3.3 Git on your own
git init
: turn the current folder into a git repositorygit status
: let’s you know what is going on run this all the time!git add
: put file(s) into your “staging area”git commit -m 'MY COMMIT MESSAGE'
: commits files in the “staging area” with the given messagegit diff <file name>
: compares saved changes to a file to the last commited version of the filegit diff --staged <file name>
: compares a staged file to the last commited version of the filegit log
andgit log --oneline
: looks at your git historygit log --oneline --graph --decorate --all
: gives detailed log information about where you are
How not to write commit messages:
how #not to write #git #commit messages -.-'' pic.twitter.com/5TdiZ1yi5S
— Dⓐniel Chen ((???)) April 16, 2015