Package org.codehaus.mojo.build
Class CreateMetadataMojo
- java.lang.Object
-
- org.apache.maven.plugin.AbstractMojo
-
- org.codehaus.mojo.build.AbstractScmMojo
-
- org.codehaus.mojo.build.CreateMetadataMojo
-
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled,org.apache.maven.plugin.Mojo
@Mojo(name="create-metadata", defaultPhase=GENERATE_RESOURCES, requiresProject=true, threadSafe=true) public class CreateMetadataMojo extends AbstractScmMojoThis mojo discovers latest SCM revision, current timestamp, project version, and project name then write them to one or more java property files together with a set of user provided properties. It also has option to add the output file to resource classpath for jar packaging.
-
-
Field Summary
-
Fields inherited from class org.codehaus.mojo.build.AbstractScmMojo
password, project, revisionOnScmFailure, scmConnectionUrl, scmDeveloperConnectionUrl, scmDirectory, scmManager, scmTag, settings, shortRevisionLength, skip, username
-
-
Constructor Summary
Constructors Constructor Description CreateMetadataMojo()
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description voidexecute()StringgetRevision()-
Methods inherited from class org.codehaus.mojo.build.AbstractScmMojo
checkResult, getScmRepository, getScmRevision, info
-
-
-
-
Method Detail
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException- Throws:
org.apache.maven.plugin.MojoExecutionExceptionorg.apache.maven.plugin.MojoFailureException
-
getRevision
public String getRevision() throws org.apache.maven.plugin.MojoExecutionException
- Throws:
org.apache.maven.plugin.MojoExecutionException
-
-