Skip to content

Instantly share code, notes, and snippets.

@dmtrek14
Created July 15, 2022 16:09
Show Gist options
  • Save dmtrek14/20a139dd0f9a855eb7e6c718220c107f to your computer and use it in GitHub Desktop.
Save dmtrek14/20a139dd0f9a855eb7e6c718220c107f to your computer and use it in GitHub Desktop.
Some useful Git aliases
[alias]
s = status
d = diff
co = checkout
cob = checkout -b
cane = commit --amend --no-editor
aa = add --all
cam = commit -am
delb = branch -D
br = branch --format='%(HEAD) %(color: brightBlue)%(refname:short)%(color:reset) - %(contents:subject)%(color:green)(%(committerdate:relative)) %(color: magenta)[%(authorname)]' --sort=-committerdate
undo = reset HEAD~1 --mixed
psu = push --set-upstream origin
sl = stash list
ss = stash save
sp = stash pop
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment