Skip to content

Instantly share code, notes, and snippets.

@mcfiredrill
Created September 16, 2017 03:09
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save mcfiredrill/c74f218e178377a98a2724db7d591511 to your computer and use it in GitHub Desktop.
Save mcfiredrill/c74f218e178377a98a2724db7d591511 to your computer and use it in GitHub Desktop.
cool git aliases
☯tony@okirakugokiraku☯ ~$ cat .gitconfig
[user]
email = mcfiredrill@gmail.com
name = Tony Miller
[color]
ui = true
[core]
excludesfile = /home/tony/.gitignore_global
[alias]
s = status
edit-unmerged = "!f() { git ls-files --unmerged | cut -f2 | sort -u ; }; vim `f`"
add-unmerged = "!f() { git ls-files --unmerged | cut -f2 | sort -u ; }; git add `f`"
continue-rebase = rebase --continue
latest-branches = for-each-ref --count=30 --sort=-committerdate refs/heads/ --format='%(refname:short)'
ci = commit
dc = diff --cached
br = branch
co = checkout
df = diff
lg = log -p
who = shortlog -s --k
delete-remote-branch = "!f() { git push origin :$1; }; f"
[bash]
showDirtyState = true
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment