fix(swaybar): adapt thermal warnings to real-life conditions
This commit is contained in:
parent
f07c8aee32
commit
9c2358068d
1 changed files with 3 additions and 3 deletions
|
|
@ -32,13 +32,13 @@ common() {
|
|||
temp_cpu() {
|
||||
local name="cpu"
|
||||
local cpu=$(expr $(cat /sys/class/thermal/thermal_zone2/temp) / 1000)
|
||||
if [[ $(echo "$cpu >= 55" | bc -l ) == "1" ]] && [[ $(echo "$cpu < 65" | bc -l ) == "1" ]]; then
|
||||
if [[ $(echo "$cpu >= 60" | bc -l ) == "1" ]] && [[ $(echo "$cpu < 70" | bc -l ) == "1" ]]; then
|
||||
local bg=$warn1
|
||||
local fg=$text_dark
|
||||
elif [[ $(echo "$cpu >= 65" | bc -l ) == "1" ]] && [[ $(echo "$cpu < 75" | bc -l ) == "1" ]]; then
|
||||
elif [[ $(echo "$cpu >= 70" | bc -l ) == "1" ]] && [[ $(echo "$cpu < 80" | bc -l ) == "1" ]]; then
|
||||
local bg=$warn2
|
||||
local fg=$text_dark
|
||||
elif [[ $(echo "$cpu >= 75" | bc -l ) == "1" ]]; then
|
||||
elif [[ $(echo "$cpu >= 80" | bc -l ) == "1" ]]; then
|
||||
local bg=$crit
|
||||
local fg=$text_light
|
||||
else
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue