bilal-korir
7/14/2018 - 11:59 AM

Git frequent used commands

Git frequent used commands

Git user configuration

$ git config --global user.name "John Doe"

$ git config --global user.email johndoe@example.com

Global .gitignore configuration

$ git config --global core.excludesfile ~/.gitignore

Untrack files already added to the repository

git rm -r --cached .

Remove unstaged and uncommited chnages and back to the last commit

git reset --hard