mvn
Apache Maven: build and manage Java-based projects. tldr-pages
On several platforms
Several platforms
Compile a project
mvn compileIdentifyCompile and package the compiled code in its distributable format, such as a jar
mvn packageIdentifyCompile and package, skipping unit tests
mvn package --define skipTestsIdentifyInstall the built package in local maven repository. (This will invoke the compile and package commands too)
mvn installIdentifyDelete build artifacts from the target directory
mvn cleanIdentifyDo a clean and then invoke the package phase
mvn clean packageIdentifyClean and then package the code with a given build profile
mvn clean --activate-profiles profile packageIdentifyRun a class with a main method
mvn exec:java --define exec.mainClass="com.example.Main" --define exec.args="argument1 argument2 ..."Identify