Created
September 11, 2014 14:07
-
-
Save nataliepo/abd716667b6325a66608 to your computer and use it in GitHub Desktop.
keeping a forked repo up to date
This file contains 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
to configure your repo to point to an upstream repo: | |
1. add this to .git/config: | |
[remote "upstream"] | |
url = https://github.com/gitusername/repo-name.git | |
fetch = +refs/heads/*:refs/remotes/upstream/* | |
2. fetch the other repo's changes into upstream/master | |
git fetch upstream | |
3. check out your local master branch. | |
git checkout master | |
4. merge upstream/master -> local master. | |
git checkout master | |
git merge upstream/master | |
then, your master will be up to date with the original repo's master. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment