I write a Mojo Plugin. It has a Pamameter like:
*@Mojo(name = "showModus", requiresProject = false, defaultPhase = LifecyclePhase.PROCESS_RESOURCES)<br>
public class ShowModus extends AbstractMojo { <br>
@Parameter (property = "modus", defaultValue = "${modus}")<br>
private String modus;*
in Pom.xml of Mojo Plugin i define a property for this:
<properties><modus>1.1.1</modus></properties>
It works fine if i call the Mojo goal direct under project order per mvn
But if i call the mojo plugin direct form maven repo or. in directory without mojo plugin the Parameter modus is not set.
I understand that mvn can not find the pom.xml of mojo plugin project and therefore can not set the value to parameter.
Is there any way where i can set the pom properties of the mojo maven plugin to the generated plugin.xml ?
I wourd like to call (use) the mojo maven plugin direct from maven repo with certain parameter whereby their value set or inject from pom.xml of plugin
Greeting