How to contribute
Thank you for considering to contribute to our project!
This checklist is closely based on a blog post by Davide Coppola. It also serves as a table of contents.
Before your first contribution, make sure to follow the steps described in GITHUB-INTRO.md on how to create a fork, configure your git client and clone a working copy.
Create a branch
Create a local branch to collect changes related to a new feature or bug fix. Branches help to organize different developments within the project and facilitate the code review process.
You can do that with the following git command:
$ git checkout -b BRANCH_NAME
You can check which branch is active (
*) using the
$ git branch master * BRANCH_NAME
--all flag to show local and remote-tracking branches.
Work on your contribution
Now you can start with the development of your new feature (or bug fix). You can commit changes as often as you like locally. In your log message, follow the "The seven rules of a great Git commit message".
$ git add FILENAME $ git commit
git's commit and push mechanism to save and track your changes to your
$ git push origin BRANCH_NAME
Update your working copy
Make sure to pull changes from the
branch at regular intervals to keep track of changes done to the project.
We recommend to use the
--rebase flag. This will
rewind your commits and reapply them on top of the
project's history to maintain a linear history.
$ git pull --rebase upstream master
Since this changes the order of commits, you need to pass the
-f option when
you push your branch to your own fork again:
$ git push -f origin BRANCH_NAME
If you are using different computers and pushed changes to your fork on one, you can update your local branch on the other computer with:
$ git pull --rebase origin BRANCH_NAME
After pushing your changes to your fork navigate to the GitHub page of your fork and create a Pull request. Add the needed information to the web form and submit your request.
The developer team will review your changes and decide whether to accept your changes. This process might include some discussion or even further changes to the code (this is the reason why branches are important).
After your contribution has been merged to the main project (or rejected) you can delete your development branch:
$ git branch -D BRANCH_NAME # local $ git push origin --delete BRANCH_NAME # server-side