Create a directory for which you will create repositories
mkdir ~/repos
cd ~/repos
Next we need to clone a repository from the URL of a repository
git clone https://github.com/eragasa/pyflamestk.git
For each file you want to add to the repository
git add <filename/directory>
To see which file will be committed you can use the git status command
git status
First, you need to commit the changes to the local repository
git commit -m '<message>'
To update an existing local repository from the master repository on github, run the following command
git pull
Second, you need to push the changes to remote master repository
git push
In some cases, you will have really messed up development. In this case, you can reset from the current master branch
git fetch origin
git reset --hard origin/master
git clean -f
Cheat Sheet for Git Hub
References: