check_sensors.sh: [ShellCheck](http://www.shellcheck.net/) fails (#1368)

waja notifications at github.com
Mon Oct 5 12:16:45 CEST 2015


Running '$ shellcheck plugins-scripts/check_sensors.sh' results into the
following:

In plugins-scripts/check_sensors.sh line 3:
PATH="@TRUSTED_PATH@"
^-- SC2123: PATH is the shell search path. Use another name.

In plugins-scripts/check_sensors.sh line 5:
PROGNAME=`basename $0`
         ^-- SC2006: Use $(..) instead of legacy `..`.
                   ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 6:
PROGPATH=`echo $0 | sed -e 's,[\\/][^\\/][^\\/]*$,,'`
         ^-- SC2006: Use $(..) instead of legacy `..`.
               ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 9:
. $PROGPATH/utils.sh
  ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 16:
	print_revision $PROGNAME $REVISION
                       ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 23:
	exit $STATE_OK
             ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 29:
		exit $STATE_OK
                     ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 33:
		exit $STATE_OK
                     ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 36:
		print_revision $PROGNAME $REVISION
                               ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 37:
		exit $STATE_OK
                     ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 40:
		print_revision $PROGNAME $REVISION
                               ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 41:
		exit $STATE_OK
                     ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 44:
		sensordata=`sensors 2>&1`
                           ^-- SC2006: Use $(..) instead of legacy `..`.

In plugins-scripts/check_sensors.sh line 52:
		elif echo ${sensordata} | egrep ALARM > /dev/null; then
                          ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 55:
		elif echo ${sensordata} | egrep FAULT > /dev/null \
                          ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 66:
			echo ${sensordata}
                             ^-- SC2086: Double quote to prevent globbing and word splitting.

In plugins-scripts/check_sensors.sh line 68:
		exit $exit
                     ^-- SC2086: Double quote to prevent globbing and word splitting.

-- 
Reply to this email on GitHub:
https://github.com/monitoring-plugins/monitoring-plugins/issues/1368
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <https://www.monitoring-plugins.org/archive/devel/attachments/20151005/1262ec9e/attachment.html>


More information about the Devel mailing list