From 4b6cc5fd503b6d6f2dba003965ddddbef28a63f4 Mon Sep 17 00:00:00 2001 From: David Schroeder Date: Tue, 7 Nov 2023 09:41:33 -0600 Subject: [PATCH] Update powerwall.sh --- powerwall.sh | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/powerwall.sh b/powerwall.sh index ea7a2ce6..4cf384de 100755 --- a/powerwall.sh +++ b/powerwall.sh @@ -39,6 +39,13 @@ CHECKTEMP(){ DIVIDER . yellow 90 for SENSOR in ${PW_SENSOR_ORD[@]}; do + [ "${search}" == "" ] && echo yes || echo no + [[ "${SENSOR,,}" = *"${search,,}"* ]] && echo yes || echo no + [ "${avgdays}" == "noavg" ] && echo yes || echo no + [[ "${avgdays}" =~ ^[0-9]+$ ]] && echo yes || echo no + + + if [ "${search}" == "" ] || [[ "${SENSOR,,}" = *"${search,,}"* ]] || [ "${avgdays}" == "noavg" ] || [[ "${avgdays}" =~ ^[0-9]+$ ]]; then if [ "${PW_SENSOR_TYPE[${SENSOR}]}" == "esxi" ]; then