As a newbie to Github, I've just submitted a pull request. The owner of the project is pretty happy with my additions but they're not quite perfect and need a bit of changing.
How do I proceed from here? Do I need to close the current pull request and submit a new one? Or is there a way of amending one?
Also is it preferable to reset my branch and make the required changes from scratch, or make another commit to my branch to amend the changes on top of my previous changes?
You can revert a pull request after it's been merged to the upstream branch.
You cannot add commits directly to User B's pull-request unless you have write access to User B's fork. You can, however, make local additions to the pull-request, by just fetching the pull-request branch into your own local repo (assuming the url for B's fork is public).
Once you create a pull request, if you look near the bottom of the issue it creates, there is a message which mentions that if you push more commits to the branch you've made the request on, they'll be appended to the pull request.
All additional commits pushed to the same branch become part of that pull request. The reason for that is due to the way a pull request works. You can think of it as the person accepting the pull request as pulling the current state of that branch at the moment they decide to merge, rather than creating a set of changes and asking for that to be accepted.
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With