Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Find the default phase that a Maven plugin binds to

Given a <plugin> element in a pom.xml, how do I find the default phase that it binds to?

For example, I'd like to know which phase of the Maven lifecycle does the maven-war-plugin gets executed.

like image 922
ryanprayogo Avatar asked Oct 17 '11 14:10

ryanprayogo


People also ask

What is default phase in Maven plugin?

Given the lifecycle phases above, this means that when the default lifecycle is used, Maven will first validate the project, then will try to compile the sources, run those against the tests, package the binaries (e.g. jar), run integration tests against that package, verify the integration tests, install the verified ...

What are the Maven phases?

Maven Lifecycle: Below is a representation of the default Maven lifecycle and its 8 steps: Validate, Compile, Test, Package, Integration test, Verify, Install and Deploy.

Are Maven goals tied to phases?

A Maven plugin is a group of goals; however, these goals aren't necessarily all bound to the same phase.


1 Answers

The best way to see what's really happening in your project along those lines is with mvn help:effective-pom. It doesn't just show the defaults; it shows what actually is according to your current pom.

like image 129
Ryan Stewart Avatar answered Sep 28 '22 00:09

Ryan Stewart