diff options
author | Tavian Barnes <tavianator@tavianator.com> | 2023-10-20 15:56:55 -0400 |
---|---|---|
committer | Tavian Barnes <tavianator@tavianator.com> | 2023-10-20 15:56:55 -0400 |
commit | dd8ac68070176343a8781e67de4bbd6a071bb89d (patch) | |
tree | d6e730a2c49d338e706973c0857e63b2f94ea355 /tests | |
parent | 60366e4583a1d148dd5f8171c9148ebb98890478 (diff) | |
download | bfs-dd8ac68070176343a8781e67de4bbd6a071bb89d.tar.xz |
tests: Fix column detection with redirected stderr
Diffstat (limited to 'tests')
-rw-r--r-- | tests/run.sh | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/run.sh b/tests/run.sh index 5fcccad..7b7fe24 100644 --- a/tests/run.sh +++ b/tests/run.sh @@ -14,7 +14,7 @@ update_eol() { # Bash gets $COLUMNS from stderr, so if it's redirected use tput instead local cols="${COLUMNS-}" if [ -z "$cols" ]; then - cols=$(tput cols) + cols=$(tput cols 2>/dev/tty) fi # Put the cursor at the last column, then write a space so the next |