summaryrefslogtreecommitdiff
path: root/plugins/fzf/fzf.plugin.zsh
diff options
context:
space:
mode:
authorMarc Cornellà <marc.cornella@live.com>2019-10-15 16:51:51 +0200
committerGitHub <noreply@github.com>2019-10-15 16:51:51 +0200
commitf56b678888c0ad4ac71458680d75d88b442cf09b (patch)
treece7695efffa5f200fe354423a6660933027f8bee /plugins/fzf/fzf.plugin.zsh
parent52f58785645c18aa88ea515d070a42bcfe97508d (diff)
downloadzsh-f56b678888c0ad4ac71458680d75d88b442cf09b.tar.gz
zsh-f56b678888c0ad4ac71458680d75d88b442cf09b.tar.bz2
zsh-f56b678888c0ad4ac71458680d75d88b442cf09b.zip
fzf: check for dpkg before checking for fzf in debian
Fixes #8253 Co-authored-by: Mariusz B <mb@binary-offensive.com>
Diffstat (limited to 'plugins/fzf/fzf.plugin.zsh')
-rw-r--r--plugins/fzf/fzf.plugin.zsh12
1 files changed, 6 insertions, 6 deletions
diff --git a/plugins/fzf/fzf.plugin.zsh b/plugins/fzf/fzf.plugin.zsh
index 646148297..f701fdf32 100644
--- a/plugins/fzf/fzf.plugin.zsh
+++ b/plugins/fzf/fzf.plugin.zsh
@@ -1,9 +1,9 @@
function setup_using_base_dir() {
- # Declare all variables local not no mess with outside env in any way
- local fzf_base
- local fzf_shell
- local fzfdirs
- local dir
+ # Declare all variables local not no mess with outside env in any way
+ local fzf_base
+ local fzf_shell
+ local fzfdirs
+ local dir
test -d "${FZF_BASE}" && fzf_base="${FZF_BASE}"
@@ -58,7 +58,7 @@ function setup_using_base_dir() {
function setup_using_debian_package() {
- dpkg -s fzf &> /dev/null
+ (( $+command[dpkg] )) && dpkg -s fzf &> /dev/null
if (( $? )); then
# Either not a debian based distro, or no fzf installed. In any case skip ahead
return 1