[bash] opt-in for fzf completion

This commit is contained in:
odrling 2023-11-27 21:12:45 +01:00
parent 36d4e15564
commit 519a8d2b32
No known key found for this signature in database
GPG key ID: E24CA7508C27AF5B

View file

@ -34,8 +34,13 @@ complete -cf doas
if command -v fzf 2>&1 > /dev/null; then
source ~/.bash/fzf/shell/completion.bash
source ~/.bash/fzf/shell/key-bindings.bash
source ~/.bash/fzf-tab-completion/bash/fzf-bash-completion.sh
bind -x '"\t": fzf_bash_completion'
if [ -n "$FZF_COMPLETION" ]; then
source ~/.bash/fzf/shell/completion.bash
source ~/.bash/fzf-tab-completion/bash/fzf-bash-completion.sh
bind -x '"\t": fzf_bash_completion'
_fzf_bash_completion_loading_msg() { echo "${PS1@P}${READLINE_LINE}" | tail -n1; }
fi
fi
# prompt