Fix a bug in the help function causing help to fail when trying to open help for a builtin command. Thanks to Reuben Thomas for the report.

darcs-hash:20061107131211-ac50b-9727a813d940b34923b23b073c80a7b42c023486.gz
This commit is contained in:
axel 2006-11-07 23:12:11 +10:00
parent d20c14b4bb
commit dc90e460fe

View file

@ -75,17 +75,15 @@ function help -d (N_ "Show help for the fish shell")
case ""
set fish_help_page index.html
case "."
set fish_help_page "builtins.html\#source"
set fish_help_page "commands.html\#source"
case difference
set fish_help_page difference.html
case globbing
set fish_help_page "index.html\#expand"
case (builtin -n)
set fish_help_page "builtins.html\#$fish_help_item"
# This command substitution should locate all commands with
# documentation. It's a bit of a hack, since it relies on the
# Doxygen markup format to never change...
# Doxygen markup format to never change.
case (sed -n < $__fish_help_dir/commands.html -e "s/.*<h2><a class=\"anchor\" name=\"\([^\"]*\)\">.*/\1/p")
set fish_help_page "commands.html\#$fish_help_item"