feat(gitconfig): alias hs

fix(gitconfig): alias edit-unmerged call with $EDITOR
This commit is contained in:
TheK4n 2023-01-29 16:47:44 +03:00
parent 6eabcecc5c
commit 7726504000

View File

@ -26,7 +26,6 @@
d = "!git diff --color=always | less -R"
co = checkout
ci = commit
ca = commit -a
ps = "!git push origin $(git rev-parse --abbrev-ref HEAD)"
pl = "!git pull origin $(git rev-parse --abbrev-ref HEAD)"
st = status
@ -34,8 +33,9 @@
ba = branch -a
bm = branch --merged
bn = branch --no-merged
df = "!git hist | peco | awk '{print $2}' | xargs -I {} git diff {}^ {}"
hist = log --pretty=format:\"%Cgreen%h %Creset%cd %Cblue[%cn] %Creset%s%C(yellow)%d%C(reset)\" --graph --date=relative --decorate --all --color=always
df = "!git hist | peco | awk '{print $2}' | xargs -I {} git diff {}^ {}"
hs = "!git hist | head"
llog = log --graph --name-status --pretty=format:\"%C(red)%h %C(reset)(%cd) %C(green)%an %Creset%s %C(yellow)%d%Creset\" --date=relative
open = "!hub browse"
type = cat-file -t
@ -45,10 +45,8 @@
last = log -1 HEAD
branches = branch -avv --list
# edit conflicted file on merge
edit-unmerged = "!f() { git ls-files --unmerged | cut -f2 | sort -u ; }; vim `f`"
edit-unmerged = "!f() { git ls-files --unmerged | cut -f2 | sort -u ; }; $EDITOR `f`"
# add conflicted file on merge
add-unmerged = "!f() { git ls-files --unmerged | cut -f2 | sort -u ; }; git add `f`"