Git command summary
Jump to navigation
Jump to search
Branching
Create branch
git branch branch-name
Display branches
git branch
Switch branch
git checkout branch-name
Staging
git add file-name
Committing
Commit
git commit -m "Commit message goes here."
Push
git push
Diffing
To see a diff list of changes made to the files on disk:
git diff
To see a diff list of changes made to the staged files:
git diff --cached