mirror of
https://github.com/fish-shell/fish-shell
synced 2024-12-26 04:43:10 +00:00
Check documentation for listing of external commands instead of relying on out of date static lists in various places
darcs-hash:20060529133239-ac50b-48392cfa1e5817ed8df452f0632658af7fe47a28.gz
This commit is contained in:
parent
4c7e06e752
commit
29cd62ab6e
2 changed files with 7 additions and 2 deletions
|
@ -6,7 +6,7 @@ for i in (builtin -n)
|
|||
complete -c help -x -a $i -d (N_ "Help for the specified builtin")
|
||||
end
|
||||
|
||||
for i in count dirh dirs help mimedb nextd open popd prevd pushd set_color psub umask type
|
||||
for i in case (sed -n < /usr/share/doc/fish-1.21.7/commands.html -e "s/.*<h2><a class=\"anchor\" name=\"\([^\"]*\)\">.*/\1/p")
|
||||
complete -c help -x -a $i -d (N_ "Help for the specified command")
|
||||
end
|
||||
|
||||
|
|
|
@ -74,7 +74,12 @@ function help -d (N_ "Show help for the fish shell")
|
|||
set fish_help_page "index.html\#expand"
|
||||
case (builtin -n)
|
||||
set fish_help_page "builtins.html\#$fish_help_item"
|
||||
case contains count dirh dirs help mimedb nextd open popd prevd pushd set_color tokenize psub umask type vared
|
||||
|
||||
# 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...
|
||||
|
||||
case (sed -n < /usr/share/doc/fish-1.21.7/commands.html -e "s/.*<h2><a class=\"anchor\" name=\"\([^\"]*\)\">.*/\1/p")
|
||||
set fish_help_page "commands.html\#$fish_help_item"
|
||||
case $help_topics
|
||||
set fish_help_page "index.html\#$fish_help_item"
|
||||
|
|
Loading…
Reference in a new issue