From 5f0e7218ebf500e19ff1b94fd8ce22fb6d05b51a Mon Sep 17 00:00:00 2001 From: icp Date: Sun, 6 Nov 2022 15:12:41 +0530 Subject: [PATCH] common/xbps-src/shutils/update_check.sh: tweak url and rx for git.sr.ht Accommodate for tarballs in refs named after commit hash. --- common/xbps-src/shutils/update_check.sh | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh index 85e419cb81a..c5a9f745ba4 100644 --- a/common/xbps-src/shutils/update_check.sh +++ b/common/xbps-src/shutils/update_check.sh @@ -167,8 +167,8 @@ update_check() { rx='/archive/(v?|\Q'"$pkgname"'\E-)?\K[\d.]+(?=\.tar\.gz")';; *git.sr.ht*) pkgurlname="$(printf %s "$url" | cut -d/ -f4,5)" - url="https://git.sr.ht/$pkgurlname/refs" - rx='/archive/(v?|\Q'"$pkgname"'\E-)?\K[\d.]+(?=\.tar\.gz")';; + url="https://git.sr.ht/$pkgurlname/refs/rss.xml" + rx='\Q'"${url%/*}"'\E/(v-?|\Q'"$pkgname"'\E-)?\K[\d.]+(?=)' ;; *pkgs.fedoraproject.org*) url="https://pkgs.fedoraproject.org/repo/pkgs/$pkgname" ;; esac