Keeping Pull Requests clean:
- Note that this is a semi-advanced topic. Make sure you are somewhat familiar with using git and/or try this on repositories you control before actually using it publically.
Creating a fork to make edits on:
On github, click fork
git clone FORKURLgit checkout -b patch-NAMEMaking changes:
make changes,
git add FILE,git commit,git status, etc to add new commitsPull new changes made from original repo to your fork
git remote add upstream FORKEDwhere FORKED is the git clone url for the original repo that was forkedgit fetch upstreamgit rebase upstream/masteror whatever the name of the upstream branch you want to update to is- use
git logto verify git push origin
Actually pulling new changes:
git pull upstream masterthengit committo update from the forked git- These commits will disappear when you use rebase at the end
Making the actual pull request
- These commits will disappear when you use rebase at the end
- make pull request within github’s GUI
- On your repo there may be a notification asking if you want to create a pull request
- You can also go to the original repo, pull requests and create on there
**DO NOT EVER EVER EVER REBASE ON NON-PULL-REQUEST REPOS/BRANCHES**