是否有使用Git-flow处理非线性发布计划的解决方案?

时间:2013-05-20 20:51:23

标签: git version-control merge release

到目前为止,Git流模型对我们公司运作良好,但我们想知道处理这种假设情况的解决方案。我搜索了一下,但我认为我对这个案例缺乏适当的术语可能会阻碍我的Google-fu。

如果您的所有版本必须“来自”合并提交到master分支,详见此处:

A successful Git branching model

然后,您如何处理释放0.2.0,然后0.3.0,然后0.2.1的情况?此时必须从0.2.x开发分支执行发布(假设存在一个,或者是从0.2.0标记创建的)?当然你不能合并回master,因为你的补丁发布可能是很少的提交。

那是最好的解决方案,例如:

git checkout tag-release-0.2.0
git checkout -b some-0.2.1-critical-feature
.. (work) ..
git commit
# At this point, the release-0.2.x-branch is the same as the above release tag
git checkout release-0.2.x-branch
# Merge the feature branch into the patch release branch
git merge some-0.2.1-critical-feature
# NOTE here! Release occurs from the patch branch!
git tag tag-release-0.2.1
# Merge patch fixes into develop
git checkout develop
git merge tag-release-0.2.1

有比这更好的解决方案吗?如果 RULE 要合并到master中以执行发布,那么在下一个minor / major之前是否不会发生任何补丁发布?

0 个答案:

没有答案