Keeping your branch up-to-date¶
When working with other developers, it can be that the branch your are working on becomes out of sync with the base branch. In your Github PR your will see the following message:
If this happens, you need to retrieve all the changes from upstream, and apply them to your branch by rebasing it on top of master.
-
Open Terminal.
-
Change the current working directory to your local project.
-
Sync up your fork with
upstream
.git checkout master git pull upstream master git push origin master
-
Rebase your branch.
git checkout - git rebase master
-
Update your branch.
git push origin -f