As I know, we can set parameters for maven plugin by either put them in configuration section of pom.xml or -Dparameter in command line. I think -Dparameter will override the same one in the pom. I can find the available parameter list in the reference doc of the plugin. But how can got the -Dparameter list ?
Share
Start with the documentation for the plugin goal you want to configure. The top part of the page lists the required and optional parameters. If you scroll down the page (or click a parameter name) to view the parameter details, many of them have an “Expression” listed; that’s the property you specify on the command line.
For example, consider the jar:jar goal as an example. If I wanted to set the
forceCreationflag to true, I could add<forceCreation>true</forceCreation>in the plugin config. The details for theforceCreationproperty show the Expression as ${jar.forceCreation}, so I could add-Djar.forceCreation=trueon my Maven command line to accomplish the same thing.