From 12dcb4226e2df849100b2b3850afe993244fb3e9 Mon Sep 17 00:00:00 2001 From: Hendrik Jaeger Date: Tue, 24 Nov 2020 00:16:11 +0100 Subject: Reorder simple aliases --- .config/git/config | 117 +++++++++++++++++++++++++++++++---------------------- 1 file changed, 68 insertions(+), 49 deletions(-) (limited to '.config/git') diff --git a/.config/git/config b/.config/git/config index f39ca0a..c2c48be 100644 --- a/.config/git/config +++ b/.config/git/config @@ -40,61 +40,83 @@ enabled = false [alias] -# basic {{{ - pl = pull - pla = pull --all - ps = push - st = status -s - cl = clone - ci = commit - co = checkout - cob = checkout -b - br = branch - r = reset - cp = cherry-pick - gr = grep -Ii - please = push --force-with-lease - diff = diff --word-diff - branch = branch -ra - grep = grep -Ii - bra = branch -ra - a = add + a = add ap = add -p ai = add --interactive - # grep on filename - f = "!git ls-files | grep -i" - cm = commit -m - cma = commit -a -m - cmv = commit -a -v - ca = commit --amend + + b = branch + br = branch + branch = branch -ra + bra = branch -ra + + co = checkout + cob = checkout -b + + cp = cherry-pick + cpa = cherry-pick --abort + cpc = cherry-pick --continue + + ci = commit + cm = commit -m + cma = commit -a -m + cmv = commit -a -v + ca = commit --amend amend = commit --amend - caa = commit -a --amend -C HEAD - fix = commit -a --fixup - ls = log --pretty=format:"%C(green)%h\\ %C(yellow)[%ad]%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --date=relative - ll = log --pretty=format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --numstat - lc = "!f() { git ll "$1"^.."$1"; }; f" - lnc = log --pretty=format:"%h\\ %s\\ [%cn]" - fl = log -u + caa = commit -a --amend -C HEAD + fix = commit -a --fixup + + diff = diff --word-diff + d = diff --word-diff + dc = diff --cached + dlc = diff --cached HEAD^ + dr = "!f() { git diff -w "$1"^.."$1"; }; f" + diffr = "!f() { git diff "$1"^.."$1"; }; f" + + gr = grep -Ii + grep = grep -Ii + + ls = log --pretty = format:"%C(green)%h\\ %C(yellow)[%ad]%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --date = relative + ll = log --pretty = format:"%C(yellow)%h%Cred%d\\ %Creset%s%Cblue\\ [%cn]" --decorate --numstat + lnc = log --pretty = format:"%h\\ %s\\ [%cn]" + fl = log -u filelog = log -u - lg = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit - lga = log --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --all - d = diff --word-diff - dc = diff --cached - # diff last commit - dlc = diff --cached HEAD^ - dr = "!f() { git diff -w "$1"^.."$1"; }; f" - diffr = "!f() { git diff "$1"^.."$1"; }; f" - r1 = reset HEAD^ - r2 = reset HEAD^^ - rh = reset --hard + lg = log --graph --pretty = format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit + lga = log --graph --pretty = format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --all + # tag logs + taglog = "log --tags --simplify-by-decoration --pretty='format:%ci %d'" + + pl = pull + pla = pull --all + + ps = push + please = push --force-with-lease + + rem = remote + + rb = rebase + rba = rebase --abort + rbc = rebase --continue + + r = reset + r1 = reset HEAD^ + r2 = reset HEAD^^ + rh = reset --hard rh1 = reset HEAD^ --hard rh2 = reset HEAD^^ --hard - svnr = svn rebase - svnd = svn dcommit - svnl = svn log --oneline --show-commit + sl = stash list sa = stash apply ss = stash save + + s = status -s + st = status -s + + # grep on filename + f = "!git ls-files | grep -i" + lc = "!f() { git ll "$1"^.."$1"; }; f" + svnr = svn rebase + svnd = svn dcommit + svnl = svn log --oneline --show-commit assume = update-index --assume-unchanged unassume = update-index --no-assume-unchanged # show assumed files @@ -110,9 +132,6 @@ lasttag = "describe --tags --abbrev=0" lt = "describe --tags --abbrev=0" - # tag logs - taglog = "log --tags --simplify-by-decoration --pretty='format:%ci %d'" - # conflict/merges ours = "!f() { git co --ours $@ && git add $@; }; f" theirs = "!f() { git co --theirs $@ && git add $@; }; f" -- cgit v1.2.3