Reputation: 1511
I can disable the particular phase in pom: Disable phases in Maven lifecycle. It is possible to disable test from the command line: -Dmaven.test.skip=true
Is it possible to start mvn lifecycle from the particular phase, for example compile using only the command line options ?
Upvotes: 1
Views: 230
Reputation: 402
By default, a lifecycle is as follows (from Introduction to the Build Lifecycle):
While we can build applications without automated testing, we can't execute the package phase without an earlier code compilation. Just as we are not able to install the package into the local repository without the .jar/.war packages, that are created in package phase.
For compilation you can use Apache Maven Compiler Plugin.
Then you can run compilation by executing
mvn compile
The command will execute maven goal compiler:compile
Upvotes: 1