diff options
author | Case Duckworth | 2022-04-13 17:20:13 -0500 |
---|---|---|
committer | Case Duckworth | 2022-04-13 17:20:13 -0500 |
commit | 34d6372186b79a9b1004884152ec022fa43ef81d (patch) | |
tree | 6b3248a12d35c7aa06959fa5e226055756f32f8b /bash/man.bash | |
parent | Emacs stuff (diff) | |
parent | Remove apk from sudo aliases (diff) | |
download | etc-34d6372186b79a9b1004884152ec022fa43ef81d.tar.gz etc-34d6372186b79a9b1004884152ec022fa43ef81d.zip |
Merge branch 'main' of github.com:duckwork/etc
Diffstat (limited to 'bash/man.bash')
-rw-r--r-- | bash/man.bash | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/bash/man.bash b/bash/man.bash index 4927952..5a28066 100644 --- a/bash/man.bash +++ b/bash/man.bash | |||
@@ -3,7 +3,7 @@ export MANWIDTH=80 | |||
3 | # on smaller terminals, use their width | 3 | # on smaller terminals, use their width |
4 | # (cf. https://wiki.archlinux.org/index.php/Man_page#Page_width) | 4 | # (cf. https://wiki.archlinux.org/index.php/Man_page#Page_width) |
5 | man() { | 5 | man() { |
6 | local width=$(tput cols) | 6 | local width=$COLUMNS # bashism! |
7 | [ $width -gt $MANWIDTH ] && width=$MANWIDTH | 7 | [ $width -gt $MANWIDTH ] && width=$MANWIDTH |
8 | env MANWIDTH=$width man "$@" | 8 | env MANWIDTH=$width man "$@" |
9 | } | 9 | } |