From 3edac36e3832858b890a416bf5e6c98917fba390 Mon Sep 17 00:00:00 2001 From: Jorge Bucaran Date: Thu, 14 Jan 2021 20:58:35 +0900 Subject: [PATCH] Better error message on no fish_plugins (#646) --- fisher.fish | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/fisher.fish b/fisher.fish index 9e26d92..d9210b2 100644 --- a/fisher.fish +++ b/fisher.fish @@ -27,8 +27,10 @@ function fisher -a cmd -d "Fish plugin manager" set --local new_plugins if ! set --query argv[2] - if test "$cmd" != update || test ! -e $fish_plugins + if test "$cmd" != update echo "fisher: Not enough arguments for command: \"$cmd\"" >&2 && return 1 + else if test ! -e $fish_plugins + echo "fisher: fish_plugins file not found: \"$cmd\"" >&2 && return 1 end set arg_plugins (string match --regex --invert '^\s*$' -- <$fish_plugins) end