run java program maven
mvn exec:java -Dexec.mainClass="com.vineetmanohar.module.Main" -Dexec.args="arg0 arg1 arg2"
run java program maven
mvn exec:java -Dexec.mainClass="com.vineetmanohar.module.Main" -Dexec.args="arg0 arg1 arg2"
execute maven project in cmd
#execute the project
mvn exec:java -Dexec.mainClass=com.mycompany.App
what is pom.xml
- pom.xml file allows us to add, remove, manage dependencies
and versions from one single location.
- POM stands for project object model
- .xml -> stands for: extensible markup language
How to run Maven from Java?
MavenCli cli = new MavenCli();
cli.doMain(new String[]{"clean", "install"}, "project_dir", System.out, System.out);
Copyright © 2021 Codeinu
Forgot your account's password or having trouble logging into your Account? Don't worry, we'll help you to get back your account. Enter your email address and we'll send you a recovery link to reset your password. If you are experiencing problems resetting your password contact us