Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
18 changes: 16 additions & 2 deletions pages/fork.md
Original file line number Diff line number Diff line change
Expand Up @@ -32,22 +32,36 @@ Say you want to contribute changes to someone else's repository (eg,
`git://github.com/` in the second case. I'm not sure why these need
to be the way they are, but that's what works for me.

- Also note the first myfriend does not need to be the same as the username of `myfriend`. You could very well choose:

$ git remote add repo_nickname git://github.com/myfriend/the_repo

- To check this `remote add` set up:

$ git remote -v

- Make changes to files.

- `git add` and `git commit` those changes

- `git push` them back to [github](http://github.com). These will go
to _your version_ of the repository.

- Note: if you get an error like:

error: src refspec master does not match any.
error: failed to push some refs to 'git@github.com:username/the_repo'

Then try `git push origin HEAD:gh-pages` [stackoverflow.](http://stackoverflow.com/questions/4181861/src-refspec-master-does-not-match-any-when-pushing-commits-in-git) Typing `git show-ref` can show what reference to put after HEAD.

- Go to _your version_ of the repository on github.

- Click the “Pull Request” button at the top.

- Note that your friend's repository will be on the left and _your
repository_ will be on the right.

- Give a short explaination of the changes and click the “Send
pull request” button.
- Click the green button "Create pull request". Give a succinct and informative title, in the comment field give a short explanation of the changes and click the green button "Create pull request" again.


### Pulling others' changes
Expand Down