Fix less again

This commit is contained in:
gitlab.com/pepa65 2021-02-27 18:49:11 +07:00
parent 8fcf07f263
commit c1e818eddb
2 changed files with 5 additions and 5 deletions

View File

@ -1,6 +1,6 @@
# tldr-bash-client # tldr-bash-client
* version 0.47 * version 0.48
### Bash client for tldr: community driven man-by-example ### Bash client for tldr: community driven man-by-example
**A fully-functional [bash](https://tiswww.case.edu/php/chet/bash/bashtop.html) **A fully-functional [bash](https://tiswww.case.edu/php/chet/bash/bashtop.html)

8
tldr
View File

@ -1,8 +1,8 @@
#!/usr/bin/env bash #!/usr/bin/env bash
set +vx -o pipefail set +vx -o pipefail
[[ $- = *i* ]] && echo "Don't source this script!" && return 1 [[ $- = *i* ]] && echo "Don't source this script!" && return 1
version='0.47' version='0.48'
# tldr-bash-client version 0.44 # tldr-bash-client version 0.48
# Bash client for tldr: community driven man-by-example # Bash client for tldr: community driven man-by-example
# - forked from Ray Lee, https://github.com/raylee/tldr # - forked from Ray Lee, https://github.com/raylee/tldr
# - modified and expanded by pepa65: https://gitlab.com/pepa65/tldr-bash-client # - modified and expanded by pepa65: https://gitlab.com/pepa65/tldr-bash-client
@ -205,7 +205,7 @@ Config(){
Init_term Init_term
[[ $TLDR_LESS = 0 ]] && [[ $TLDR_LESS = 0 ]] &&
trap 'cat <<<"$stdout"' EXIT || trap 'cat <<<"$stdout"' EXIT ||
trap 'less -~RXQFP"Browse up/down, press Q to exit " <<<"$stdout"' EXIT trap 'less -Gg -~RXQFP"Browse up/down, press Q to exit " <<<"$stdout"' EXIT
ver="tldr-bash-client version $version$XB ${URL}https://gitlab.com/pepa65/tldr-bash-client$XURL" ver="tldr-bash-client version $version$XB ${URL}https://gitlab.com/pepa65/tldr-bash-client$XURL"
@ -357,7 +357,7 @@ Display_tldr(){
done <"$1" done <"$1"
[[ $TLDR_LESS = 0 ]] && [[ $TLDR_LESS = 0 ]] &&
trap 'cat <<<"$stdout"' EXIT || trap 'cat <<<"$stdout"' EXIT ||
trap 'less +Gg -~RXQFP"%pB\% tldr $I$page$XI - browse up/down, press Q to exit" <<<"$stdout"' EXIT trap 'less -Gg -~RXQFP"%pB\% tldr $I$page$XI - browse up/down, press Q to exit" <<<"$stdout"' EXIT
} }
# $1: exit code; Uses: platform index # $1: exit code; Uses: platform index