Hotfix finish doesn't merge back to a release branch if exists
Bankers88 opened this issue · 3 comments
Why is a hotfix branch not merged back to a release branch if it is open? When you run the git flow hotfix finish 1.18.6 the hotfix branch is merged to master and develop. Is there there an option to do so?
hotfix/1.18.6
release/1.19.0
master
This is what I expected:
https://nvie.com/posts/a-successful-git-branching-model/
The one exception to the rule here is that, when a release branch currently exists, the hotfix changes need to be merged into that release branch, instead of develop. Back-merging the bugfix into the release branch will eventually result in the bugfix being merged into develop too, when the release branch is finished.
Hmmm...
For me it's more logical as is:
You need the hotfix merged into develop for new feature branches....
Of course, you might need to rebase your feature branch on the current develop anyway (other feature branches might be merged since you started your own feature), but I think for a project with heavy developing it's easier to either rebase the release branch or to cherry pick the hotfix, as it would be to potentially recheck every feature branch started after the hotfix for new clashes within the code (it's enough work to do so for features started before the hotfix).
Maybe to both branches the develop and release branch. I think you don't want to lose the bugfix in the next release (release branch).
Wat about to give the user the option. So we introduce new parameter -r that will merge back to the release branch if it exists.
For example:
git flow hotfix finish -r
Any thoughts @petervanderdoes?
Since it's not with certainty that the hotfix would be needed within the new release that would be the best bet...
Although one has to expect that the hotfix won't apply cleanly to the release branch!