Skip to content

Instantly share code, notes, and snippets.

@azizoid
Last active May 18, 2025 18:24
Show Gist options
  • Select an option

  • Save azizoid/1e671481c0ea8039d8cb4ee56418f80a to your computer and use it in GitHub Desktop.

Select an option

Save azizoid/1e671481c0ea8039d8cb4ee56418f80a to your computer and use it in GitHub Desktop.
git shortcuts
[alias]
co = checkout
br = branch
st = status
cp = cherry-pick
lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit
gr = log --all --decorate --oneline --graph
cleanup = "!git fetch -p && git branch -vv | awk '/: gone]/{print $1}' | xargs -r git branch -D"
last = log -1 HEAD --stat
stats = log --stat --oneline
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment