mirror of
https://github.com/fish-shell/fish-shell.git
synced 2026-05-30 11:21:15 -03:00
@@ -11,7 +11,7 @@ function __fish_print_help --description "Print help message for the specified f
|
||||
end
|
||||
|
||||
# Do nothing if the file does not exist
|
||||
if not test -e "$__fish_datadir/man/man1/$item.1" -o -e "$__fish_datadir/man/man1/$item.1.gz"
|
||||
if not test -e "$__fish_data_dir/man/man1/$item.1" -o -e "$__fish_data_dir/man/man1/$item.1.gz"
|
||||
return
|
||||
end
|
||||
|
||||
@@ -37,15 +37,15 @@ function __fish_print_help --description "Print help message for the specified f
|
||||
set cols (math $cols - 4) # leave a bit of space on the right
|
||||
set rLL -rLL=$cols[1]n
|
||||
end
|
||||
set -lx GROFF_TMAC_PATH $__fish_datadir/groff
|
||||
set -lx GROFF_TMAC_PATH $__fish_data_dir/groff
|
||||
set -l mfish
|
||||
if test -e $GROFF_TMAC_PATH/fish.tmac
|
||||
set mfish -mfish
|
||||
end
|
||||
if test -e "$__fish_datadir/man/man1/$item.1"
|
||||
set help (nroff -c -man $mfish -t $rLL "$__fish_datadir/man/man1/$item.1" ^/dev/null)
|
||||
else if test -e "$__fish_datadir/man/man1/$item.1.gz"
|
||||
set help (gunzip -c "$__fish_datadir/man/man1/$item.1.gz" ^/dev/null | nroff -c -man $mfish -t $rLL ^/dev/null)
|
||||
if test -e "$__fish_data_dir/man/man1/$item.1"
|
||||
set help (nroff -c -man $mfish -t $rLL "$__fish_data_dir/man/man1/$item.1" ^/dev/null)
|
||||
else if test -e "$__fish_data_dir/man/man1/$item.1.gz"
|
||||
set help (gunzip -c "$__fish_data_dir/man/man1/$item.1.gz" ^/dev/null | nroff -c -man $mfish -t $rLL ^/dev/null)
|
||||
end
|
||||
|
||||
# The original implementation trimmed off the top 5 lines and bottom 3 lines
|
||||
|
||||
Reference in New Issue
Block a user