From e966123170588c281952f5185f9265593c35dd5f Mon Sep 17 00:00:00 2001 From: Tobias Schmidl Date: Wed, 12 Jul 2023 08:37:25 +0200 Subject: [PATCH] fzf.zsh: Bugfix for termux --- fzf.zsh | 12 ++++++++++-- 1 file changed, 10 insertions(+), 2 deletions(-) diff --git a/fzf.zsh b/fzf.zsh index 9ff9b0f..a0ff03a 100644 --- a/fzf.zsh +++ b/fzf.zsh @@ -1,6 +1,14 @@ export FZF_COMPLETION_OPTS='--border --info=inline' -source /usr/share/doc/fzf/examples/completion.zsh -source /usr/share/doc/fzf/examples/key-bindings.zsh + +if [ -n "$TERMUX_VERSION" ] && [ -d "$PREFIX" ]; +then + source "$PREFIX/share/fzf/completion.zsh" + source "$PREFIX/share/fzf/key-bindings.zsh" +else + source /usr/share/doc/fzf/examples/completion.zsh + source /usr/share/doc/fzf/examples/key-bindings.zsh +fi + # (EXPERIMENTAL) Advanced customization of fzf options via _fzf_comprun function # - The first argument to the function is the name of the command. # - You should make sure to pass the rest of the arguments to fzf.