From 34a86c50149c73cf6aad520c1bebe407138e4d96 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Sat, 3 Sep 2022 11:37:38 -0500 Subject: [PATCH] Update powerwall.sh --- powerwall.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/powerwall.sh b/powerwall.sh index 7b9994f1..931e4640 100755 --- a/powerwall.sh +++ b/powerwall.sh @@ -22,8 +22,8 @@ CHECKTEMP(){ temp_f=`echo "scale=2; $temp_c*1.8 + 32" | bc` #echo "$temp_c -> $temp_f" - temp_warn=${TEMP_THRESHOLDS[${1}]} - echo $temp_warn | cut -d',' -f 1 + echo ${TEMP_THRESHOLDS[${1}]} | cut -d',' -f 1 | read temp_warn + echo ${TEMP_THRESHOLDS[${1}]} | cut -d',' -f 2 | read temp_crit if [ $temp_f -ge ${TEMP_THRESHOLDS[${1}]['warn']} ] && [ $temp_f -lt ${TEMP_THRESHOLDS[${1}]['crit']} ]; then echo "WARNING: $temp_f"