Package org.apache.maven.plugins.release
Class PrepareReleaseMojo
java.lang.Object
org.apache.maven.plugin.AbstractMojo
org.apache.maven.plugins.release.AbstractReleaseMojo
org.apache.maven.plugins.release.AbstractScmReleaseMojo
org.apache.maven.plugins.release.PrepareReleaseMojo
- All Implemented Interfaces:
org.apache.maven.plugin.ContextEnabled
,org.apache.maven.plugin.Mojo
- Direct Known Subclasses:
PrepareWithPomReleaseMojo
@Mojo(name="prepare",
aggregator=true,
requiresDependencyCollection=TEST)
public class PrepareReleaseMojo
extends AbstractScmReleaseMojo
Prepare for a release in SCM. Steps through several phases to ensure the POM is ready to be released and then
prepares SCM to eventually contain a tagged version of the release and a record in the local copy of the parameters
used. This can be followed by a call to
release:perform
. For more info see https://maven.apache.org/plugins/maven-release-plugin/usage/prepare-release.html.- Author:
- John Casey, Emmanuel Venisse, Jason van Zyl, Brett Porter
-
Field Summary
Fields inherited from class org.apache.maven.plugins.release.AbstractReleaseMojo
project, releaseManager, session
Fields inherited from interface org.apache.maven.plugin.Mojo
ROLE
-
Constructor Summary
-
Method Summary
Modifier and TypeMethodDescriptionvoid
execute()
protected String
Gets the comma separated list of additional profiles for the release build.protected void
prepareRelease
(boolean generateReleasePoms) prepareRelease.Methods inherited from class org.apache.maven.plugins.release.AbstractScmReleaseMojo
buildScm, createReleaseDescriptor
Methods inherited from class org.apache.maven.plugins.release.AbstractReleaseMojo
addArgument, getBasedir, getProject, getReactorProjects, getReleaseEnvironment, setBasedir, setPomFileName
Methods inherited from class org.apache.maven.plugin.AbstractMojo
getLog, getPluginContext, setLog, setPluginContext
-
Constructor Details
-
PrepareReleaseMojo
public PrepareReleaseMojo()
-
-
Method Details
-
getAdditionalProfiles
Gets the comma separated list of additional profiles for the release build.- Overrides:
getAdditionalProfiles
in classAbstractReleaseMojo
- Returns:
- additional profiles to enable during release
-
execute
public void execute() throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException- Specified by:
execute
in interfaceorg.apache.maven.plugin.Mojo
- Overrides:
execute
in classAbstractScmReleaseMojo
- Throws:
org.apache.maven.plugin.MojoExecutionException
org.apache.maven.plugin.MojoFailureException
-
prepareRelease
protected void prepareRelease(boolean generateReleasePoms) throws org.apache.maven.plugin.MojoExecutionException, org.apache.maven.plugin.MojoFailureException prepareRelease.
- Parameters:
generateReleasePoms
- a boolean- Throws:
org.apache.maven.plugin.MojoExecutionException
- if any.org.apache.maven.plugin.MojoFailureException
- if any.
-