* Re: [PR PATCH] [Updated] update-check: download each url once
[not found] <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-6395@inbox.vuxu.org>
@ 2019-05-09 8:09 ` voidlinux-github
2019-05-09 8:09 ` voidlinux-github
` (4 subsequent siblings)
5 siblings, 0 replies; 6+ messages in thread
From: voidlinux-github @ 2019-05-09 8:09 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 466 bytes --]
There is an updated pull request by Chocimier against master on the void-packages repository
https://github.com/Chocimier/void-packages-org update-check-fetch-once
https://github.com/void-linux/void-packages/pull/6395
update-check: download each url once
Speed up for packages with multiple downloads from same location or having homepage and distfiles at gitlab or github.
A patch file from https://github.com/void-linux/void-packages/pull/6395.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-update-check-fetch-once-6395.patch --]
[-- Type: application/text/x-diff, Size: 3179 bytes --]
From 484e149902b1a7a2c6994e344000f989f796fdc7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Daniel=20Ey=C3=9Fer?= <daniel.eysser@gmail.com>
Date: Tue, 7 May 2019 22:34:47 +0200
Subject: [PATCH 1/2] bash-completion: update to 2.9.
---
srcpkgs/bash-completion/template | 11 +++--------
1 file changed, 3 insertions(+), 8 deletions(-)
diff --git a/srcpkgs/bash-completion/template b/srcpkgs/bash-completion/template
index 170f231408f..01ecdd0a726 100644
--- a/srcpkgs/bash-completion/template
+++ b/srcpkgs/bash-completion/template
@@ -1,6 +1,6 @@
# Template file for 'bash-completion'
pkgname=bash-completion
-version=2.8
+version=2.9
revision=1
archs=noarch
build_style=gnu-configure
@@ -11,10 +11,5 @@ short_desc="Programmable completion for the GNU Bash shell"
maintainer="Juan RP <xtraeme@voidlinux.org>"
license="GPL-2.0-or-later"
homepage="https://github.com/scop/bash-completion"
-distfiles="${homepage}/releases/download/${version}/bash-completion-${version}.tar.xz"
-checksum=c01f5570f5698a0dda8dc9cfb2a83744daa1ec54758373a6e349bd903375f54d
-
-post_install() {
- # remove completions provided by util-linux.
- rm -f ${DESTDIR}/usr/share/bash-completion/completions/{{u,}mount*,rfkill}
-}
+distfiles="https://github.com/scop/bash-completion/releases/download/${version}/bash-completion-${version}.tar.xz"
+checksum=d48fe378e731062f479c5f8802ffa9d3c40a275a19e6e0f6f6cc4b90fa12b2f5
From 732b66d858e25ae8cf1c09c7d4b470110a98249d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= <chocimier@tlen.pl>
Date: Mon, 31 Dec 2018 12:34:10 +0100
Subject: [PATCH 2/2] update-check: download each url once
---
common/xbps-src/shutils/update_check.sh | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh
index ef88bd5f4a4..61caedd053a 100644
--- a/common/xbps-src/shutils/update_check.sh
+++ b/common/xbps-src/shutils/update_check.sh
@@ -4,7 +4,7 @@ update_check() {
local i p url sfname lpname bbname githubname rx found_version consider
local update_override=$XBPS_SRCPKGDIR/$XBPS_TARGET_PKG/update
local original_pkgname=$pkgname
- local urlpfx urlsfx
+ local urlpfx urlsfx fetchedurls
if [ -r $update_override ]; then
. $update_override
@@ -103,11 +103,19 @@ update_check() {
rx=${pattern:-$rx}
rx=${rx:-'(?<!-)\b\Q'"$pkgname"'\E[-_]?((src|source)[-_])?\K([^-/_\s]*?\d[^-/_\s]*?)(?=(?:[-_.](?:src|source|orig))?\.(?:[jt]ar|shar|t[bglx]z|tbz2|zip))\b'}
+ if printf '%s' "$fetchedurls" | grep -qFx "$url"; then
+ if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
+ echo "already fetched $url" 1>&2
+ fi
+ continue
+ fi
+
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
echo "fetching $url" 1>&2
fi
curl -H 'Accept: text/html,application/xhtml+xml,application/xml,text/plain,application/rss+xml' -A "xbps-src-update-check/$XBPS_SRC_VERSION" --max-time 10 -Lsk "$url" |
grep -Po -i "$rx"
+ fetchedurls="$(printf '%s\n%s' "$fetchedurls" "$url")"
done |
tr _ . |
sort -Vu |
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PR PATCH] [Updated] update-check: download each url once
[not found] <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-6395@inbox.vuxu.org>
2019-05-09 8:09 ` [PR PATCH] [Updated] update-check: download each url once voidlinux-github
@ 2019-05-09 8:09 ` voidlinux-github
2019-05-09 8:11 ` voidlinux-github
` (3 subsequent siblings)
5 siblings, 0 replies; 6+ messages in thread
From: voidlinux-github @ 2019-05-09 8:09 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 466 bytes --]
There is an updated pull request by Chocimier against master on the void-packages repository
https://github.com/Chocimier/void-packages-org update-check-fetch-once
https://github.com/void-linux/void-packages/pull/6395
update-check: download each url once
Speed up for packages with multiple downloads from same location or having homepage and distfiles at gitlab or github.
A patch file from https://github.com/void-linux/void-packages/pull/6395.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-update-check-fetch-once-6395.patch --]
[-- Type: application/text/x-diff, Size: 3179 bytes --]
From 484e149902b1a7a2c6994e344000f989f796fdc7 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Daniel=20Ey=C3=9Fer?= <daniel.eysser@gmail.com>
Date: Tue, 7 May 2019 22:34:47 +0200
Subject: [PATCH 1/2] bash-completion: update to 2.9.
---
srcpkgs/bash-completion/template | 11 +++--------
1 file changed, 3 insertions(+), 8 deletions(-)
diff --git a/srcpkgs/bash-completion/template b/srcpkgs/bash-completion/template
index 170f231408f..01ecdd0a726 100644
--- a/srcpkgs/bash-completion/template
+++ b/srcpkgs/bash-completion/template
@@ -1,6 +1,6 @@
# Template file for 'bash-completion'
pkgname=bash-completion
-version=2.8
+version=2.9
revision=1
archs=noarch
build_style=gnu-configure
@@ -11,10 +11,5 @@ short_desc="Programmable completion for the GNU Bash shell"
maintainer="Juan RP <xtraeme@voidlinux.org>"
license="GPL-2.0-or-later"
homepage="https://github.com/scop/bash-completion"
-distfiles="${homepage}/releases/download/${version}/bash-completion-${version}.tar.xz"
-checksum=c01f5570f5698a0dda8dc9cfb2a83744daa1ec54758373a6e349bd903375f54d
-
-post_install() {
- # remove completions provided by util-linux.
- rm -f ${DESTDIR}/usr/share/bash-completion/completions/{{u,}mount*,rfkill}
-}
+distfiles="https://github.com/scop/bash-completion/releases/download/${version}/bash-completion-${version}.tar.xz"
+checksum=d48fe378e731062f479c5f8802ffa9d3c40a275a19e6e0f6f6cc4b90fa12b2f5
From 732b66d858e25ae8cf1c09c7d4b470110a98249d Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= <chocimier@tlen.pl>
Date: Mon, 31 Dec 2018 12:34:10 +0100
Subject: [PATCH 2/2] update-check: download each url once
---
common/xbps-src/shutils/update_check.sh | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh
index ef88bd5f4a4..61caedd053a 100644
--- a/common/xbps-src/shutils/update_check.sh
+++ b/common/xbps-src/shutils/update_check.sh
@@ -4,7 +4,7 @@ update_check() {
local i p url sfname lpname bbname githubname rx found_version consider
local update_override=$XBPS_SRCPKGDIR/$XBPS_TARGET_PKG/update
local original_pkgname=$pkgname
- local urlpfx urlsfx
+ local urlpfx urlsfx fetchedurls
if [ -r $update_override ]; then
. $update_override
@@ -103,11 +103,19 @@ update_check() {
rx=${pattern:-$rx}
rx=${rx:-'(?<!-)\b\Q'"$pkgname"'\E[-_]?((src|source)[-_])?\K([^-/_\s]*?\d[^-/_\s]*?)(?=(?:[-_.](?:src|source|orig))?\.(?:[jt]ar|shar|t[bglx]z|tbz2|zip))\b'}
+ if printf '%s' "$fetchedurls" | grep -qFx "$url"; then
+ if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
+ echo "already fetched $url" 1>&2
+ fi
+ continue
+ fi
+
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
echo "fetching $url" 1>&2
fi
curl -H 'Accept: text/html,application/xhtml+xml,application/xml,text/plain,application/rss+xml' -A "xbps-src-update-check/$XBPS_SRC_VERSION" --max-time 10 -Lsk "$url" |
grep -Po -i "$rx"
+ fetchedurls="$(printf '%s\n%s' "$fetchedurls" "$url")"
done |
tr _ . |
sort -Vu |
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PR PATCH] [Updated] update-check: download each url once
[not found] <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-6395@inbox.vuxu.org>
2019-05-09 8:09 ` [PR PATCH] [Updated] update-check: download each url once voidlinux-github
2019-05-09 8:09 ` voidlinux-github
@ 2019-05-09 8:11 ` voidlinux-github
2019-05-09 8:11 ` voidlinux-github
` (2 subsequent siblings)
5 siblings, 0 replies; 6+ messages in thread
From: voidlinux-github @ 2019-05-09 8:11 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 466 bytes --]
There is an updated pull request by Chocimier against master on the void-packages repository
https://github.com/Chocimier/void-packages-org update-check-fetch-once
https://github.com/void-linux/void-packages/pull/6395
update-check: download each url once
Speed up for packages with multiple downloads from same location or having homepage and distfiles at gitlab or github.
A patch file from https://github.com/void-linux/void-packages/pull/6395.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-update-check-fetch-once-6395.patch --]
[-- Type: application/text/x-diff, Size: 1781 bytes --]
From ea8112b11c686b5d1b7beb46c86298ad323e0af3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= <chocimier@tlen.pl>
Date: Mon, 31 Dec 2018 12:34:10 +0100
Subject: [PATCH] update-check: download each url once
---
common/xbps-src/shutils/update_check.sh | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh
index ef88bd5f4a4..61caedd053a 100644
--- a/common/xbps-src/shutils/update_check.sh
+++ b/common/xbps-src/shutils/update_check.sh
@@ -4,7 +4,7 @@ update_check() {
local i p url sfname lpname bbname githubname rx found_version consider
local update_override=$XBPS_SRCPKGDIR/$XBPS_TARGET_PKG/update
local original_pkgname=$pkgname
- local urlpfx urlsfx
+ local urlpfx urlsfx fetchedurls
if [ -r $update_override ]; then
. $update_override
@@ -103,11 +103,19 @@ update_check() {
rx=${pattern:-$rx}
rx=${rx:-'(?<!-)\b\Q'"$pkgname"'\E[-_]?((src|source)[-_])?\K([^-/_\s]*?\d[^-/_\s]*?)(?=(?:[-_.](?:src|source|orig))?\.(?:[jt]ar|shar|t[bglx]z|tbz2|zip))\b'}
+ if printf '%s' "$fetchedurls" | grep -qFx "$url"; then
+ if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
+ echo "already fetched $url" 1>&2
+ fi
+ continue
+ fi
+
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
echo "fetching $url" 1>&2
fi
curl -H 'Accept: text/html,application/xhtml+xml,application/xml,text/plain,application/rss+xml' -A "xbps-src-update-check/$XBPS_SRC_VERSION" --max-time 10 -Lsk "$url" |
grep -Po -i "$rx"
+ fetchedurls="$(printf '%s\n%s' "$fetchedurls" "$url")"
done |
tr _ . |
sort -Vu |
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PR PATCH] [Updated] update-check: download each url once
[not found] <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-6395@inbox.vuxu.org>
` (2 preceding siblings ...)
2019-05-09 8:11 ` voidlinux-github
@ 2019-05-09 8:11 ` voidlinux-github
2019-06-11 20:11 ` voidlinux-github
2019-06-11 20:11 ` voidlinux-github
5 siblings, 0 replies; 6+ messages in thread
From: voidlinux-github @ 2019-05-09 8:11 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 466 bytes --]
There is an updated pull request by Chocimier against master on the void-packages repository
https://github.com/Chocimier/void-packages-org update-check-fetch-once
https://github.com/void-linux/void-packages/pull/6395
update-check: download each url once
Speed up for packages with multiple downloads from same location or having homepage and distfiles at gitlab or github.
A patch file from https://github.com/void-linux/void-packages/pull/6395.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-update-check-fetch-once-6395.patch --]
[-- Type: application/text/x-diff, Size: 1781 bytes --]
From ea8112b11c686b5d1b7beb46c86298ad323e0af3 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= <chocimier@tlen.pl>
Date: Mon, 31 Dec 2018 12:34:10 +0100
Subject: [PATCH] update-check: download each url once
---
common/xbps-src/shutils/update_check.sh | 10 +++++++++-
1 file changed, 9 insertions(+), 1 deletion(-)
diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh
index ef88bd5f4a4..61caedd053a 100644
--- a/common/xbps-src/shutils/update_check.sh
+++ b/common/xbps-src/shutils/update_check.sh
@@ -4,7 +4,7 @@ update_check() {
local i p url sfname lpname bbname githubname rx found_version consider
local update_override=$XBPS_SRCPKGDIR/$XBPS_TARGET_PKG/update
local original_pkgname=$pkgname
- local urlpfx urlsfx
+ local urlpfx urlsfx fetchedurls
if [ -r $update_override ]; then
. $update_override
@@ -103,11 +103,19 @@ update_check() {
rx=${pattern:-$rx}
rx=${rx:-'(?<!-)\b\Q'"$pkgname"'\E[-_]?((src|source)[-_])?\K([^-/_\s]*?\d[^-/_\s]*?)(?=(?:[-_.](?:src|source|orig))?\.(?:[jt]ar|shar|t[bglx]z|tbz2|zip))\b'}
+ if printf '%s' "$fetchedurls" | grep -qFx "$url"; then
+ if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
+ echo "already fetched $url" 1>&2
+ fi
+ continue
+ fi
+
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
echo "fetching $url" 1>&2
fi
curl -H 'Accept: text/html,application/xhtml+xml,application/xml,text/plain,application/rss+xml' -A "xbps-src-update-check/$XBPS_SRC_VERSION" --max-time 10 -Lsk "$url" |
grep -Po -i "$rx"
+ fetchedurls="$(printf '%s\n%s' "$fetchedurls" "$url")"
done |
tr _ . |
sort -Vu |
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PR PATCH] [Updated] update-check: download each url once
[not found] <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-6395@inbox.vuxu.org>
` (3 preceding siblings ...)
2019-05-09 8:11 ` voidlinux-github
@ 2019-06-11 20:11 ` voidlinux-github
2019-06-11 20:11 ` voidlinux-github
5 siblings, 0 replies; 6+ messages in thread
From: voidlinux-github @ 2019-06-11 20:11 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 466 bytes --]
There is an updated pull request by Chocimier against master on the void-packages repository
https://github.com/Chocimier/void-packages-org update-check-fetch-once
https://github.com/void-linux/void-packages/pull/6395
update-check: download each url once
Speed up for packages with multiple downloads from same location or having homepage and distfiles at gitlab or github.
A patch file from https://github.com/void-linux/void-packages/pull/6395.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-update-check-fetch-once-6395.patch --]
[-- Type: application/text/x-diff, Size: 1624 bytes --]
From f6dc1f0a5bcbaa426419263819592db2d03386bd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= <chocimier@tlen.pl>
Date: Mon, 31 Dec 2018 12:34:10 +0100
Subject: [PATCH] update-check: download each url once
---
common/xbps-src/shutils/update_check.sh | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh
index e2cdee3d0fc..445600a2fe9 100644
--- a/common/xbps-src/shutils/update_check.sh
+++ b/common/xbps-src/shutils/update_check.sh
@@ -5,6 +5,7 @@ update_check() {
local update_override=$XBPS_SRCPKGDIR/$XBPS_TARGET_PKG/update
local original_pkgname=$pkgname
local urlpfx urlsfx
+ local -A fetchedurls
if [ -r $update_override ]; then
. $update_override
@@ -138,11 +139,19 @@ update_check() {
rx=${pattern:-$rx}
rx=${rx:-'(?<!-)\b\Q'"$pkgname"'\E[-_]?((src|source)[-_])?\K([^-/_\s]*?\d[^-/_\s]*?)(?=(?:[-_.](?:src|source|orig))?\.(?:[jt]ar|shar|t[bglx]z|tbz2|zip))\b'}
+ if [ "${fetchedurls[$url]}" ]; then
+ if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
+ echo "already fetched $url" 1>&2
+ fi
+ continue
+ fi
+
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
echo "fetching $url" 1>&2
fi
curl -H 'Accept: text/html,application/xhtml+xml,application/xml,text/plain,application/rss+xml' -A "xbps-src-update-check/$XBPS_SRC_VERSION" --max-time 10 -Lsk "$url" |
grep -Po -i "$rx"
+ fetchedurls[$url]=yes
done |
tr _ . |
sort -Vu |
^ permalink raw reply [flat|nested] 6+ messages in thread
* Re: [PR PATCH] [Updated] update-check: download each url once
[not found] <gh-mailinglist-notifications-41a7ca26-5023-4802-975b-f1789d68868e-void-packages-6395@inbox.vuxu.org>
` (4 preceding siblings ...)
2019-06-11 20:11 ` voidlinux-github
@ 2019-06-11 20:11 ` voidlinux-github
5 siblings, 0 replies; 6+ messages in thread
From: voidlinux-github @ 2019-06-11 20:11 UTC (permalink / raw)
To: ml
[-- Attachment #1: Type: text/plain, Size: 466 bytes --]
There is an updated pull request by Chocimier against master on the void-packages repository
https://github.com/Chocimier/void-packages-org update-check-fetch-once
https://github.com/void-linux/void-packages/pull/6395
update-check: download each url once
Speed up for packages with multiple downloads from same location or having homepage and distfiles at gitlab or github.
A patch file from https://github.com/void-linux/void-packages/pull/6395.patch is attached
[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-update-check-fetch-once-6395.patch --]
[-- Type: application/text/x-diff, Size: 1624 bytes --]
From f6dc1f0a5bcbaa426419263819592db2d03386bd Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= <chocimier@tlen.pl>
Date: Mon, 31 Dec 2018 12:34:10 +0100
Subject: [PATCH] update-check: download each url once
---
common/xbps-src/shutils/update_check.sh | 9 +++++++++
1 file changed, 9 insertions(+)
diff --git a/common/xbps-src/shutils/update_check.sh b/common/xbps-src/shutils/update_check.sh
index e2cdee3d0fc..445600a2fe9 100644
--- a/common/xbps-src/shutils/update_check.sh
+++ b/common/xbps-src/shutils/update_check.sh
@@ -5,6 +5,7 @@ update_check() {
local update_override=$XBPS_SRCPKGDIR/$XBPS_TARGET_PKG/update
local original_pkgname=$pkgname
local urlpfx urlsfx
+ local -A fetchedurls
if [ -r $update_override ]; then
. $update_override
@@ -138,11 +139,19 @@ update_check() {
rx=${pattern:-$rx}
rx=${rx:-'(?<!-)\b\Q'"$pkgname"'\E[-_]?((src|source)[-_])?\K([^-/_\s]*?\d[^-/_\s]*?)(?=(?:[-_.](?:src|source|orig))?\.(?:[jt]ar|shar|t[bglx]z|tbz2|zip))\b'}
+ if [ "${fetchedurls[$url]}" ]; then
+ if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
+ echo "already fetched $url" 1>&2
+ fi
+ continue
+ fi
+
if [ -n "$XBPS_UPDATE_CHECK_VERBOSE" ]; then
echo "fetching $url" 1>&2
fi
curl -H 'Accept: text/html,application/xhtml+xml,application/xml,text/plain,application/rss+xml' -A "xbps-src-update-check/$XBPS_SRC_VERSION" --max-time 10 -Lsk "$url" |
grep -Po -i "$rx"
+ fetchedurls[$url]=yes
done |
tr _ . |
sort -Vu |
^ permalink raw reply [flat|nested] 6+ messages in thread