From 34af53b5ec497551e2c61c5054e296aca0e44680 Mon Sep 17 00:00:00 2001 From: mkrzewic Date: Fri, 30 May 2014 20:27:05 +0200 Subject: [PATCH] add a protection and a warning against running with bash version < 4 --- PWGPP/QA/scripts/runQA.sh | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) diff --git a/PWGPP/QA/scripts/runQA.sh b/PWGPP/QA/scripts/runQA.sh index 47f11837009..339fba07988 100755 --- a/PWGPP/QA/scripts/runQA.sh +++ b/PWGPP/QA/scripts/runQA.sh @@ -1,4 +1,9 @@ #!/bin/bash +if [ ${BASH_VERSINFO} -lt 4 ]; then + echo "bash version >= 4 needed, you have ${BASH_VERSION}, exiting..." + exit 1 +fi + main() { if [[ -z $1 ]]; then @@ -10,7 +15,7 @@ main() echo " ${0##*/} configFile=runQA.config inputList=file.list outputDirectory=%det" return 1 fi - + if ! parseConfig "$@"; then ${0} return 1 -- 2.43.0