Thursday, March 19, 2015

Git merge master into feature branch

Source: http://stackoverflow.com/questions/16955980/git-merge-master-into-feature-branch

You should be able to rebase your branch on master:
git checkout feature1
git rebase master
Manage all conflicts that arise. When you get to the commits with the bugfixes (already in master), git will say that there were no changes and that maybe they were already applied. You then continue the rebase (while skipping the commits already in master) with
git rebase --skip
If you perform a git log on your feature branch, you'll see the bugfix commit appear only once, and in the master portion.