Reputation: 2812
I've forked a repo on github to do my own customistations.
However, along the way, I discovered a bug and fixed it and would like to send a pull request upstream.
I followed the guide at: http://gun.io/blog/how-to-github-fork-branch-and-pull-request/
And have created a branch with just the bugfix on it - but when I go to submit a pull request to the upstream - it lists all the changes I've made since I forked, I can't seem to find a way to isolate the bug fix patch. I don't want to send all my changes, and I'm guessing they don't want to receive them - so how do I send just the bug fix?
If it helps, the repo is https://github.com/chrisjensen/ankusa The branch is untrainfix
Upvotes: 1
Views: 144
Reputation: 1328982
The way pull requests work is to apply a commit from a fork on top of the upstream repo.
For that, the easiest way is to make your fix on the same branch than the one you intend to apply it (by making a pull request) on the upstream repo.
In other words, all your changes should be done in a custom branch, except for the fix, that you should do (or report by cherry-picking) on the same branch than the one used in the original upstream repo.
If you want to fix a bug on master
from upstream, make your fix in the master
branch of your fork, by first making sure your master
branch is identical (git pull
) to the one in upstream.
Upvotes: 1