mirror of
https://github.com/ItsDrike/dotfiles.git
synced 2024-11-10 02:39:40 +00:00
Add find and show merge commit aliases
This commit is contained in:
parent
365de49061
commit
65529ffd1d
|
@ -6,9 +6,12 @@
|
||||||
[credential]
|
[credential]
|
||||||
helper = store --file ~/.config/git/git-credentials
|
helper = store --file ~/.config/git/git-credentials
|
||||||
[alias]
|
[alias]
|
||||||
l = log --oneline --decorate --all --graph
|
l = "log --oneline --decorate --all --graph"
|
||||||
lol = log --pretty=oneline --abbrev-commit --graph
|
lol = "log --pretty=oneline --abbrev-commit --graph"
|
||||||
lg = log --all --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --
|
lg = "log --all --color --graph --pretty=format:'%Cred%h%Creset -%C(yellow)%d%Creset %s %Cgreen(%cr) %C(bold blue)<%an>%Creset' --abbrev-commit --"
|
||||||
|
find-merge = "!sh -c 'commit=$0 && branch=${1:-HEAD} && (git rev-list $commit..$branch --ancestry-path | cat -n; git rev-list $commit..$branch --first-parent | cat -n) | sort -k2 -s | uniq -f1 -d | sort -n | tail -1 | cut -f2'"
|
||||||
|
show-merge = "!sh -c 'merge=$(git find-merge $0 $1) && [ -n \"$merge\" ] && git show $merge'"
|
||||||
|
|
||||||
[merge]
|
[merge]
|
||||||
tool = meld
|
tool = meld
|
||||||
[mergetool]
|
[mergetool]
|
||||||
|
|
Loading…
Reference in a new issue