From a91d2633162c47bc1caf16422dada7eaa1ac5fe4 Mon Sep 17 00:00:00 2001 From: zontreck Date: Sat, 23 Nov 2024 02:16:53 -0700 Subject: [PATCH] Switch to an eval statement --- installscript.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/installscript.sh b/installscript.sh index abc60c4..4ef3f55 100644 --- a/installscript.sh +++ b/installscript.sh @@ -23,7 +23,7 @@ else exit 1 fi - SUDO_CMD="echo \"$PASS\" | sudo -S" + SUDO_CMD="echo $PASS | sudo -S" fi # Function to download a file with retry logic @@ -34,7 +34,7 @@ download_with_retry() { local attempt=1 while [ $attempt -le $max_retries ]; do - $SUDO_CMD wget "$url" -O "$output" + eval "$SUDO_CMD wget \"$url\" -O \"$output\"" # Check if the download was successful and the file is not empty if [ -s "$output" ]; then