From: Simon Ruderich Date: Thu, 2 Jan 2020 15:19:19 +0000 (+0100) Subject: htoprc: automatically switch to 4-column CPU layout X-Git-Url: https://ruderich.org/simon/gitweb/?a=commitdiff_plain;h=873ae3e69abd451545ec860598dcd0ec21881ca1;p=config%2Fdotfiles.git htoprc: automatically switch to 4-column CPU layout --- diff --git a/shell/setup.sh b/shell/setup.sh index e8cff62..9f622f7 100755 --- a/shell/setup.sh +++ b/shell/setup.sh @@ -233,6 +233,9 @@ fi # Htop overwrites the comments in its configuration file. generate htoprc .in cat +if installed nproc && test "$(nproc)" -gt 8; then + sed_i 's/LeftCPUs/LeftCPUs2/; s/RightCPUs/RightCPUs2/' htoprc +fi if installed dig; then # dig doesn't support any comments in digrc.