From 7e33e13abc7019c12ab17593d92848cc412a2416 Mon Sep 17 00:00:00 2001 From: Elyrith Date: Fri, 30 Nov 2012 00:08:45 -0500 Subject: [PATCH] Increased version to 0.7 because of new "advanced" sensor parsing (line 191) -Added following line edits info to comments at the top and increased version number -Line 193, modified sensor parsing to cut after the first '+' since all positive temperatures are preceded by a + and the one we want is labeled first -Line 211, reduced "verbosity" needed to see verbose info (was 2: -v -v) -Line 229-232, now checks if no sensor data was found and exits with STATE_UNKNOWN -Fixed 2 typos, one in output and other an in-line comment -Updated line numbers in previous version info lines in comments since my comments pushed the lines down --- check_temp.sh | 23 ++++++++++++++++------- 1 file changed, 16 insertions(+), 7 deletions(-) diff --git a/check_temp.sh b/check_temp.sh index 0a6dce6..a1f28f2 100755 --- a/check_temp.sh +++ b/check_temp.sh @@ -27,9 +27,13 @@ # Version 0.2: Line 98, fixed the missing "-n" option (Thanks to Chad who # # pointed this out for me). Also added a "shopt -s extglob". (Thx to Chad) # # Version 0.5: Line 162, fixed a typo (EXIT_UNKNOWN to STATE_UNKNOWN) # +# Version 0.7: # +# Line 191, modified sensor grab from "3rd section" to "after first '+'" # +# Line 227-230, now checks if no sensor data was found and exits with # +# STATE_UNKNOWN # ############################################################################### -VERSION="Version 0.6" +VERSION="Version 0.7" AUTHOR="(c) 2011 Jack-Benny Persson (jack-benny@cyberinfo.se)" # Sensor program @@ -56,7 +60,7 @@ print_help() { print_version printf "$AUTHOR\n" - printf "Monitor temperatur with the use of sensors\n" + printf "Monitor temperature with the use of sensors\n" /bin/cat <