...
Release candidates are built from a release branch. As a final step in preparation for the release, you should create the release branch, push it to the code repository (you should probably do this once the whole process is done), and update version information on the original branch.
Check out the version of the codebase from which you start the release. For a new minor or major release, this may be HEAD
of the master
branch. To build a hotfix/incremental release, instead of the master
branch, use the release branch of the release being patched. (Please make sure your cloned repository is up-to-date before starting.)
Code Block | ||
---|---|---|
| ||
BRANCH="<master branch OR release branch>"
$ git checkout $BRANCH |
Set up a few environment variables to simplify Maven commands that follow. (We use bash
Unix syntax in this guide.)
...
If you are doing a new major/minor release, first create check out the version of the codebase from which you start the release. This may be HEAD
of the master
branch. Create a branch for the new version that we want to release before updating the master branch to the next development version:
Code Block | ||
---|---|---|
| ||
$ git checkout master $ git checkout -b release-$SHORT_RELEASE_VERSION $ git checkout $BRANCHmaster $ cd tools tools $ OLD_VERSION=$CURRENT_SNAPSHOT_VERSION NEW_VERSION=$NEXT_SNAPSHOT_VERSION releasing/update_branch_version.sh $ cd .. $ git checkout -b release-$SHORT_RELEASE_VERSION |
...