diff --git a/share/functions/__fish_paginate.fish b/share/functions/__fish_paginate.fish index f7c888a37..696c6137a 100644 --- a/share/functions/__fish_paginate.fish +++ b/share/functions/__fish_paginate.fish @@ -2,7 +2,7 @@ function __fish_paginate -d "Paginate the current command using the users defaul set -l cmd less if set -q PAGER - set cmd $PAGER + echo $PAGER | read -at cmd end if test -z (commandline -j | string join '') diff --git a/share/functions/__fish_print_help.fish b/share/functions/__fish_print_help.fish index beaf6b9fc..55aa628c1 100644 --- a/share/functions/__fish_print_help.fish +++ b/share/functions/__fish_print_help.fish @@ -110,7 +110,7 @@ function __fish_print_help --description "Print help message for the specified f begin set -l pager less set -q PAGER - and set pager $PAGER + and echo $PAGER | read -at pager not isatty stdout and set pager cat # cannot use a builtin here # similar to man, but add -F to quit paging when the help output is brief (#6227) diff --git a/share/functions/history.fish b/share/functions/history.fish index 65856a89f..355d45147 100644 --- a/share/functions/history.fish +++ b/share/functions/history.fish @@ -86,7 +86,7 @@ function history --description "display or manipulate interactive command histor if isatty stdout set -l pager less set -q PAGER - and set pager $PAGER + and echo $PAGER | read -at pager # If the user hasn't preconfigured less with the $LESS environment variable, # we do so to have it behave like cat if output fits on one screen. Prevent the