Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] xbps-src: improve update-check pattern for GitHub
@ 2024-11-03  7:11 icp1994
  2025-02-02  1:59 ` github-actions
  2025-02-03 18:39 ` [PR PATCH] [Updated] " icp1994
  0 siblings, 2 replies; 3+ messages in thread
From: icp1994 @ 2024-11-03  7:11 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 720 bytes --]

There is a new pull request by icp1994 against master on the void-packages repository

https://github.com/icp1994/void-packages gh-update-check
https://github.com/void-linux/void-packages/pull/52894

xbps-src: improve update-check pattern for GitHub
#### Testing the changes
- I tested the changes in this PR: **YES**

This one catches tags of the form `<pkgname>-v<major>.<minor>.<patch>` which would get through the previous one. And possibly some other cursed patterns. But maybe there's some unintended side effects. I did check it against quite a few packages but GH sources are far too many to do an exhaustive testing.

A patch file from https://github.com/void-linux/void-packages/pull/52894.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gh-update-check-52894.patch --]
[-- Type: text/x-diff, Size: 1083 bytes --]

From 89696e3ea4667e9c32c9b60ca8f40b8575e21704 Mon Sep 17 00:00:00 2001
From: icp <pangolin@vivaldi.net>
Date: Sun, 3 Nov 2024 12:32:47 +0530
Subject: [PATCH] xbps-src: improve update-check pattern for GitHub

---
 common/xbps-src/shutils/update_check.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh
index e626b307b7c65f..7d971ba8744c0e 100644
--- a/common/xbps-src/shutils/update_check.sh
+++ b/common/xbps-src/shutils/update_check.sh
@@ -139,7 +139,7 @@ update_check() {
             *github.com*)
                 pkgurlname="$(printf %s "$url" | cut -d/ -f4,5)"
                 url="https://github.com/$pkgurlname/tags"
-                rx='/archive/refs/tags/(v?|\Q'"$pkgname"'\E[-_])?\K[\d.]+(?=\.tar\.gz")';;
+                rx='/archive/refs/tags/(\Q'"$pkgname"'\E|[-_v])*\K[\d.]+(?=\.tar\.gz")';;
             *//gitlab.*|*code.videolan.org*)
                 case "$url" in
                     */-/*) pkgurlname="$(printf %s "$url" | sed -e 's%/-/.*%%g; s%/$%%')";;

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: xbps-src: improve update-check pattern for GitHub
  2024-11-03  7:11 [PR PATCH] xbps-src: improve update-check pattern for GitHub icp1994
@ 2025-02-02  1:59 ` github-actions
  2025-02-03 18:39 ` [PR PATCH] [Updated] " icp1994
  1 sibling, 0 replies; 3+ messages in thread
From: github-actions @ 2025-02-02  1:59 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 305 bytes --]

New comment by github-actions[bot] on void-packages repository

https://github.com/void-linux/void-packages/pull/52894#issuecomment-2629200698

Comment:
Pull Requests become stale 90 days after last activity and are closed 14 days after that.  If this pull request is still relevant bump it or assign it.

^ permalink raw reply	[flat|nested] 3+ messages in thread

* Re: [PR PATCH] [Updated] xbps-src: improve update-check pattern for GitHub
  2024-11-03  7:11 [PR PATCH] xbps-src: improve update-check pattern for GitHub icp1994
  2025-02-02  1:59 ` github-actions
@ 2025-02-03 18:39 ` icp1994
  1 sibling, 0 replies; 3+ messages in thread
From: icp1994 @ 2025-02-03 18:39 UTC (permalink / raw)
  To: ml

[-- Attachment #1: Type: text/plain, Size: 725 bytes --]

There is an updated pull request by icp1994 against master on the void-packages repository

https://github.com/icp1994/void-packages gh-update-check
https://github.com/void-linux/void-packages/pull/52894

xbps-src: improve update-check pattern for GitHub
#### Testing the changes
- I tested the changes in this PR: **YES**

This one catches tags of the form `<pkgname>-v<major>.<minor>.<patch>` which would get through the previous one. And possibly some other cursed patterns. But maybe there's some unintended side effects. I did check it against quite a few packages but GH sources are far too many to do an exhaustive testing.

A patch file from https://github.com/void-linux/void-packages/pull/52894.patch is attached

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-gh-update-check-52894.patch --]
[-- Type: text/x-diff, Size: 1083 bytes --]

From e0e3a578f40057f2bba3449308bba58cdd33aee3 Mon Sep 17 00:00:00 2001
From: icp <pangolin@vivaldi.net>
Date: Sun, 3 Nov 2024 12:32:47 +0530
Subject: [PATCH] xbps-src: improve update-check pattern for GitHub

---
 common/xbps-src/shutils/update_check.sh | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh
index e626b307b7c65f..7d971ba8744c0e 100644
--- a/common/xbps-src/shutils/update_check.sh
+++ b/common/xbps-src/shutils/update_check.sh
@@ -139,7 +139,7 @@ update_check() {
             *github.com*)
                 pkgurlname="$(printf %s "$url" | cut -d/ -f4,5)"
                 url="https://github.com/$pkgurlname/tags"
-                rx='/archive/refs/tags/(v?|\Q'"$pkgname"'\E[-_])?\K[\d.]+(?=\.tar\.gz")';;
+                rx='/archive/refs/tags/(\Q'"$pkgname"'\E|[-_v])*\K[\d.]+(?=\.tar\.gz")';;
             *//gitlab.*|*code.videolan.org*)
                 case "$url" in
                     */-/*) pkgurlname="$(printf %s "$url" | sed -e 's%/-/.*%%g; s%/$%%')";;

^ permalink raw reply	[flat|nested] 3+ messages in thread

end of thread, other threads:[~2025-02-03 18:39 UTC | newest]

Thread overview: 3+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2024-11-03  7:11 [PR PATCH] xbps-src: improve update-check pattern for GitHub icp1994
2025-02-02  1:59 ` github-actions
2025-02-03 18:39 ` [PR PATCH] [Updated] " icp1994

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for NNTP newsgroup(s).