HomeToolsAbout a20k

Diffing

Compare Commits

Show which files modified and created new

git status

Show difference between unstaged changes and previous commit

git diff

Show difference between staged changes and previous commit

git diff --staged

Show all difference between previous n-commit

git diff HEAD~n

Compare Against Remote Branch

Show difference between local and remote branch

git diff local_branch_name origin/remote_branch_name

Summarize File Diffs

Show summary of files changed and number of added/deleted files

git diff --stat

Show summary of branch difference by files by stats

git diff --stat --color master..origin/master

Merge Conflict Status

Check for merge conflict markers and whitespace errors

git diff --check

Show list of conflicting file names in Git

git diff --name-only --diff-filter=U
© VincentVanKoh