[install] Avoid generating empty component in $PATH

Fix #1517
This commit is contained in:
Junegunn Choi 2019-03-08 12:38:36 +09:00
parent 85c1f8a9e0
commit 4f8bf2ae78
No known key found for this signature in database
GPG Key ID: 254BC280FEF9C627

View File

@ -272,7 +272,7 @@ for shell in $shells; do
# Setup fzf
# ---------
if [[ ! "\$PATH" == *$fzf_base_esc/bin* ]]; then
export PATH="\$PATH:$fzf_base/bin"
export PATH="\${PATH:+\${PATH}:}$fzf_base/bin"
fi
# Auto-completion
@ -282,7 +282,6 @@ $fzf_completion
# Key bindings
# ------------
$fzf_key_bindings
EOF
echo "OK"
done