This plugin is used to release a project with Maven, saving a lot of repetitive, manual work. Releasing a project takes two steps: prepare and perform.
Preparing a release executes the following steps:
To execute this step, run:
mvn release:prepare
Note: If an error occurs, or the process is cancelled, then running this will pick up from where the last one left off from. If you wish to start again, use:
mvn release:prepare -Dresume=false
Alternatively, you can use:
mvn release:clean release:prepare
Note that if any changes have been made to your source files they might need to be reverted before you restart the prepare process.
Performing a release does the following:
To execute this step, run:
mvn release:perform
This relies on release.properties being present from a previous release. If this is not the case, you need to give the goal the name of the URL and optional tag to perform the release from. For example:
mvn release:perform -DconnectionUrl=scm:svn:https://svn.apache.org/repos/asf/maven/plugins/tags/maven-release-plugin-2.0
After the release is complete, the release.properties and other release files will be removed from the checkout.