From a5c8021cb1f2ef7fca7422f4769eebf1239b7318 Mon Sep 17 00:00:00 2001 From: Pulse Monitor Date: Sun, 24 Aug 2025 16:16:48 +0000 Subject: [PATCH] fix: ensure RC version variable is properly initialized Initialize RC_VERSION to empty string before assignment to prevent 'unbound variable' errors when running with set -u. This ensures the RC update option is shown when running a stable version. --- install.sh | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/install.sh b/install.sh index 480709a9e..ba02fb23b 100755 --- a/install.sh +++ b/install.sh @@ -908,7 +908,8 @@ main() { fi # For RC, we need the API, so if it fails just use empty - local RC_VERSION=$(curl -s https://api.github.com/repos/$GITHUB_REPO/releases | grep '"tag_name":' | head -1 | sed -E 's/.*"([^"]+)".*/\1/' 2>/dev/null || true) + local RC_VERSION="" + RC_VERSION=$(curl -s https://api.github.com/repos/$GITHUB_REPO/releases 2>/dev/null | grep '"tag_name":' | head -1 | sed -E 's/.*"([^"]+)".*/\1/' || true) # Determine default update channel UPDATE_CHANNEL="stable"