From 75eb42b9efb1401d421f011224aa1ed59044c26f Mon Sep 17 00:00:00 2001 From: Nithin Puthenveettil Date: Wed, 24 Apr 2024 11:04:28 +0530 Subject: [PATCH] Updated the currency automation script to accommodate capital letters in the package URL. --- version_updater.sh | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/version_updater.sh b/version_updater.sh index 0c502edda..ae2360319 100755 --- a/version_updater.sh +++ b/version_updater.sh @@ -27,9 +27,10 @@ find_latest_version() { if [ -n "$pkg" ]; then # Query the latest version for the package local url="https://proxy.golang.org/${pkg}/@latest" - echo $url - curl -s "$url" - LATEST_VERSION=$(curl -s "$url" | jq .Version | tr -d '"') + local url_lower=$(echo "$url" | awk '{ print tolower($0) }') + echo $url_lower + curl -s "$url_lower" + LATEST_VERSION=$(curl -s "$url_lower" | jq .Version | tr -d '"') else LATEST_VERSION="" echo "Invalid package location: $pkg"