Class MavenVersionMojo

java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.codehaus.mojo.buildhelper.AbstractDefinePropertyMojo
org.codehaus.mojo.buildhelper.MavenVersionMojo
All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled, org.apache.maven.plugin.Mojo

@Mojo(name="maven-version", defaultPhase=VALIDATE, threadSafe=true) public class MavenVersionMojo extends AbstractDefinePropertyMojo
Store the maven core version in a property maven.version.
Since:
1.3
  • Field Details

    • runtime

      @Component private org.apache.maven.rtinfo.RuntimeInformation runtime
      The RuntimeInforamtion for the current instance of Maven.
    • versionProperty

      @Parameter(defaultValue="maven.version") private String versionProperty
      The name of the property in which to store the version of Maven.
  • Constructor Details

    • MavenVersionMojo

      public MavenVersionMojo()
  • Method Details

    • execute

      public void execute()
      Main plugin execution