From 7faf9f3e09073f82f042ae78af28cc5ee86d09e3 Mon Sep 17 00:00:00 2001 From: Steven Foerster Date: Mon, 1 Mar 2021 21:21:58 -0500 Subject: [PATCH] bash logic --- scripts/env/suricata_init.sh | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/scripts/env/suricata_init.sh b/scripts/env/suricata_init.sh index 4dd3590..f02057c 100755 --- a/scripts/env/suricata_init.sh +++ b/scripts/env/suricata_init.sh @@ -3,7 +3,7 @@ set -e # detect if suricata is installed -if [[ ! $(dpkg-query -W -f='${Status}' suricata 2>/dev/null | grep -c "ok installed") ]]; then +if [[ $(dpkg-query -W -f='${Status}' suricata 2>/dev/null | grep -c "ok installed") -eq 1 ]]; then echo "Installed" exit 0 fi