Fix: Update bash script syntax to comply with GHA 72/12772/1
authorJessica Wagantall <jwagantall@linuxfoundation.org>
Wed, 24 Apr 2024 16:42:37 +0000 (09:42 -0700)
committerJessica Wagantall <jwagantall@linuxfoundation.org>
Wed, 24 Apr 2024 16:42:37 +0000 (09:42 -0700)
- Update install-deb-rmr.sh script

Change-Id: I5c300d555f27017efebcf4424e0dbb643dbc3410
Signed-off-by: Jessica Wagantall <jwagantall@linuxfoundation.org>
jjb/shell/install-deb-rmr.sh

index ad24aea..dbe3522 100644 (file)
@@ -28,7 +28,7 @@ echo "---> install-deb-rmr.sh"
 set -eux
 
 version_file=rmr-version.yaml
-if [[ -f $version_file ]]; then
+if [ -f "$version_file" ]; then
     # pipeline is less elegant than yq but that requires venv and pip install
     repo=$(grep "^repo:" "$version_file" | cut -d: -f2 | xargs )
     ver=$(grep "^version:" "$version_file" | cut -d: -f2 | xargs)
@@ -36,7 +36,7 @@ else
     echo "File $version_file not found."
     exit 1
 fi
-if [[ -z $ver ]]; then
+if [ -z "$ver" ]; then
     echo "Failed to get RMR version string from file $version_file"
     exit 1
 fi