Skip to content

Add more details in the release strategy guide #86

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 2 commits into
base: main
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
33 changes: 32 additions & 1 deletion BRANCHING_RELEASE_STRATEGY.md
Original file line number Diff line number Diff line change
Expand Up @@ -137,15 +137,39 @@ $ git checkout main
$ git pull
```

Verify that you don't use a RC or SNAPSHOT version for the PowSyBl dependencies.
Using the following command, you should only have your repo version:
```shell
$ git grep -B2 -E "SNAPSHOT|-RC" pom.xml | less
$ # You should not have RC or SNAPSHOT versions (except your own repo's one)
```
If it is not the case, then the bump of the dependencies should be done prior to releasing.

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

++ in a regular pull request

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

If the README contains POM examples they should be updated to include the right versions for the project beeing releases and its dependencies (to include in the bump version commit or before so that it is included in the release tag).

Create your temporary branch preparing to the release X.Y.0 and add a commit bumping to your release version.
```shell
$ git checkout -b tmp_prepare_release
$ mvn versions:set -DnewVersion=X.Y.0
$ git commit -s -a -S -m "Bump to vX.Y.0"
$ git push -u origin tmp_prepare_release
$ # Then create a PR for tmp_prepare_release
```

Create a pull request from your temporary branch into the `main` branch.
In its description, use the following message (don't forget to change the vX.Y.0 by your version number):
```markdown
**Please check if the PR fulfills these requirements**
<!-- please use `'[x]'` to check the checkboxes, or submit the PR and then click the checkboxes -->
- [X] The commit message follows our guidelines


**What kind of change does this PR introduce?**
<!-- Bug fix, feature, docs update, ... -->
Prepare release vX.Y.0

**Other information**:
:warning: **DO NOT** squash the commits, merge with fast-forward locally
```

Create a pull request from your temporary branch into the `main` branch.
Wait until all the CI criteria are fully validated. Then add a commit for your next snapshot version.
You can then push again.

Expand All @@ -159,13 +183,16 @@ Tag another maintainer as a reviewer to your pull request so they can approve it

Once it is approved, locally merge it by following these steps:
```shell
$ # The PR should be reviewed and approved
$ git checkout main
$ git pull
$ git merge --ff tmp_prepare_release
$ git push
```
After that, create your tag:
```shell
$ git log --oneline -2
$ # Retrieve the commit hash of the second line, and use it in the following instruction
$ git tag -s vX.Y.0 <hash of the corresponding commit (bumping to vX.Y.0)>
$ git push origin vX.Y.0
```
Expand All @@ -181,7 +208,11 @@ Please make sure that your release note is comprehensive to all new features and

On your repository, checkout to the release tag. You can then package and deploy your release:
```shell
$ git status
$ # Your local repository should be clean
$ git checkout tags/vX.Y.0
$ git log --oneline -1
$ # Check that the last commit is indeed the "Bump to X.Y.0" commit
$ mvn dependency:purge-local-repository
$ mvn clean package -Prelease
$ mvn deploy -Prelease -DskipTests
Expand Down