From 0681490bedcd51ff7853c332b574f60a40d24208 Mon Sep 17 00:00:00 2001 From: Guillaume Delpierre Date: Tue, 8 Sep 2015 14:55:18 +0200 Subject: Portability --- phpmalwarefinder | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phpmalwarefinder b/phpmalwarefinder index 1fbe4cf..e127a7d 100755 --- a/phpmalwarefinder +++ b/phpmalwarefinder @@ -1,4 +1,4 @@ -#!/bin/bash +#!/usr/bin/env bash YARA=$(which yara) CONFIG_PATH='/etc/phpmalwarefinder/malwares.yara' -- cgit v1.3 From c7638eac9798ae10b1c76fe9f6e504e1a7c88f6c Mon Sep 17 00:00:00 2001 From: Guillaume Delpierre Date: Tue, 8 Sep 2015 14:56:52 +0200 Subject: Use bash builtin --- phpmalwarefinder | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/phpmalwarefinder b/phpmalwarefinder index e127a7d..6d4d047 100755 --- a/phpmalwarefinder +++ b/phpmalwarefinder @@ -1,9 +1,9 @@ #!/usr/bin/env bash -YARA=$(which yara) +YARA=$(command -v yara) CONFIG_PATH='/etc/phpmalwarefinder/malwares.yara' -IONICE_BIN=$(which ionice) -NICE_BIN=$(which nice) +IONICE_BIN=$(command -v ionice) +NICE_BIN=$(command -v nice) if [ ! -f "$YARA" ] then -- cgit v1.3 From ae011125e83c8695295b1612a428ef300b3ce095 Mon Sep 17 00:00:00 2001 From: Guillaume Delpierre Date: Tue, 8 Sep 2015 15:07:36 +0200 Subject: Typo --- phpmalwarefinder | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/phpmalwarefinder b/phpmalwarefinder index 6d4d047..d6081e1 100755 --- a/phpmalwarefinder +++ b/phpmalwarefinder @@ -81,7 +81,7 @@ fi if [ ! -e ${NICE} ] then - echo "no nice program available. Please install ionice or nice." + echo "No nice program available. Please install ionice or nice." exit 1 fi -- cgit v1.3 From 2c8a4a30946bcb1c881f417b85c96914786cf128 Mon Sep 17 00:00:00 2001 From: Guillaume Delpierre Date: Tue, 8 Sep 2015 15:28:41 +0200 Subject: Use type built-in instead of command --- phpmalwarefinder | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/phpmalwarefinder b/phpmalwarefinder index d6081e1..c49a7bd 100755 --- a/phpmalwarefinder +++ b/phpmalwarefinder @@ -1,9 +1,9 @@ #!/usr/bin/env bash -YARA=$(command -v yara) +YARA=$(type -P yara) CONFIG_PATH='/etc/phpmalwarefinder/malwares.yara' -IONICE_BIN=$(command -v ionice) -NICE_BIN=$(command -v nice) +IONICE_BIN=$(type -P ionice) +NICE_BIN=$(type -P nice) if [ ! -f "$YARA" ] then -- cgit v1.3