Skip to content

Commit

Permalink
Updated the currency automation script to accommodate capital letters…
Browse files Browse the repository at this point in the history
… in the package URL.
  • Loading branch information
nithinputhenveettil authored Apr 24, 2024
1 parent ed4653b commit 75eb42b
Showing 1 changed file with 4 additions and 3 deletions.
7 changes: 4 additions & 3 deletions version_updater.sh
Original file line number Diff line number Diff line change
Expand Up @@ -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"
Expand Down

0 comments on commit 75eb42b

Please sign in to comment.