Merging an upstream repository into your fork
1. Check out the branch you wish to merge to. Usually, you will merge into master
.
-
$ git checkout master
2. Pull the desired branch from the upstream repository. This method will retain the commit history without modification.
-
$ git pull https://github.com/ORIGINAL_OWNER/ORIGINAL_REPOSITORY.git BRANCH_NAME
转自: https://help.github.com/articles/merging-an-upstream-repository-into-your-fork/