Update temp.inc.sh
This commit is contained in:
@@ -87,10 +87,8 @@ CHECKTEMP(){
|
|||||||
if [ "${avgdays}" != "noavg" ]; then
|
if [ "${avgdays}" != "noavg" ]; then
|
||||||
if [ $(bc -l <<< "${avgdays} < 1") -eq 1 ]; then
|
if [ $(bc -l <<< "${avgdays} < 1") -eq 1 ]; then
|
||||||
avgdays_disp="$(ROUND_NUMBER $(bc <<< "scale=2; ${avgdays}*24")) Hour"
|
avgdays_disp="$(ROUND_NUMBER $(bc <<< "scale=2; ${avgdays}*24")) Hour"
|
||||||
elif [ $(bc -l <<< "${avgdays} = 1") -eq 1 ]; then
|
|
||||||
avgdays_disp="${avgdays} Day"
|
|
||||||
else
|
else
|
||||||
avgdays_disp="${avgdays} Days"
|
avgdays_disp="${avgdays} Day"
|
||||||
fi
|
fi
|
||||||
echo -en "Pulling data and calculating ${avgdays} Day average ... "
|
echo -en "Pulling data and calculating ${avgdays} Day average ... "
|
||||||
else
|
else
|
||||||
@@ -231,7 +229,7 @@ CHECKTEMPSENSOR(){
|
|||||||
c=0; spc=''; spc1=`expr 12 - ${#tmp}`; until [ ${c} = ${spc1} ]; do spc="${spc} "; c=`expr ${c} + 1`; done
|
c=0; spc=''; spc1=`expr 12 - ${#tmp}`; until [ ${c} = ${spc1} ]; do spc="${spc} "; c=`expr ${c} + 1`; done
|
||||||
[ ${#temp_warn} == 2 ] && spcw=' ' || spcw=' '
|
[ ${#temp_warn} == 2 ] && spcw=' ' || spcw=' '
|
||||||
[ ${#temp_crit} == 2 ] && spcc=' ' || spcc=' '
|
[ ${#temp_crit} == 2 ] && spcc=' ' || spcc=' '
|
||||||
echo -e "${spc}[${spcw}${idsCL[Yellow]}${temp_warn_disp}${GAUGESH}${idsCL[Default]} /${spcc}${idsCL[LightRed]}${temp_crit_disp}${GAUGESH}=>${idsCL[Default]} ]"
|
echo -e "${idsCL[Default]}${spc}[${spcw}${idsCL[Yellow]}${temp_warn_disp}${GAUGESH}${idsCL[Default]} /${spcc}${idsCL[LightRed]}${temp_crit_disp}${GAUGESH}=>${idsCL[Default]} ]"
|
||||||
|
|
||||||
# if [ "${PW_SENSOR_TYPE[${1}]}" == "lacrosse" ]; then
|
# if [ "${PW_SENSOR_TYPE[${1}]}" == "lacrosse" ]; then
|
||||||
# temp_probe_f=$(bc <<< "scale=2; ${temp_probe_c}*1.8+32")
|
# temp_probe_f=$(bc <<< "scale=2; ${temp_probe_c}*1.8+32")
|
||||||
|
|||||||
Reference in New Issue
Block a user