From 1ec6b162cb4e9fb96dcc45319b62fc7e2b3c8726 Mon Sep 17 00:00:00 2001 From: Lorenz <12514511+RincewindsHat@users.noreply.github.com> Date: Fri, 7 Oct 2022 11:44:47 +0200 Subject: Replace egrep with grep -E (#1791) Replace egrep with grep -E to avoid the deprecation warnings --- plugins-scripts/check_sensors.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'plugins-scripts/check_sensors.sh') diff --git a/plugins-scripts/check_sensors.sh b/plugins-scripts/check_sensors.sh index ab4e726e..921e7b36 100755 --- a/plugins-scripts/check_sensors.sh +++ b/plugins-scripts/check_sensors.sh @@ -49,10 +49,10 @@ case "$1" in elif test "${status}" -ne 0; then text="WARNING - sensors returned state $status" exit=$STATE_WARNING - elif echo "${sensordata}" | egrep ALARM > /dev/null; then + elif echo "${sensordata}" | grep -E ALARM > /dev/null; then text="SENSOR CRITICAL - Sensor alarm detected!" exit=$STATE_CRITICAL - elif echo "${sensordata}" | egrep FAULT > /dev/null \ + elif echo "${sensordata}" | grep -E FAULT > /dev/null \ && test "$1" != "-i" -a "$1" != "--ignore-fault"; then text="SENSOR UNKNOWN - Sensor reported fault" exit=$STATE_UNKNOWN -- cgit v1.2.3-74-g34f1