Created
March 16, 2015 16:59
-
-
Save bgadrian/358615eb1c83963edaed to your computer and use it in GitHub Desktop.
Git aliases
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
//a collection of git aliases | |
//to have them on all projects on my user | |
//vim ~/.gitconfig | |
[alias] | |
cp = cherry-pick | |
st = status -s | |
ci = commit | |
br = branch | |
co = checkout | |
df = diff --wrod-diff | |
lg = log -pm | |
sl = stash list | |
sa = stash apply | |
ss = stash save | |
lg = log --graph --abbrev-commit --decorate --date=relative --format=format:'%C(bold blue)%h%C(reset) - %C(bold green)(%ar)%C(reset) %C(white)%s%C(reset) %C(dim white)- %an%C(reset)%C(bold yellow)%d%C(reset)' | |
pus = "!git push origin \"$(git rev-parse --abbrev-ref HEAD)\"" | |
pul = "!git pull origin \"$(git rev-parse --abbrev-ref HEAD)\"" | |
conflicts = !git ls-files --unmerged | cut -f2 | sort -u | |
count-conflicts = !grep -c '^=======$' | |
count-all-conflicts = !grep -c '^=======$' $(git conflicts) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment