From cf0be4349201f9f2e64b3b1dc4ebe8ae6def9588 Mon Sep 17 00:00:00 2001 From: Guillaume Lambert Date: Thu, 29 Apr 2021 14:12:24 +0200 Subject: [COMMON] Get rid of "x-hack" in shell scripts $ find . -name *.sh -print |xargs grep -l '"x'| xargs sed -i 's/"x/"/g' The "x-hack" is a historical workaround for some old UNIX shells with buggy condition comparison code. None of them is still used today. Recent POSIX specifications now guarantee it should work without it in any modern POSIX shell. More details at https://www.vidarholen.net/contents/blog/?p=1035 https://github.com/koalaman/shellcheck/wiki/SC2268 Issue-ID: OOM-2643 Signed-off-by: Guillaume Lambert Change-Id: Ic01bbc5faee9492dba5b5d4dea0f659540da2c24 --- kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'kubernetes/appc') diff --git a/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh index 717ea6679c..68b50e1ad6 100755 --- a/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh +++ b/kubernetes/appc/resources/config/appc/opt/onap/appc/bin/startODL.sh @@ -83,7 +83,7 @@ then show databases like 'sdnctl'; END ) - if [ "x${sdnc_db_exists}" = "x" ] + if [ "${sdnc_db_exists}" = "" ] then echo "Installing SDNC database" ${SDNC_HOME}/bin/installSdncDb.sh @@ -92,7 +92,7 @@ END show databases like 'appcctl'; END ) - if [ "x${appc_db_exists}" = "x" ] + if [ "${appc_db_exists}" = "" ] then echo "Installing APPC database" ${APPC_HOME}/bin/installAppcDb.sh -- cgit 1.2.3-korg