mirror of
https://github.com/wfxr/forgit.git
synced 2026-09-13 00:36:17 -04:00
fix: 🐛 Fix darwin compatibility on gd. #39
This commit is contained in:
parent
e1418c0402
commit
b7ef3ac3eb
|
|
@ -43,7 +43,8 @@ forgit::diff() {
|
|||
+m -0 --preview=\"$cmd\" --bind=\"enter:execute($cmd |LESS='-R' less)\"
|
||||
$FORGIT_DIFF_FZF_OPTS
|
||||
"
|
||||
eval "git diff --name-only $commit -- ${files[*]} | xargs -I% realpath --relative-to=. '$(git rev-parse --show-toplevel)/%'"|
|
||||
cmd="echo" && hash realpath &>/dev/null && cmd="realpath --relative-to=."
|
||||
eval "git diff --name-only $commit -- ${files[*]}| xargs -I% $cmd '$(git rev-parse --show-toplevel)/%'"|
|
||||
FZF_DEFAULT_OPTS="$opts" fzf
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Reference in a new issue