GIT COMMANDS
- git stash - stash changes of a dirty working directory away in order to go back to a clean directoy
- git stash list - to see the stashes you've stored
- git stash apply - apply changes of what you stashed, uses the most recent one unless specified
- git stash show -p | git apply -R - unapplys the stash you added
- git shortlog - shows list of authors and commits
- git commit --amend - edit the commit message
- git reset --hard - reverts to previous commit
- git reset --soft - will undo the last commit, but the file changes will stay in your working tree
- git reset --hard HEAD~2 -
Find three different ways to display the git log. One example is git log --oneline.
- git log --oneline - condenses each commit to single line
- git log --oneline --decorate - display all of the references (e.g., branches, tags, etc) that point to each commit
- git log --stat option displays the number of insertions and deletions to each file altered by each commit (note that modifying a line is represented as 1 insertion and 1 deletion)