[bash] Use command \find for ALT-C

ALT-C can fail with the following aliases as pointed out in #272

    alias find='noglob find'
    alias command='command '
This commit is contained in:
Junegunn Choi 2015-06-25 23:54:05 +09:00
parent 5254ee2e2a
commit 56100f0fa7

View File

@ -29,7 +29,7 @@ __fzf_select_tmux__() {
__fzf_cd__() { __fzf_cd__() {
local dir local dir
dir=$(command find -L ${1:-.} \( -path '*/\.*' -o -fstype 'dev' -o -fstype 'proc' \) -prune \ dir=$(command \find -L ${1:-.} \( -path '*/\.*' -o -fstype 'dev' -o -fstype 'proc' \) -prune \
-o -type d -print 2> /dev/null | sed 1d | cut -b3- | $(__fzfcmd) +m) && printf 'cd %q' "$dir" -o -type d -print 2> /dev/null | sed 1d | cut -b3- | $(__fzfcmd) +m) && printf 'cd %q' "$dir"
} }