mcfly-fzf
mcfly-fzf copied to clipboard
Make use of fzf-tmux
Please make use of the __fzfcmd
function as used in junegunn/fzf/shell/key-bindings.fish
function __fzfcmd
test -n "$FZF_TMUX"; or set FZF_TMUX 0
test -n "$FZF_TMUX_HEIGHT"; or set FZF_TMUX_HEIGHT 40%
if [ -n "$FZF_TMUX_OPTS" ]
echo "fzf-tmux $FZF_TMUX_OPTS -- "
else if [ $FZF_TMUX -eq 1 ]
echo "fzf-tmux -d$FZF_TMUX_HEIGHT -- "
else
echo "fzf"
end
end
I'm not very familiar with fish scripting, but it seems to me that we need to make some modifications to this line:
eval $MCFLY_FZF_PATH --history-format fish dump --header -0 --options-json $MCFLY_FZF_OPTS | eval fzf -q '(commandline)' |
where eval fzf
needs to be eval (__fzfcmd)
.
This is for fish
, and similar changes would need to be made for bash
and zsh
as well.