taolf fzfgrep fix
This commit is contained in:
parent
1b22c5ab20
commit
daccf77ffa
|
@ -26,8 +26,11 @@ cmd open ${{
|
|||
|
||||
cmd pushedit %{{
|
||||
set +u
|
||||
echo "Open: " && read files
|
||||
echo
|
||||
files=$1
|
||||
[ -z $files ] && {
|
||||
echo "Open: " && read files
|
||||
echo
|
||||
}
|
||||
echo $files | xargs -r touch
|
||||
if [ -n "$TAOLF" ]; then
|
||||
lf -remote "send $id unselect
|
||||
|
@ -162,10 +165,8 @@ cmd fzfgrep ${{
|
|||
row="$(echo "$res" | cut -d':' -f2)"
|
||||
column="$(echo "$res" | cut -d':' -f3)"
|
||||
if [ -n "$res" ]; then
|
||||
# shellcheck disable=2154
|
||||
lf -remote "send $id select '$file'"
|
||||
if [ -n "$VIM" ]; then
|
||||
lf -remote "send $id open '$file'"
|
||||
lf -remote "send $id pushedit '$file'"
|
||||
elif { [ "$EDITOR" = "nvim" ] || [ "$EDITOR" = "vim" ]; } && [ -n "$EMBEDDED" ]; then
|
||||
lf -remote "send $id \$$EDITOR +'call cursor($row, $column)' -- $([ -n "$EMBEDDED" ] && echo "--") '$file'"
|
||||
else
|
||||
|
|
Loading…
Reference in New Issue