Instantly share code, notes, and snippets.

Embed
What would you like to do?
How to contribute to a project on Github

This text now lives at https://github.com/MarcDiethelm/contributing/blob/master/README.md. I turned it into a Github repo so you can, you know, contribute to it by making pull requests.


Contributing

If you want to contribute to a project and make it better, your help is very welcome. Contributing is also a great way to learn more about social coding on Github, new technologies and and their ecosystems and how to make constructive, helpful bug reports, feature requests and the noblest of all contributions: a good, clean pull request.

How to make a clean pull request

Look for a project's contribution instructions. If there are any, follow them.

  • Create a personal fork of the project on Github.
  • Clone the fork on your local machine. Your remote repo on Github is called origin.
  • Add the original repository as a remote called upstream.
  • If you created your fork a while ago be sure to pull upstream changes into your local repository.
  • Create a new branch to work on! Branch from develop if it exists, else from master.
  • Implement/fix your feature, comment your code.
  • Follow the code style of the project, including indentation.
  • If the project has tests run them!
  • Write or adapt tests as needed.
  • Add or change the documentation as needed.
  • Squash your commits into a single commit with git's interactive rebase. Create a new branch if necessary.
  • Push your branch to your fork on Github, the remote origin.
  • From your fork open a pull request in the correct branch. Target the project's develop branch if there is one, else go for master!
  • ...
  • Once the pull request is approved and merged you can pull the changes from upstream to your local repo and delete your extra branch(es).

And last but not least: Always write your commit messages in the present tense. Your commit message should describe what the commit, when applied, does to the code – not what you did to the code.

@olaoluwa-98

This comment has been minimized.

olaoluwa-98 commented Apr 7, 2017

This is very helpful

@HarshitKaushik

This comment has been minimized.

HarshitKaushik commented Apr 8, 2017

Very helpful for beginners, thank you.

@Jambazishvili

This comment has been minimized.

Jambazishvili commented Jun 6, 2017

pretty helpful and nicely structured. thank you very much!

@dattz

This comment has been minimized.

dattz commented Jun 20, 2017

Thank you.

@ryanrayjahn

This comment has been minimized.

ryanrayjahn commented Dec 23, 2017

Will try.

@Nikoloutsos

This comment has been minimized.

Nikoloutsos commented Jan 4, 2018

Thank you for sharing this with us!
It helped me so much..

@StephRicardo

This comment has been minimized.

StephRicardo commented Jan 20, 2018

Thanks so much for this gist! It's excellent!

@CompSciGuyIT

This comment has been minimized.

CompSciGuyIT commented Feb 22, 2018

Nice! This demystifies things quite a lot. Thank you.

@fost14oct

This comment has been minimized.

fost14oct commented Feb 22, 2018

Thank you :D

@zoldos

This comment has been minimized.

zoldos commented Feb 23, 2018

Seems a bit involved, but I'm ready to dive right in, esp. with PHP! 👍

@TirupathiAndroid

This comment has been minimized.

TirupathiAndroid commented Apr 4, 2018

Thank you

@Krishna-Vyas

This comment has been minimized.

Krishna-Vyas commented Apr 5, 2018

Thank you,, for your great response.

@shanky97

This comment has been minimized.

shanky97 commented Apr 5, 2018

Thanks

@vicrobot

This comment has been minimized.

vicrobot commented Apr 6, 2018

Great

@sayantanHack

This comment has been minimized.

sayantanHack commented Apr 10, 2018

sounds good

@haidaoxiaofei

This comment has been minimized.

haidaoxiaofei commented May 21, 2018

just tried. Nice procedure.

@EigenLaw

This comment has been minimized.

EigenLaw commented Jun 6, 2018

Thanks very much!

@ArjunasarathyM

This comment has been minimized.

ArjunasarathyM commented Jun 20, 2018

was really helpful :), Thank you

@pkoukia

This comment has been minimized.

pkoukia commented Jul 8, 2018

Nice :)

@Joshua-Inman

This comment has been minimized.

Joshua-Inman commented Aug 1, 2018

Thank you!

@FrancoisT31

This comment has been minimized.

FrancoisT31 commented Sep 30, 2018

A big thank you for that !

@paddotk

This comment has been minimized.

paddotk commented Oct 8, 2018

Is there a reason for calling the remote upstream? origin seems the more obvious/default choice to me.

@sheikgit

This comment has been minimized.

sheikgit commented Nov 12, 2018

Very helpful!!! Just submitted my first contribution!! :)

@iranappo

This comment has been minimized.

iranappo commented Nov 19, 2018

Thank you

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment