Github messages for voidlinux
 help / color / mirror / Atom feed
* [PR PATCH] xbps-src: fix warning on file:/// mirror
@ 2021-08-13 17:03 Chocimier
  2021-08-15 20:41 ` [PR REVIEW] " ericonr
                   ` (2 more replies)
  0 siblings, 3 replies; 4+ messages in thread
From: Chocimier @ 2021-08-13 17:03 UTC (permalink / raw)
  To: ml

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

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

https://github.com/Chocimier/void-packages-org XBPS_DISTFILES_MIRROR
https://github.com/void-linux/void-packages/pull/32482

xbps-src: fix warning on file:/// mirror
None

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

[-- Warning: decoded text below may be mangled, UTF-8 assumed --]
[-- Attachment #2: github-pr-XBPS_DISTFILES_MIRROR-32482.patch --]
[-- Type: text/x-diff, Size: 1903 bytes --]

From 885cf05a62da19de279ea3af277980c31fda7851 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= <chocimier@tlen.pl>
Date: Fri, 13 Aug 2021 17:56:19 +0200
Subject: [PATCH 1/2] xbps-src: source msg_warn before its first use

---
 xbps-src | 13 +++++++------
 1 file changed, 7 insertions(+), 6 deletions(-)

diff --git a/xbps-src b/xbps-src
index 086a0fe212fc..5e75926c5ad5 100755
--- a/xbps-src
+++ b/xbps-src
@@ -689,12 +689,6 @@ fi
 
 check_build_requirements
 
-if [ -z "$IN_CHROOT" ]; then
-    trap 'exit_func' INT TERM
-    if [ -n "$XBPS_DISTFILES_MIRROR" ]; then
-        setup_distfiles_mirror
-    fi
-fi
 #
 # Read funcs from helpers
 #
@@ -702,6 +696,13 @@ for f in ${XBPS_SHUTILSDIR}/*.sh; do
     [ -r "$f" ] && . $f
 done
 
+if [ -z "$IN_CHROOT" ]; then
+    trap 'exit_func' INT TERM
+    if [ -n "$XBPS_DISTFILES_MIRROR" ]; then
+        setup_distfiles_mirror
+    fi
+fi
+
 reconfigure_base_chroot
 
 #

From 99cac7216396eb0e326a21e2b984752aa13a6dc5 Mon Sep 17 00:00:00 2001
From: =?UTF-8?q?Piotr=20W=C3=B3jcik?= <chocimier@tlen.pl>
Date: Fri, 13 Aug 2021 18:58:39 +0200
Subject: [PATCH 2/2] xbps-src: limit warning on file:/// mirror to related
 targets

---
 xbps-src | 5 ++++-
 1 file changed, 4 insertions(+), 1 deletion(-)

diff --git a/xbps-src b/xbps-src
index 5e75926c5ad5..7fe0ac55ffd8 100755
--- a/xbps-src
+++ b/xbps-src
@@ -337,7 +337,10 @@ setup_distfiles_mirror() {
             mkdir -p "$XBPS_MASTERDIR/$path"
             XBPS_CHROOT_CMD_ARGS+=" -b $path:$path"
         else
-            msg_warn "xbps-src: File URLs ($mirror) don't work with '$XBPS_CHROOT_CMD'\n"
+            case "$XBPS_TARGET" in
+                fetch|extract|patch|configure|build|check|install|pkg|bootstrap|bootstrap-update|update-sys)
+                    msg_warn "xbps-src: File URLs ($mirror) don't work with '$XBPS_CHROOT_CMD'\n"
+            esac
         fi
     done
 }

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

* Re: [PR REVIEW] xbps-src: fix warning on file:/// mirror
  2021-08-13 17:03 [PR PATCH] xbps-src: fix warning on file:/// mirror Chocimier
@ 2021-08-15 20:41 ` ericonr
  2021-08-17 18:09 ` Chocimier
  2021-08-17 18:09 ` [PR PATCH] [Merged]: " Chocimier
  2 siblings, 0 replies; 4+ messages in thread
From: ericonr @ 2021-08-15 20:41 UTC (permalink / raw)
  To: ml

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

New review comment by ericonr on void-packages repository

https://github.com/void-linux/void-packages/pull/32482#discussion_r689140822

Comment:
At least from how the diff is displayed, I'd say the correct commit message would be `move msg_warn usage to after it's sourced` :p

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

* Re: [PR REVIEW] xbps-src: fix warning on file:/// mirror
  2021-08-13 17:03 [PR PATCH] xbps-src: fix warning on file:/// mirror Chocimier
  2021-08-15 20:41 ` [PR REVIEW] " ericonr
@ 2021-08-17 18:09 ` Chocimier
  2021-08-17 18:09 ` [PR PATCH] [Merged]: " Chocimier
  2 siblings, 0 replies; 4+ messages in thread
From: Chocimier @ 2021-08-17 18:09 UTC (permalink / raw)
  To: ml

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

New review comment by Chocimier on void-packages repository

https://github.com/void-linux/void-packages/pull/32482#discussion_r690607448

Comment:
commit message is for why, not what :p

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

* Re: [PR PATCH] [Merged]: xbps-src: fix warning on file:/// mirror
  2021-08-13 17:03 [PR PATCH] xbps-src: fix warning on file:/// mirror Chocimier
  2021-08-15 20:41 ` [PR REVIEW] " ericonr
  2021-08-17 18:09 ` Chocimier
@ 2021-08-17 18:09 ` Chocimier
  2 siblings, 0 replies; 4+ messages in thread
From: Chocimier @ 2021-08-17 18:09 UTC (permalink / raw)
  To: ml

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

There's a merged pull request on the void-packages repository

xbps-src: fix warning on file:/// mirror
https://github.com/void-linux/void-packages/pull/32482

Description:
None

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

end of thread, other threads:[~2021-08-17 18:09 UTC | newest]

Thread overview: 4+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2021-08-13 17:03 [PR PATCH] xbps-src: fix warning on file:/// mirror Chocimier
2021-08-15 20:41 ` [PR REVIEW] " ericonr
2021-08-17 18:09 ` Chocimier
2021-08-17 18:09 ` [PR PATCH] [Merged]: " Chocimier

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).