Last active
November 3, 2016 15:08
-
-
Save mallond/6172ba0ed865f8b70a73cb3ec8f84872 to your computer and use it in GitHub Desktop.
Git Rebase
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Merge a branch B1 in N1 with rebase | |
git checkout N1 | |
git pull | |
git checkout B1 | |
git rebase N1 | |
git checkout N1 | |
git rebase B1 | |
# Yet another approach | |
https://medium.com/@sda/git-rebase-based-workflow-cheat-sheet-3e37ad39da66#.lovwmnkbo | |
git remote add upstream https://github.com/userOrOrg/repoName.git | |
git pull upstream master | |
git checkout -b "awesomeFeature" | |
git add . | |
git commit -m "Added an awesome feature" | |
git pull --rebase upstream master | |
git rebase --continue | |
git push origin awesomeFeature | |
git checkout master | |
git pull upstream master |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment