Find out more
$ git --version
Find out more
$ git config --global user.name "[username]"
$ git config --global user.email "[valid-email]"
$ git config --global color.ui auto
Working with Local Branch
Find out more
$ git branch
$ git branch -a
$ git branch -d
$ git push origin –delete [branchName]
Checkout an existing branch
$ git checkout
Checkout and create a new branch
$ git checkout -b
Merge a branch into an active branch
$ git merge
Recover a deleted file and prepare it for commit
$ git checkout
Working With Remote Repositories
Find out more
$ git remote add origin
$ git clone
$ git push -u origin master
$ git pull origin master
$ git fetch
Working With Local Repositories
Find out more
$ mkdir test
$ cd test/
$ git init
$ cat > Readme.md
$ git add .
$ git add
$ git status
$ git commit -m "Commit message"
$ git rm
$ git rm
Find out more
$ git stash -u
brings the stashed work back to the working directory
$ git stash pop
$ git reset
$ git clean -n
$ git tag
$ git diff
$ git diff --staged
$ git diff