diff options
Diffstat (limited to 'shell/completion.bash')
-rw-r--r-- | shell/completion.bash | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/shell/completion.bash b/shell/completion.bash index 5d82b656..1af17698 100644 --- a/shell/completion.bash +++ b/shell/completion.bash @@ -47,7 +47,7 @@ __fzf_comprun() { } __fzf_orig_completion_filter() { - sed 's/^\(.*-F\) *\([^ ]*\).* \([^ ]*\)$/export _fzf_orig_completion_\3="\1 %s \3 #\2"; [[ "\1" = *" -o nospace "* ]] \&\& [[ ! "$__fzf_nospace_commands" = *" \3 "* ]] \&\& __fzf_nospace_commands="$__fzf_nospace_commands \3 ";/' | + sed '/ -F/!d; / _fzf/d; s/^\(.*-F\) *\([^ ]*\).* \([^ ]*\)$/export _fzf_orig_completion_\3="\1 %s \3 #\2"; [[ "\1" = *" -o nospace "* ]] \&\& [[ ! "$__fzf_nospace_commands" = *" \3 "* ]] \&\& __fzf_nospace_commands="$__fzf_nospace_commands \3 ";/' | awk -F= '{OFS = FS} {gsub(/[^A-Za-z0-9_= ;]/, "_", $1);}1' } @@ -307,7 +307,7 @@ a_cmds=" # Preserve existing completion eval "$(complete | - sed -E '/-F/!d; / _fzf/d; '"/ ($(echo $d_cmds $a_cmds | sed 's/ /|/g; s/+/\\+/g'))$/"'!d' | + sed -E "/ ($(echo $d_cmds $a_cmds | sed 's/ /|/g; s/+/\\+/g'))$/"'!d' | __fzf_orig_completion_filter)" if type _completion_loader > /dev/null 2>&1; then @@ -353,7 +353,7 @@ _fzf_setup_completion() { return 1 fi shift - eval "$(complete -p "$@" 2> /dev/null | sed '/-F/!d; / _fzf/d' | __fzf_orig_completion_filter)" + eval "$(complete -p "$@" 2> /dev/null | __fzf_orig_completion_filter)" for cmd in "$@"; do case "$kind" in dir) __fzf_defc "$cmd" "$fn" "-o nospace -o dirnames" ;; |