20665: Code style improvements.
authorLucas Di Pentima <lucas.dipentima@curii.com>
Mon, 26 Jun 2023 15:47:54 +0000 (12:47 -0300)
committerLucas Di Pentima <lucas.dipentima@curii.com>
Mon, 26 Jun 2023 15:47:54 +0000 (12:47 -0300)
Arvados-DCO-1.1-Signed-off-by: Lucas Di Pentima <lucas.dipentima@curii.com>

tools/salt-install/installer.sh
tools/salt-install/provision.sh

index 55cbd36d94673fec09eafa562390d30b752aeab2..b042d1a835938dc18190da240000afe61c04b0a0 100755 (executable)
@@ -127,7 +127,7 @@ deploynode() {
 }
 
 loadconfig() {
-    if [ ! -s ${CONFIG_FILE} -o ! -s ${CONFIG_FILE}.secrets ]; then
+    if [[ -s ${CONFIG_FILE} && -s ${CONFIG_FILE}.secrets ]]; then
                echo "Must be run from initialized setup dir, maybe you need to 'initialize' first?"
     fi
     source ${CONFIG_FILE}.secrets
index e438dfa77598fa2953f552269c26f5d73213a2f0..3314d04ff8af991886d8cdc2fcd7b11467e40c7e 100755 (executable)
@@ -241,7 +241,7 @@ arguments ${@}
 
 declare -A NODES
 
-if [ -s ${CONFIG_FILE} -a -s ${CONFIG_FILE}.secrets ]; then
+if [[ -s ${CONFIG_FILE} && -s ${CONFIG_FILE}.secrets ]]; then
   source ${CONFIG_FILE}.secrets
   source ${CONFIG_FILE}
 else