From 99ac6a60615244dce9d9be766b03ddda1a93de61 Mon Sep 17 00:00:00 2001 From: darkclip Date: Sat, 27 Jan 2024 05:45:46 +0800 Subject: [PATCH] update --- update-github-release.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/update-github-release.sh b/update-github-release.sh index 6f3fbad..e4844e6 100755 --- a/update-github-release.sh +++ b/update-github-release.sh @@ -24,10 +24,10 @@ main(){ fi echo "Update for $REPO" api_url="https://api.github.com/repos/$REPO/releases/latest" - dl_url=$(curl -sSf $api_url | grep $build_arch | grep browser_download_url | cut -d '"' -f 4) + dl_url=$(curl -sSf $api_url | grep -i $build_arch | grep browser_download_url | cut -d '"' -f 4) curr_ver=$($PROG_PATH/$PROG_NAME -v) - if (echo $dl_url | grep $curr_ver) >/dev/null 2>&1; then + if (echo $dl_url | grep -i $curr_ver) >/dev/null 2>&1; then echo "Already latest version!" else tmp_dir="/tmp/$(cat /dev/urandom | tr -dc 'a-zA-Z0-9' | fold -w 32 | head -n 1)"