This page is about how to initiate a pull request. I have another page that deals with how to process a pull request you have received.:
I cloned a project, did some work, corresponded with the author, and he requested that I submit my changes back to him as a pull request.The way to do this properly is to first fork the respository in question. Then create a branch to hold your changes and additions. Commit that to your forked respository, then trigger the pull request. Of course I did not do this at all, I just cloned the repository and started hacking. This means I will have to backtrack, manually merge in the changes I have made, and then I can join the expected process.
And it is just that easy. Now I have my own private fork of the MFM emulator in my own Github area.
I could add this point fiddle around to change the remote so my clone is linked to the original repository. This would be a good idea if I expected to be collaborating on the project long term as it would allow me to keep my clone up to date. However in this instance, I expect my contribution to be a one time thing, so don't expect that to be important. The general idea would be to do something like this:
git remote add --track master upstream https://github.com/dgesswein/mfm.git git fetch upstreamHowever, I skip this.
cd /u1/Projects/Callan/Gesswein git clone [email protected]:trebisky/mfm_emulator.gitNow I have a choice. Some examples recommend making a branch at this point to hold the changes. Other examples just dive in and make changes to the main branch. Making changes on a branch seems to be the best idea and most commonly recommended.
cd mfm_emulator git checkout -b add_callan Switched to a new branch 'add_callan'
mfm/mfm_decoder.c mfm/wd_mfm_decoder.c mfm/inc/mfm_decoder.hI copy those files into the new working directory.
git add . git commit git push origin add_callan(Typing "git push origin master" gives me a the message: "everything up to date message".
This gives me the handy hint:
remote: Create a pull request for 'add_callan' on GitHub by visiting: remote: https://github.com/trebisky/mfm_emulator/pull/new/add_callanI take note of this suggestion, but just visit my forked repository on the Github web page. It takes me to a dialog to submit the pull request. I fill out a little message for David there and submit the request (which it tells me can be merged without conflicts).
And that is it.
Tom's Computer Info / [email protected]