Releasing procedure¶
The codebase development is done using the Git-flow branching pattern1.
Use a Git extension
There are few extensions that allow to automatize the overhead of sticking to the branching model by hand, i.e. by using Git vanilla commands. Since trunk based development has become in the software landscape more appealing, most Git extension to implement Git-flow pattern have decreased maintenance and many froze. However, in simple scenarios, like manual usage in the terminal, any extension should work as expected. You can check-out the AVH edition (which has been archived in June 2023) or the CJS Edition which is still (rarely) active. Both are successors of the original implementation by Vincent Driessen, who invented the model in first place.
When the code is ready to be published, a release
branch shall be created and the finalization steps should be carried out on it.
Closing the branch means to merge it into main
, which will be tagged and contain the released version, and merge it back to develop
, which in principle might have continue development.
Don't forget to update the version string
In the codebase there is a global HYBRID_codebase_version
variable, which contains the version label.
This should be bumped on the release
branch, i.e. when it is clear which will be the following version number.
Analogously, it should be bumped into a dirt state2 on develop
as soon as the release
is closed.
Release checklist¶
- Create the
release
branch fromdevelop
and switch to it. - Make sure everything is ready to go.
- Bump version number global variable in main script to a stable state.
- Close the
release
branch in the git-flow sense:- merge it into the
main
branch; - switch to
main
and tag the last commit; - switch to
develop
and merge therelease
back into it3.
- merge it into the
- Publish the new release by pushing the changes and the new tag on
main
. - From
main
build and deploy the documentation. - From
develop
bump version number global variable in main script to an unstable state.
-
Alessandro has offered a trilogy of talks about Git and these are available on his GitHub profile AxelKrypton. The second part of the last talk is devoted to introduce and explain this branching pattern in detail. ↩
-
The version variable should make clear whether the codebase is in a stable state or not. Usually a suffix like
-next
or-unreleased
is added to the last stable version name immediately after the release (in a dedicated commit), such that the main script will report the dirty state when run with the--version
option. ↩ -
This might lead to conflicts if the codebase has evolved on the
develop
branch. Please note as well that mergingmain
intodevelop
would be equivalent as themain
branch is meant for stable releases only and it should not contain anything new w.r.t. thedevelop
branch. ↩