aboutsummaryrefslogtreecommitdiffhomepage
path: root/share/functions/help.fish
diff options
context:
space:
mode:
authorGravatar axel <axel@liljencrantz.se>2006-09-05 06:16:12 +1000
committerGravatar axel <axel@liljencrantz.se>2006-09-05 06:16:12 +1000
commit73f0d0bb488d747c7e6035338e45593a466bfde2 (patch)
tree53c6fc860b19a7f6c9438250094e6338d18e92b7 /share/functions/help.fish
parent200ebe43dcae5c8fd0dba69f9a64565d97fb49ad (diff)
Fix warning when help function is called with no arguments
darcs-hash:20060904201612-ac50b-63b83a589735021a6afd6be193500b549e3b25dd.gz
Diffstat (limited to 'share/functions/help.fish')
-rw-r--r--share/functions/help.fish8
1 files changed, 5 insertions, 3 deletions
diff --git a/share/functions/help.fish b/share/functions/help.fish
index 02f8cce5..3919a121 100644
--- a/share/functions/help.fish
+++ b/share/functions/help.fish
@@ -19,9 +19,11 @@ function help -d (N_ "Show help for the fish shell")
set -l help_topics $h expand-command-substitution expand-process
# 'help -h' should launch 'help help'
- switch $argv[1]
- case -h --h --he --hel --help
- set argv help
+ if count $argv >/dev/null
+ switch $argv[1]
+ case -h --h --he --hel --help
+ set argv help
+ end
end
#