The repositories follow the GitFlow workflow: development happens on develop, and main
holds what is released. The commands below come from the
GitFlow Maven plugin, which creates and
merges the branches and updates the project versions at the same time.
Features
| Command | Effect |
|---|
mvn gitflow:feature-start | Creates a feature branch from develop, for example feature/module-catalog |
mvn gitflow:feature-finish | Merges the finished feature into develop; the feature branch can then be deleted |
Releases
| Command | Effect |
|---|
mvn gitflow:release-start | Creates a release branch from develop and sets the release version in the pom.xml files |
mvn gitflow:release-finish | Merges the release into main, tags it, merges it back into develop and sets the next development version |
mvn gitflow:release | Releases directly, without a release branch. Suited to simple projects. |
Hotfixes
| Command | Effect |
|---|
mvn gitflow:hotfix-start | Creates a hotfix branch from main to fix an urgent production defect, with an incremented patch version |
mvn gitflow:hotfix-finish | Merges the fix into main, tags it, and merges it into develop so that later versions include it |
Support and versions
| Command | Effect |
|---|
mvn gitflow:support-start | Creates a support branch from a production tag, for example support/1.x, to maintain an older version alongside main and develop |
mvn gitflow:version-update | Updates the project version on a release or support branch, and can tag and push the change |