Skip to content

Instantly share code, notes, and snippets.

What would you like to do?
Fork the repo and clone
1. List the current configured remote repository for your fork: git remote -v
2. Specify a new remote upstream repository that will be synced with the fork: git remote add upstream[ORIGINAL_OWNER]/[REPO_NAME].git
3. Verify the new upstream repository you haveve specified for your fork: git remote -v
# origin (fetch)
# origin (push)
# upstream (fetch)
# upstream (push)
Syncing a fork
1. Fetch the branches and their respective commits from the upstream repository: git fetch upstream
2. Check out your local master branch: git checkout master
3. Merge the changes from 'upstream/master' into your local 'master' branch. This brings your master branch into sync with the upstream repository, without losing your local changes: git merge upstream/master
Create pull requirest from github UI
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment