How to commit changes to the repository - TopBrussels/TopTreeAnalysis GitHub Wiki

To commit changes of your code (e.g. mycode.cc) to the GitHub repository, you can do the following commands:

First add the file to the 'staging area'; this is also referred to as 'taking a snapshot'. Note that this command has to be done every time you want to commit, not only once (like was the case for CVS)!

git add mycode.cc

You can optionally check the status of the file you are about to commit:

git status -s

Commit the code to your local copy of the repository:

git commit -m 'Some change log text'

Finally commit the code to the remote repository:

git push origin