2011-02-12 30 views
5

Ne etkileşimli olmayan git komutu (ler) (M.Ö. bir birleştirme olduğu taahhüt) sonra öncesinden bu yana gelen değişim ulaşmakayrı şube +

önce taahhüt birleştirme olarak taahhüt :

A---B---C---D 

sonra:

İşte
B---C 
/ \ 
A-------BC---D' 

cevap

5

ben öyle yapardım:

$ git branch to-merge-in C-commit-ID # Create a branch at C 
$ git reset --hard A-commit-ID   # Reset current branch to A 
$ git merge --no-ff to-merge-in   # Merge in branch. Create a merge commit. 
$ git cherry-pick D-commit-ID   # Grab the commit D