Skip to content

Instantly share code, notes, and snippets.

@progging
Created January 23, 2020 09:43
Show Gist options
  • Save progging/c9183a197fa6e06a9feda357b8c85fea to your computer and use it in GitHub Desktop.
Save progging/c9183a197fa6e06a9feda357b8c85fea to your computer and use it in GitHub Desktop.
awesome-git-aliases
yeet = "!yeet(){ git add -A && git commit -m $@ && git push; }; yeet"
refresco = !git fetch --all --prune && git checkout master && git pull && git lastbranch
amend = commit --amend --no-edit
lastbranch = checkout @{-1}
qlog = log -10 --oneline --decorate
qbranch = "!qb(){ git checkout -b PREFIX$@; }; qb"
qcheckout = "!qc(){ git checkout PREFIX$@; }; qc"
qa = "!qa(){ git refresco && git branch --remote | grep $@ | sed 's/origin\\///' | xargs git checkout && git pull --rebase; }; qa"
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment