我已经与许多分支机构分道扬..两个分支特别感兴趣我。
1.8.x
2.2.x
我引入了一个新文件'newfile.source'并更改了两个分支中存在的文件'existingfile.source'。我想同步我在两个分支之间的newfile和existingfile中所做的更改。
我在脑海中对此进行建模的方式是这样的:
commit -- commit -- commit -- commit -- commit -- commit -- commit -- 2.2.x
\
-- commit -- 1.8.x
我希望有一个结构(分支但只包含对现有文件和新文件的更改),我可以对其进行更改并合并到1.8.x和2.2.x中:
nothing -- custom_changes -- nothing
然后执行以下操作:
git checkout 2.2.x
git merge custom_changes
git checkout 1.8.x
git merge custom_changes