Created
February 25, 2015 03:58
-
-
Save jfryman/487095e5addafb093c24 to your computer and use it in GitHub Desktop.
This file contains 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
root = !pwd | |
s = status -su | |
lol = log --graph --decorate --pretty=oneline --abbrev-commit | |
lola = log --graph --decorate --pretty=oneline --abbrev-commit --all | |
ls = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate | |
ll = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --numstat | |
lnc = log --pretty=format:"%h\\ %s\\ [%cn]" | |
ld = log --pretty=format:"%C(yellow)%h\\ %ad%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --date=relative | |
lds = log --pretty=format:"%C(yellow)%h\\ %ad%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --date=short | |
filelog = log -u | |
fl = log -u | |
dl = "!git ll -1" | |
dlc = diff --cached HEAD^ | |
f = "!git ls-files | grep -i" | |
grep = grep -Ii | |
gr = grep -Ii | |
la = "!git config -l | grep alias | cut -c 7-" | |
assume = update-index --assume-unchanged | |
unassume = update-index --no-assume-unchanged | |
assumed = "!git ls-files -v | grep ^h | cut -c 3-" | |
unassumeall = "!git assumed | xargs git update-index --no-assume-unchanged" | |
assumeall = "!git st -s | awk {'print $2'} | xargs git assume" | |
lasttag = describe --tags --abbrev=0 | |
lt = describe --tags --abbrev=0 | |
ours = "!f() { git co --ours $@ && git add $@; }; f" | |
theirs = "!f() { git co --theirs $@ && git add $@; }; f" | |
cp = cherry-pick | |
st = status -s | |
cl = clone | |
ci = commit | |
co = checkout | |
br = branch | |
diff = diff --word-diff | |
dc = diff --cached | |
r = reset | |
r1 = reset HEAD^ | |
r2 = reset HEAD^^ | |
rh = reset --hard | |
rh1 = reset HEAD^ --hard | |
rh2 = reset HEAD^^ --hard | |
this = "!git init && git add . && git commit -m \"initial commit\"" | |
amend = "!git log -n 1 --pretty=tformat:%s%n%nb | git commit -F - --amend" | |
r = "!git ls-files -z --deleted | xargs -0 git rm" | |
ignore = "!gi() { curl -L -s https://www.gitignore.io/api/$@ ;}; gi" | |
up = "!git pull --rebase --prune $@ && git submodule update --init --recursive" | |
cob = checkout -b | |
cm = "!git add -A && git commit -m" | |
save = "!git add -A && git commit -m 'SAVEPOINT'" | |
wip = "!git add -u && git commit -m 'WIP'" | |
undo = reset HEAD~1 --mixed | |
wipe = "!git add -A && git commit -qm 'WIPE SAVEPOINT' && git reset HEAD~1 --hard" | |
bclean = "!f() { git branch --merged ${1-master} | grep -v " ${1-master}$" | xargs -r git branch -d; }; f" | |
bdone = "!f() { git checkout ${1-master} && git up && git bclean ${1-master}; }; f" |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment