dotfiles

configuration files for shell, text editor, graphical environment, etc.
git clone git://src.adamsgaard.dk/dotfiles
Log | Files | Refs | README | LICENSE Back to index

commit 6c00cd38204c430b86d123d0100fc87ba9a8e085
parent a1ab7a1b519dcedd00cb53a05dc0ae7435739762
Author: Anders Damsgaard <anders@adamsgaard.dk>
Date:   Thu,  1 Oct 2020 09:39:53 +0200

temptest: simplify output formatting

Diffstat:
M.local/bin/temptest | 5++---
1 file changed, 2 insertions(+), 3 deletions(-)

diff --git a/.local/bin/temptest b/.local/bin/temptest @@ -37,8 +37,7 @@ show_temp() { load="$(uptime | sed 's/.*: //')" temp="$(get_temp)" cpuspeed="$(get_speed)" - printf '\r ' - printf '\r%s\t%.4s C\t%s MHz\n' "$load" "$temp" "$cpuspeed" + printf '%s\t%.4s C\t%s MHz\n' "$load" "$temp" "$cpuspeed" } n_cores="$(get_ncpu)" @@ -48,10 +47,10 @@ else label="cpu" fi +printf 'stressing %s %s...\n' "$n_cores" "$label" i=1 while [ $i -le 5 ]; do show_temp - printf 'stressing %s %s...' "$n_cores" "$label" stress -c "$n_cores" -t 120s >/dev/null i=$(( i + 1 )) done