From debbugs-submit-bounces@debbugs.gnu.org Thu Oct 27 17:27:35 2022 Received: (at submit) by debbugs.gnu.org; 27 Oct 2022 21:27:35 +0000 Received: from localhost ([127.0.0.1]:59492 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ooAPX-0003Rv-Ap for submit@debbugs.gnu.org; Thu, 27 Oct 2022 17:27:35 -0400 Received: from lists.gnu.org ([209.51.188.17]:54610) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ooAPV-0003Ro-Ol for submit@debbugs.gnu.org; Thu, 27 Oct 2022 17:27:34 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ooAPU-0005gT-HN for guix-patches@gnu.org; Thu, 27 Oct 2022 17:27:33 -0400 Received: from knopi.disroot.org ([178.21.23.139]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1ooAPH-0005HK-EN for guix-patches@gnu.org; Thu, 27 Oct 2022 17:27:32 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 34BDD4E841; Thu, 27 Oct 2022 23:27:16 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id lVGLinmwcwSi; Thu, 27 Oct 2022 23:27:15 +0200 (CEST) From: "(" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1666906035; bh=NtQTLP2AnTFk20q2cBsqE03zjCAxqGAEBuMETKFtutw=; h=From:To:Cc:Subject:Date; b=f/yk4mBYTj8NiIaeIOMtLVbxcRI3vj8vepOLQgfySeeijP5HhdrG0+zuUs1LiQlRU tiLcBfH9OSSJD1Mq2g291lsBF9ahWiTaP3s8PNBGbsCVFBvIKhiDx5fnVxBKDVskcP xrvH9f6DkHlSkD2D48MhYQ+boOljnbzew/zLe5hCn3Gg2kJtSynmXH4fh3iUII8VZr ikNJlRKZ+YBfus5Ay36uJn6QSnn+19o7Wqp3jVhizYG/1bdahO3O7Kwk2KHKWieY+R wSJIsEhGQJ4qCYj7Tz0YLo2zabzudUod5hSSKXE+ntW3JLOX4U/VcUJpzakteZUbKy vGqzXy3z+pf7w== To: guix-patches@gnu.org Subject: [PATCH 0/1] scripts: refresh: Support --list-dependent=packages. Date: Thu, 27 Oct 2022 22:27:06 +0100 Message-Id: <20221027212706.21680-1-paren@disroot.org> Mime-Version: 1.0 Content-Transfer-Encoding: 8bit Received-SPF: pass client-ip=178.21.23.139; envelope-from=paren@disroot.org; helo=knopi.disroot.org X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -0.0 (/) X-Debbugs-Envelope-To: submit Cc: Vagrant Cascadian , "\(" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Heya Guix, This patch adds support for passing the string "packages" to ``guix refresh'''s ``--list-dependent'' argument, which displays only the packages, with no "XXX packages will be rebuilt:" header. This allows us to perform substitutions like this: guix build $(guix refresh --list-dependent=packages gtk) to, for example, build all the dependents of ``gtk''. ( (1): scripts: refresh: Support --list-dependent=packages. guix/scripts/refresh.scm | 61 ++++++++++++++++++++++++---------------- 1 file changed, 37 insertions(+), 24 deletions(-) base-commit: f928abac369f699f425ddee925d0d0c2dc0a635d -- 2.38.0 From debbugs-submit-bounces@debbugs.gnu.org Thu Oct 27 17:29:14 2022 Received: (at 58824) by debbugs.gnu.org; 27 Oct 2022 21:29:14 +0000 Received: from localhost ([127.0.0.1]:59497 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ooAR7-0003Uy-Pa for submit@debbugs.gnu.org; Thu, 27 Oct 2022 17:29:14 -0400 Received: from knopi.disroot.org ([178.21.23.139]:60662) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ooAR6-0003Ur-2D for 58824@debbugs.gnu.org; Thu, 27 Oct 2022 17:29:12 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 6D13D4E7B1; Thu, 27 Oct 2022 23:29:11 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with UTF8SMTP id qON8V6_lMvPF; Thu, 27 Oct 2022 23:29:10 +0200 (CEST) From: "(" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1666906145; bh=RX4bJxeslxrvpwh4rVf9sS/QmUq5D2w8gzHxa/921nA=; h=From:To:Cc:Subject:Date; b=dKEtZfo4caUWcnud+ldh1xvZNQPkORCbGaJGgZ/qpXlbi7mwN7UJVo6jH7+RcHZYD HM21psLJG1ovVxxiOwJgQIcWBIbB6k+xSR16rRVaC8ROR02YLhuSgG8JO3iqeokEU0 V8q+He+SApV6GxH2d/nJJkyoLBGOzPmKYALSwtPiFOxzmqWRRXuIum50uUCKokZlRP m+JRBIs8QNGEqNRgRaUutjUq0RxBRmG3gnpXHyfnHRv3ukYOic2+6G+QqkPsWn4Lm9 Tm+aIbtaMWYn4vZ0H4ZWRkwfOoTHGMGQuXZJdUsR6Zt/oqafhhy+mroYm1WPcR7S/f I8P2f4J5YudMg== To: 58824@debbugs.gnu.org Subject: [PATCH 1/1] scripts: refresh: Support --list-dependent=packages. Date: Thu, 27 Oct 2022 22:28:59 +0100 Message-Id: <20221027212859.21755-1-paren@disroot.org> Mime-Version: 1.0 Content-Transfer-Encoding: 8bit X-Spam-Score: 1.3 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: * guix/scripts/refresh.scm (%options)[list-dependent]: Allow an optional argument. Set 'LIST-DEPENDENT-MACHINE-READABLE? to #T in RESULT if the argument is "packages". (list-dependents): Support #:MAC [...] Content analysis details: (1.3 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 1.3 FROM_ONE_CHAR Bogus FROM name -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record X-Debbugs-Envelope-To: 58824 Cc: "\(" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.3 (/) * guix/scripts/refresh.scm (%options)[list-dependent]: Allow an optional argument. Set 'LIST-DEPENDENT-MACHINE-READABLE? to #T in RESULT if the argument is "packages". (list-dependents): Support #:MACHINE-READABLE?. (guix-refresh): Pass #:MACHINE-READABLE? #T to LIST-DEPENDENTS if 'LIST-DEPENDENT-MACHINE-READABLE? is #T. --- guix/scripts/refresh.scm | 61 ++++++++++++++++++++++++---------------- 1 file changed, 37 insertions(+), 24 deletions(-) diff --git a/guix/scripts/refresh.scm b/guix/scripts/refresh.scm index 14329751f8..9040f4d83d 100644 --- a/guix/scripts/refresh.scm +++ b/guix/scripts/refresh.scm @@ -93,9 +93,12 @@ (define %options (option '(#\e "expression") #t #f (lambda (opt name arg result) (alist-cons 'expression arg result))) - (option '(#\l "list-dependent") #f #f + (option '(#\l "list-dependent") #f #t (lambda (opt name arg result) - (alist-cons 'list-dependent? #t result))) + (append `((list-dependent? . #t) + (list-dependent-machine-readable? + . ,(and arg (string=? arg "packages")))) + result))) (option '(#\r "recursive") #f #f (lambda (opt name arg result) (alist-cons 'recursive? #t result))) @@ -417,8 +420,10 @@ (define (all-packages) '() #:select? (const #t))) ;include hidden packages -(define (list-dependents packages) - "List all the things that would need to be rebuilt if PACKAGES are changed." +(define* (list-dependents packages #:key (machine-readable? #f)) + "List all the things that would need to be rebuilt if PACKAGES are +changed. If MACHINE-READABLE? is #T, display only a list of packages, +with no human-friendly extra text." ;; Using %BAG-NODE-TYPE is more accurate than using %PACKAGE-NODE-TYPE ;; because it includes implicit dependencies. (define (full-name package) @@ -431,27 +436,31 @@ (define (full-name package) (covering (filter (lambda (node) (null? (edges node))) dependents))) - (match dependents - (() - (format (current-output-port) - (N_ "No dependents other than itself: ~{~a~}~%" - "No dependents other than themselves: ~{~a~^ ~}~%" - (length packages)) - (map full-name packages))) - - ((x) - (format (current-output-port) - (G_ "A single dependent package: ~a~%") - (full-name x))) - (lst - (format (current-output-port) - (N_ "Building the following ~d package would ensure ~d \ + (if machine-readable? + (format (current-output-port) + (G_ "~{~a~^ ~}~%") + (map full-name covering)) + (match dependents + (() + (format (current-output-port) + (N_ "No dependents other than itself: ~{~a~}~%" + "No dependents other than themselves: ~{~a~^ ~}~%" + (length packages)) + (map full-name packages))) + ((x) + (format (current-output-port) + (G_ "A single dependent package: ~a~%") + (full-name x))) + (lst + (format (current-output-port) + (N_ "Building the following ~d package would ensure ~d \ dependent packages are rebuilt: ~{~a~^ ~}~%" - "Building the following ~d packages would ensure ~d \ + "Building the following ~d packages would ensure ~d \ dependent packages are rebuilt: ~{~a~^ ~}~%" - (length covering)) - (length covering) (length dependents) - (map full-name covering)))) + (length covering)) + (length covering) (length dependents) + (map full-name covering))))) + (return #t)))) (define (list-transitive packages) @@ -528,6 +537,8 @@ (define (options->updaters opts) (updaters (options->updaters opts)) (recursive? (assoc-ref opts 'recursive?)) (list-dependent? (assoc-ref opts 'list-dependent?)) + (list-dependent-machine-readable? + (assoc-ref opts 'list-dependent-machine-readable?)) (list-transitive? (assoc-ref opts 'list-transitive?)) (key-download (assoc-ref opts 'key-download)) @@ -543,7 +554,9 @@ (define (options->updaters opts) (mlet %store-monad ((packages (options->packages opts))) (cond (list-dependent? - (list-dependents packages)) + (list-dependents packages + #:machine-readable? + list-dependent-machine-readable?)) (list-transitive? (list-transitive packages)) (update? -- 2.38.0 From debbugs-submit-bounces@debbugs.gnu.org Fri Oct 28 11:39:18 2022 Received: (at 58824) by debbugs.gnu.org; 28 Oct 2022 15:39:18 +0000 Received: from localhost ([127.0.0.1]:34091 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ooRS2-0004nb-95 for submit@debbugs.gnu.org; Fri, 28 Oct 2022 11:39:18 -0400 Received: from knopi.disroot.org ([178.21.23.139]:58764) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ooRRw-0004nO-EJ for 58824@debbugs.gnu.org; Fri, 28 Oct 2022 11:39:16 -0400 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id 241EB4E8C6; Fri, 28 Oct 2022 17:39:11 +0200 (CEST) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with UTF8SMTP id 8NYV6MnO6e0M; Fri, 28 Oct 2022 17:39:09 +0200 (CEST) From: "(" DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1666971060; bh=d/tiJysaQdblEUHSRSLo/r74txMVz6eJ2G0T4LzqtvQ=; h=From:To:Cc:Subject:Date; b=bk1Ap8dqllH+3r2vHgjpTavBKM86PkdmsIBSHSYLGxaw32NkLiOLP9kJunneqBjWZ HJB0FXeXZ/VjmZeQs1PnEF5oEyJBvACSIXMqx04MbZ/JtKSA2Z7dA5iZNxj9feeFo4 9hYRmrCyB5wDd+csFK2lSEYiao9/2yC+yGUsrvj4z4UGQrcwpcm0torIL6MB/fTX+0 uF0yaI3kW+sS6Ofka5/iq6GRw0dDby+3IM4NzimcYBNyPvYDOOJ4lFZIyRk/2JSXBm GLKTt7K15wy7nTriAMoErWiyj4ebuNe+S/GG1uqfKrHtaOlgRmdfuJxcyd5WyEp87z gl0EkPb3YJQuw== To: 58824@debbugs.gnu.org Subject: [PATCH v2] scripts: refresh: Support --list-dependent=packages. Date: Fri, 28 Oct 2022 16:30:52 +0100 Message-Id: <20221028153052.3051-1-paren@disroot.org> Mime-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit X-Spam-Score: 1.3 (+) X-Spam-Report: Spam detection software, running on the system "debbugs.gnu.org", has NOT identified this incoming email as spam. The original message has been attached to this so you can view it or label similar future email. If you have any questions, see the administrator of that system for details. Content preview: * guix/scripts/refresh.scm (%options)[list-dependent]: Allow an optional argument. Set 'LIST-DEPENDENT-MACHINE-READABLE? to #T in RESULT if the argument is "packages". (list-dependents): Support #:MAC [...] Content analysis details: (1.3 points, 10.0 required) pts rule name description ---- ---------------------- -------------------------------------------------- 1.3 FROM_ONE_CHAR Bogus FROM name -0.0 SPF_PASS SPF: sender matches SPF record 0.0 SPF_HELO_NONE SPF: HELO does not publish an SPF Record X-Debbugs-Envelope-To: 58824 Cc: "\(" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: 0.3 (/) * guix/scripts/refresh.scm (%options)[list-dependent]: Allow an optional argument. Set 'LIST-DEPENDENT-MACHINE-READABLE? to #T in RESULT if the argument is "packages". (list-dependents): Support #:MACHINE-READABLE?. (guix-refresh): Pass #:MACHINE-READABLE? #T to LIST-DEPENDENTS if 'LIST-DEPENDENT-MACHINE-READABLE? is #T. * doc/guix.texi: Document 'guix refresh --list-dependent=packages'. --- doc/guix.texi | 13 +++++++-- guix/scripts/refresh.scm | 62 ++++++++++++++++++++++++---------------- 2 files changed, 49 insertions(+), 26 deletions(-) diff --git a/doc/guix.texi b/doc/guix.texi index 3bfb89bc33..9800307888 100644 --- a/doc/guix.texi +++ b/doc/guix.texi @@ -14095,11 +14095,20 @@ be used when passing @command{guix refresh} one or more package names: @table @code -@item --list-dependent -@itemx -l +@item --list-dependent[=packages] +@itemx -l [packages] List top-level dependent packages that would need to be rebuilt as a result of upgrading one or more packages. +If the option is called with the optional @code{packages} argument, it +will display only the list of packages, without the header stating the +number of packages that will be rebuilt. This can be used to run +commands such as this, which builds all the dependents of @code{gtk}: + +@example +$ guix build $(guix refresh gtk -l packages) +@end example + @xref{Invoking guix graph, the @code{reverse-package} type of @command{guix graph}}, for information on how to visualize the list of dependents of a package. diff --git a/guix/scripts/refresh.scm b/guix/scripts/refresh.scm index 14329751f8..7c3f392a96 100644 --- a/guix/scripts/refresh.scm +++ b/guix/scripts/refresh.scm @@ -9,6 +9,7 @@ ;;; Copyright © 2019 Ricardo Wurmus ;;; Copyright © 2020 Simon Tournier ;;; Copyright © 2021 Sarah Morgensen +;;; Copyright © 2022 ( ;;; ;;; This file is part of GNU Guix. ;;; @@ -93,9 +94,12 @@ (define %options (option '(#\e "expression") #t #f (lambda (opt name arg result) (alist-cons 'expression arg result))) - (option '(#\l "list-dependent") #f #f + (option '(#\l "list-dependent") #f #t (lambda (opt name arg result) - (alist-cons 'list-dependent? #t result))) + (append `((list-dependent? . #t) + (list-dependent-machine-readable? + . ,(and arg (string=? arg "packages")))) + result))) (option '(#\r "recursive") #f #f (lambda (opt name arg result) (alist-cons 'recursive? #t result))) @@ -417,8 +421,10 @@ (define (all-packages) '() #:select? (const #t))) ;include hidden packages -(define (list-dependents packages) - "List all the things that would need to be rebuilt if PACKAGES are changed." +(define* (list-dependents packages #:key (machine-readable? #f)) + "List all the things that would need to be rebuilt if PACKAGES are +changed. If MACHINE-READABLE? is #T, display only a list of packages, +with no human-friendly extra text." ;; Using %BAG-NODE-TYPE is more accurate than using %PACKAGE-NODE-TYPE ;; because it includes implicit dependencies. (define (full-name package) @@ -431,27 +437,31 @@ (define (full-name package) (covering (filter (lambda (node) (null? (edges node))) dependents))) - (match dependents - (() - (format (current-output-port) - (N_ "No dependents other than itself: ~{~a~}~%" - "No dependents other than themselves: ~{~a~^ ~}~%" - (length packages)) - (map full-name packages))) - - ((x) - (format (current-output-port) - (G_ "A single dependent package: ~a~%") - (full-name x))) - (lst - (format (current-output-port) - (N_ "Building the following ~d package would ensure ~d \ + (if machine-readable? + (format (current-output-port) + (G_ "~{~a~^ ~}~%") + (map full-name covering)) + (match dependents + (() + (format (current-output-port) + (N_ "No dependents other than itself: ~{~a~}~%" + "No dependents other than themselves: ~{~a~^ ~}~%" + (length packages)) + (map full-name packages))) + ((x) + (format (current-output-port) + (G_ "A single dependent package: ~a~%") + (full-name x))) + (lst + (format (current-output-port) + (N_ "Building the following ~d package would ensure ~d \ dependent packages are rebuilt: ~{~a~^ ~}~%" - "Building the following ~d packages would ensure ~d \ + "Building the following ~d packages would ensure ~d \ dependent packages are rebuilt: ~{~a~^ ~}~%" - (length covering)) - (length covering) (length dependents) - (map full-name covering)))) + (length covering)) + (length covering) (length dependents) + (map full-name covering))))) + (return #t)))) (define (list-transitive packages) @@ -528,6 +538,8 @@ (define (options->updaters opts) (updaters (options->updaters opts)) (recursive? (assoc-ref opts 'recursive?)) (list-dependent? (assoc-ref opts 'list-dependent?)) + (list-dependent-machine-readable? + (assoc-ref opts 'list-dependent-machine-readable?)) (list-transitive? (assoc-ref opts 'list-transitive?)) (key-download (assoc-ref opts 'key-download)) @@ -543,7 +555,9 @@ (define (options->updaters opts) (mlet %store-monad ((packages (options->packages opts))) (cond (list-dependent? - (list-dependents packages)) + (list-dependents packages + #:machine-readable? + list-dependent-machine-readable?)) (list-transitive? (list-transitive packages)) (update? base-commit: f928abac369f699f425ddee925d0d0c2dc0a635d -- 2.38.0 From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 25 04:30:02 2022 Received: (at submit) by debbugs.gnu.org; 25 Nov 2022 09:30:03 +0000 Received: from localhost ([127.0.0.1]:33485 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oyV21-0003BD-W4 for submit@debbugs.gnu.org; Fri, 25 Nov 2022 04:30:02 -0500 Received: from lists.gnu.org ([209.51.188.17]:52882) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oyV1y-0003AN-Kz for submit@debbugs.gnu.org; Fri, 25 Nov 2022 04:29:59 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oyV1y-00026r-C9 for guix-patches@gnu.org; Fri, 25 Nov 2022 04:29:58 -0500 Received: from mail-wr1-x42d.google.com ([2a00:1450:4864:20::42d]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1oyV1w-0001Wh-Rw for guix-patches@gnu.org; Fri, 25 Nov 2022 04:29:58 -0500 Received: by mail-wr1-x42d.google.com with SMTP id v1so5842975wrt.11 for ; Fri, 25 Nov 2022 01:29:56 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=mime-version:message-id:date:in-reply-to:subject:cc:to:from:from:to :cc:subject:date:message-id:reply-to; bh=Ihn1YglQ7EK62bpjAwocOWlXKusnm6orp6yNgd/xC3Y=; b=ZG8rjtjj3bjeCqRFvc9W5OuhvAtrS4AWJediDdGomi1B7HIJR0QJpCleUBiULbH8e5 8CG5tKWvaueIVU7npY8/x+Te+nykW75kP3/EqhtL+JjWXL33SMzxKiMPoK0u1sJmtDB3 o/LWj9PwVPZhCGPaAWKEk+Mne9493CmUxv0jhwrr0pfgxx4aMr6HEzcLahJyENKiiVzV BeLSn+cIcEOu0jQ12akCgWFQBAmktUEYIeobnBj+Ot5NfmxGBcrazyxPk7UfopNdzdQ4 ReIT4DgjiYlEJCwokb4DHmV4EiPhRPiJq/x6YY/y0V2Xss1rcuHkULsjd66JqbvLJdfw Ql3A== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=mime-version:message-id:date:in-reply-to:subject:cc:to:from :x-gm-message-state:from:to:cc:subject:date:message-id:reply-to; bh=Ihn1YglQ7EK62bpjAwocOWlXKusnm6orp6yNgd/xC3Y=; b=sMvBwjs1RWuB1Q92xTbMXjcqtjdhmQLj+iBaidEKg8BlUSg5ULCt/ysuHk2LZmwQEh ym05LH5Pw5hzzgEyAuk3mmBlpnSvxU4JaS4WTQx5xXiaF4SNthFprNJ8PnxA1o77WCYv t0fzIZkxs3vJP+NuvYVxVnUrGr2m7b5DXnzsseipX/0tzL7IGfJyf/he95ED1rVvblo6 t4toCJ5xo2oIQk58WmtXsSFXgUrB3X1xd5h32XrRF18J7fIQ4Hn6nte+QgM81UKEJ51P kSPUuXNnFyIH77MrFRXfdArG1Pngm37GtuNGGYr0ss3kA6+vklEG+jeeVCWqMAQoiH3R xcUw== X-Gm-Message-State: ANoB5pkGmQSI8ics8+PT4GDMRi0D9sAHAVkuZtz5YtNz9yY4TCae8M6k U8xbAmFmrfSd1pb7Un50VA808YUxU80= X-Google-Smtp-Source: AA0mqf4hGlZGpyv0HfkHHuRtLf64eXZu8X0NLgPrjS3mC6DvARjNVy94CS0qOppipqU+rtcuqta1og== X-Received: by 2002:adf:ef90:0:b0:235:cebf:8a0f with SMTP id d16-20020adfef90000000b00235cebf8a0fmr22392714wro.220.1669368595482; Fri, 25 Nov 2022 01:29:55 -0800 (PST) Received: from lili ([2a01:e0a:59b:9120:65d2:2476:f637:db1e]) by smtp.gmail.com with ESMTPSA id o13-20020a05600c4fcd00b003cfa26c410asm9545799wmq.20.2022.11.25.01.29.54 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Fri, 25 Nov 2022 01:29:55 -0800 (PST) From: zimoun To: "( via Guix-patches via" , 58824@debbugs.gnu.org Subject: Re: [bug#58824] [PATCH 1/1] scripts: refresh: Support --list-dependent=packages. In-Reply-To: <20221027212859.21755-1-paren@disroot.org> Date: Fri, 25 Nov 2022 10:21:26 +0100 Message-ID: <86ilj3bd9l.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain Received-SPF: pass client-ip=2a00:1450:4864:20::42d; envelope-from=zimon.toutoune@gmail.com; helo=mail-wr1-x42d.google.com X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, FREEMAIL_FROM=0.001, RCVD_IN_DNSWL_NONE=-0.0001, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.3 (-) X-Debbugs-Envelope-To: submit Cc: "\(" X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.3 (--) Hi, On Thu, 27 Oct 2022 at 22:28, "\( via Guix-patches" via wrote: > - (option '(#\l "list-dependent") #f #f > + (option '(#\l "list-dependent") #f #t For what it is worth, I think it is a bad idea to have optional argument with short-name, well IMHO; see [1]. 1: Cheers, simon From debbugs-submit-bounces@debbugs.gnu.org Fri Nov 25 11:25:24 2022 Received: (at submit) by debbugs.gnu.org; 25 Nov 2022 16:25:24 +0000 Received: from localhost ([127.0.0.1]:37018 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oybVz-0006af-U7 for submit@debbugs.gnu.org; Fri, 25 Nov 2022 11:25:24 -0500 Received: from lists.gnu.org ([209.51.188.17]:52532) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1oybVx-0006aX-7G for submit@debbugs.gnu.org; Fri, 25 Nov 2022 11:25:22 -0500 Received: from eggs.gnu.org ([2001:470:142:3::10]) by lists.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oybVw-0008Bx-5B for guix-patches@gnu.org; Fri, 25 Nov 2022 11:25:20 -0500 Received: from knopi.disroot.org ([178.21.23.139]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1oybVt-0005hr-Dl for guix-patches@gnu.org; Fri, 25 Nov 2022 11:25:19 -0500 Received: from localhost (localhost [127.0.0.1]) by disroot.org (Postfix) with ESMTP id CA86A40833; Fri, 25 Nov 2022 17:25:13 +0100 (CET) X-Virus-Scanned: SPAM Filter at disroot.org Received: from knopi.disroot.org ([127.0.0.1]) by localhost (disroot.org [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id KcBZBiT76qei; Fri, 25 Nov 2022 17:25:12 +0100 (CET) Mime-Version: 1.0 DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/simple; d=disroot.org; s=mail; t=1669393512; bh=rNviTFOC7xg1nItPEKmqByACeOpvBdz/21mRnD30PKU=; h=Date:Subject:From:To:References:In-Reply-To:From; b=Be/kXudAC5Ift8f7WqWVx8SdxU1FmSxwLOIkqtGwcrtur0gQN+kI7EbZTl007AMH7 CSkHEdVeyYIDpgOv1hDvue7JKVleIig/McaXKc+ZsxLZxHfDpclo2U721rsdoHjA2l jE94fwPu3HB70gyOkDuJFnHSq6d3q4r34GWOyc4FRd7ewO5fQNrrNDU6DUhI6Gbfxq vUefpMfruWNrGIxpYykxKxBukeCf/Eumy0OqG87+f8gF+rGX1l8VrJHK5I7nDrAyKR 50rcmkbS/ZJVunMH4Z5fBHF/hBGT9PNAiXwzC1jFlB3JYjDfV90DYsAC8dS52aiX/i MKWglaRstFepw== Content-Transfer-Encoding: quoted-printable Content-Type: text/plain; charset=UTF-8 Date: Fri, 25 Nov 2022 16:25:11 +0000 Message-Id: Subject: Re: [bug#58824] [PATCH 1/1] scripts: refresh: Support --list-dependent=packages. From: "(" To: "zimoun" , "( via Guix-patches via" , <58824@debbugs.gnu.org> References: <20221027212859.21755-1-paren@disroot.org> <86ilj3bd9l.fsf@gmail.com> In-Reply-To: <86ilj3bd9l.fsf@gmail.com> Received-SPF: pass client-ip=178.21.23.139; envelope-from=paren@disroot.org; helo=knopi.disroot.org X-Spam_score_int: -20 X-Spam_score: -2.1 X-Spam_bar: -- X-Spam_report: (-2.1 / 5.0 requ) BAYES_00=-1.9, DKIM_SIGNED=0.1, DKIM_VALID=-0.1, DKIM_VALID_AU=-0.1, DKIM_VALID_EF=-0.1, SPF_HELO_NONE=0.001, SPF_PASS=-0.001 autolearn=ham autolearn_force=no X-Spam_action: no action X-Spam-Score: -1.4 (-) X-Debbugs-Envelope-To: submit X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -2.4 (--) On Fri Nov 25, 2022 at 9:21 AM GMT, zimoun wrote: > For what it is worth, I think it is a bad idea to have optional argument > with short-name, well IMHO; see [1]. > > 1: Hmm. Perhaps we could replace this with a whole new -D, --list-dependent-packages flag? -- ( From debbugs-submit-bounces@debbugs.gnu.org Mon Nov 28 07:53:06 2022 Received: (at 58824) by debbugs.gnu.org; 28 Nov 2022 12:53:06 +0000 Received: from localhost ([127.0.0.1]:48426 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ozddC-00041r-Bo for submit@debbugs.gnu.org; Mon, 28 Nov 2022 07:53:06 -0500 Received: from mail-wr1-f43.google.com ([209.85.221.43]:38443) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1ozddA-00041N-Dj for 58824@debbugs.gnu.org; Mon, 28 Nov 2022 07:53:04 -0500 Received: by mail-wr1-f43.google.com with SMTP id n3so16643998wrp.5 for <58824@debbugs.gnu.org>; Mon, 28 Nov 2022 04:53:04 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:to:from:from:to:cc:subject:date:message-id :reply-to; bh=hXuFXk8PzVFiH0LpOLyR8IWCcLlsdU4Rf2cO1qeZm/k=; b=RMA7PyuYmSWxIti2za4e+++iVShdHkcE1t+LfS+wXtwj6swRnMYYLuwyE2/3Q3WtDM xa95xbf172gxuQAvnW3lCVh6Rfew6RQUF0QenS7VpqVwvf433+P3zHvxeIfD6K8xF4CY SfAsEsNMwq2ydAkKBLcYBpkRknaVtvFTkNM0QbskERpY7eFKj4sPX+S9yDx3kEgmkx0u DBGgVqzAzBnOdE4kAB6bMZwsDjPg0rpgEeP8uXxZuk56njNnVC6IGiT5iPeCRbG0n68h O/t3rQsWVBvEikPpNAUg28ltu0fiuV2TjWEIcxm7Md0ouLPMMChK3XwscuamI2fOCqV/ U+RA== X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=1e100.net; s=20210112; h=content-transfer-encoding:mime-version:message-id:date:references :in-reply-to:subject:to:from:x-gm-message-state:from:to:cc:subject :date:message-id:reply-to; bh=hXuFXk8PzVFiH0LpOLyR8IWCcLlsdU4Rf2cO1qeZm/k=; b=1jD+zhFlf9/r/BiAwKipHfI2JjOvnFdNIB92+GC10KtS6uybWDqdWSn+8f5omh7jZ6 qdctqBe0ILkytDU1FO1RN2Xsc4OoHGB9MmzQvzUnwfPcn7inuojtLaDggj7hCyoLcfWH jxH7gqsGSzuDgRUtnSN1AhgIFtySNXOJ+6l/Av+6etIQAngFQ3IDBGcbqlGWSUyjbiwb PzbuWjbxA8n93usm+lfMWUW9Q0r+aLC4IkOBCsK31hGo1Kc/keSaMlOz5M0UqbmyqBzF oT2dAKQbbjxddCLG6nEgfeBhugllDzUZl10G2n11EVpIDE/05TKKZlGFIHJH3O0p0UfQ DwuA== X-Gm-Message-State: ANoB5pmo7r3Ar/RQruv2zwcRA20uKgk08TWpZKeABQjyFmq/XpOp2Ea8 vt+qmpkatHic/kQsJZ2xNyEtB7IeZ5A= X-Google-Smtp-Source: AA0mqf5bhAc0uSmp26zMTXQRpmB3A6FzqD27qdd9JgZTSevz5SVP06w0fOt7hmgxHZoOZBROW2+tvA== X-Received: by 2002:a05:6000:112:b0:241:d25a:e57b with SMTP id o18-20020a056000011200b00241d25ae57bmr23308159wrx.418.1669639978288; Mon, 28 Nov 2022 04:52:58 -0800 (PST) Received: from pfiuh07 ([193.48.40.241]) by smtp.gmail.com with ESMTPSA id x16-20020a5d6b50000000b0022a3a887ceasm10647405wrw.49.2022.11.28.04.52.57 (version=TLS1_3 cipher=TLS_AES_256_GCM_SHA384 bits=256/256); Mon, 28 Nov 2022 04:52:57 -0800 (PST) From: zimoun To: "(" , 58824@debbugs.gnu.org Subject: Re: [bug#58824] [PATCH 1/1] scripts: refresh: Support --list-dependent=packages. In-Reply-To: References: <20221027212859.21755-1-paren@disroot.org> <86ilj3bd9l.fsf@gmail.com> Date: Fri, 25 Nov 2022 19:01:06 +0100 Message-ID: <87ilj2ud5p.fsf@gmail.com> MIME-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: quoted-printable X-Spam-Score: 0.0 (/) X-Debbugs-Envelope-To: 58824 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: debbugs-submit-bounces@debbugs.gnu.org Sender: "Debbugs-submit" X-Spam-Score: -1.0 (-) Hi, On Fri, 25 Nov 2022 at 16:25, "\( via Guix-patches" via wrote: > Hmm. Perhaps we could replace this with a whole new > > -D, --list-dependent-packages > > flag? Vagrant proposed [1] to add a flag as --machine-readable, quoting: I vaguely recall discussing on irc not long ago the desire for "guix refresh --list-dependent --machine-readable" (e.g. drop the "Buildi= ng the following X packages would ensure 10 dependent packages are rebuilt:") or something similar. Would save having to pipe to cut, = awk, sed, perl, etc. ... Well, there is also the annoyance that hidden packages are shown so it becomes cumbersome for piping with =E2=80=9Cguix build=E2=80=9D for instanc= e. Maybe, this patch could be tweaked to have something like, guix refresh --list-build-dependent PACKAGE returning a list accepted by =E2=80=9Cguix build=E2=80=9D. 1: Cheers, simon