From patchwork Mon Apr 1 20:25:13 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 7bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62440 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id ED6CF27BBEA; Mon, 1 Apr 2024 21:26:09 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 8A3CC27BBE2 for ; Mon, 1 Apr 2024 21:26:09 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOEG-00082z-P0; Mon, 01 Apr 2024 16:26:05 -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 1rrOED-00082X-28 for guix-patches@gnu.org; Mon, 01 Apr 2024 16:26:01 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOEC-0006oW-Pa; Mon, 01 Apr 2024 16:26:00 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOEE-0007Gj-Dm; Mon, 01 Apr 2024 16:26:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 01/11] channels: Use SRFI-71 instead of SRFI-11. Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200315127891 (code B ref 70132); Mon, 01 Apr 2024 20:26:02 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:25:51 +0000 Received: from localhost ([127.0.0.1]:51651 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOE3-0007Fm-DK for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:25:51 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48922) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOE1-0007FQ-Bl for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:25:50 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrODs-0006lW-Bv; Mon, 01 Apr 2024 16:25:40 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=ySZCPnu9YVlQI7ZkdzyXyTa2iIQ31ccTumDfgNRdxZM=; b=it1FEcHDLSQ3FJPsD9YZ gpYk0Dex90hiXyKISM7KOBDp356tLazfjPLg4D9DIfGHQMPAax3hFN9vfePdzxr2jQCCmzlm+MfQR 16OnUj/ayOGrtEwD4O/+NLG1L9E+eJMqlm62vEanyVfpywrgrxsePuzTBhN9CDpdAOOBa6dCIud8r uWKdu8n/ijeGa2BIHMen6jtUKKNE1MQeij5xAJUmVvTHtzv3gD9BimpzEq8pEvh6PzBKUnT7a5E+8 lXyWRhV2QRuZea3q+74ZcS/Ov0frXjlUkInR7MbdQPcmkEoJe17h2zHmnfe/pAY6i9XQslruLjrBx 75NhU1eJaNZA9A==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:13 +0200 Message-ID: <6f4f3bb9ebafe98416d378e9438c9453fae613d2.1712002698.git.ludo@gnu.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * guix/channels.scm (latest-channel-instance): Use SRFI-71. Change-Id: I73531c98b3034e228006ed91518cc7bfedc784fd --- guix/channels.scm | 13 ++++++------- 1 file changed, 6 insertions(+), 7 deletions(-) diff --git a/guix/channels.scm b/guix/channels.scm index 66f3122f79..10f0e3800f 100644 --- a/guix/channels.scm +++ b/guix/channels.scm @@ -43,10 +43,10 @@ (define-module (guix channels) #:use-module (srfi srfi-1) #:use-module (srfi srfi-2) #:use-module (srfi srfi-9) - #:use-module (srfi srfi-11) #:use-module (srfi srfi-26) #:use-module (srfi srfi-34) #:use-module (srfi srfi-35) + #:use-module (srfi srfi-71) #:autoload (guix describe) (current-channels) ;XXX: circular dep #:autoload (guix self) (whole-package make-config.scm) #:autoload (guix inferior) (gexp->derivation-in-inferior) ;FIXME: circular dep @@ -411,12 +411,11 @@ (define* (latest-channel-instance store channel (and (string=? (basename file) ".git") (eq? 'directory (stat:type stat)))) - (let-values (((channel) - (ensure-default-introduction channel)) - ((checkout commit relation) - (update-cached-checkout (channel-url channel) - #:ref (channel-reference channel) - #:starting-commit starting-commit))) + (let ((channel (ensure-default-introduction channel)) + (checkout commit relation + (update-cached-checkout (channel-url channel) + #:ref (channel-reference channel) + #:starting-commit starting-commit))) (when relation (validate-pull channel starting-commit commit relation)) From patchwork Mon Apr 1 20:25:14 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62444 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id C25BA27BBEA; Mon, 1 Apr 2024 21:26:32 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id E9D3527BBE2 for ; Mon, 1 Apr 2024 21:26:31 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOEa-00088w-N3; Mon, 01 Apr 2024 16:26:24 -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 1rrOEE-00082j-CH for guix-patches@gnu.org; Mon, 01 Apr 2024 16:26:02 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOEE-0006oo-0J; Mon, 01 Apr 2024 16:26:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOEE-0007H3-U5; Mon, 01 Apr 2024 16:26:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 02/11] git: Add =?utf-8?b?4oCYcmVwb3NpdG9yeS1p?= =?utf-8?b?bmZv4oCZ?= and use it in (guix channels). Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:26:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200315227897 (code B ref 70132); Mon, 01 Apr 2024 20:26:02 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:25:52 +0000 Received: from localhost ([127.0.0.1]:51653 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOE3-0007Fp-PD for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:25:52 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48926) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOE2-0007FS-AZ for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:25:50 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrODt-0006lf-MR; Mon, 01 Apr 2024 16:25:41 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=y2ykFhnttS1YRD6bIrNyjtgMcfA+SjyDkZ4r96dbuu4=; b=HkXjTA1KSt9c558bMmDj 2nLTosaA9GQFt5Uz4GR4orb4WgJMqn4I/SoZKx1wJHmTUGJTCT+bXESHVLTljtucQqvyf/cXZ2yDV WwXonh0rrm0VwgFddJGVO33ylsLbRZBLsRhtMxIfdyaLnfRca0RM42t8V+AguHFkH9NOptNLwhKRm 7TnKZncD9JxMlkXCjfUos60O6jvpPPKSUM6OvYOGV2hR0v1y7d5Kb/eugSPW7cjbfCGDCMxrN3bRp 6AhiDpLixWlYX9aUkEEPqC7uOXcOaVrPrN9SVUgislTNydotmR2vFCBO8nKAZItN2H74jaUGOuL7Y 2h7gRO2PvDT+sw==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:14 +0200 Message-ID: <0b963eb469dfa61649ca3a75f6745f3ca0a041a9.1712002698.git.ludo@gnu.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * guix/git.scm (repository-info): New procedure. * guix/channels.scm (repository->guix-channel): Use it instead of local code. Change-Id: I74c758c73a22e16031571ca4271cc9cab0492f6e --- guix/channels.scm | 20 ++++++++------------ guix/git.scm | 19 ++++++++++++++++++- 2 files changed, 26 insertions(+), 13 deletions(-) diff --git a/guix/channels.scm b/guix/channels.scm index 10f0e3800f..f26ccbc3ae 100644 --- a/guix/channels.scm +++ b/guix/channels.scm @@ -24,6 +24,7 @@ (define-module (guix channels) #:autoload (guix git) (update-cached-checkout url+commit->name commit-difference + repository-info with-repository) #:autoload (guix git-authenticate) (authenticate-repository) #:autoload (guix openpgp) (openpgp-public-key-fingerprint @@ -207,18 +208,13 @@ (define* (repository->guix-channel directory channel that uses that repository and the commit HEAD currently points to; use INTRODUCTION as the channel's introduction. Return #f if no Git repository could be found at DIRECTORY or one of its ancestors." - (catch 'git-error - (lambda () - (with-repository (repository-discover directory) repository - (let* ((head (repository-head repository)) - (commit (oid->string (reference-target head)))) - (channel - (inherit %default-guix-channel) - (url (repository-working-directory repository)) - (commit commit) - (branch (reference-shorthand head)) - (introduction introduction))))) - (const #f))) + (let ((directory commit branch (repository-info directory))) + (channel + (inherit %default-guix-channel) + (url directory) + (commit commit) + (branch branch) + (introduction introduction)))) (define-record-type (channel-instance channel commit checkout) diff --git a/guix/git.scm b/guix/git.scm index cbcdb1904b..760b064a9c 100644 --- a/guix/git.scm +++ b/guix/git.scm @@ -1,6 +1,6 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2017, 2020 Mathieu Othacehe -;;; Copyright © 2018-2023 Ludovic Courtès +;;; Copyright © 2018-2024 Ludovic Courtès ;;; Copyright © 2021 Kyle Meyer ;;; Copyright © 2021 Marius Bakke ;;; Copyright © 2022 Maxime Devos @@ -59,6 +59,7 @@ (define-module (guix git) with-repository with-git-error-handling false-if-git-not-found + repository-info update-cached-checkout url+commit->name latest-repository-commit @@ -330,6 +331,22 @@ (define-syntax-rule (with-git-error-handling body ...) (lambda (key err) (report-git-error err)))) +(define (repository-info directory) + "Open the Git repository in DIRECTORY or one of its parent and return three +values: the working directory of that repository, its checked out commit ID, +and its checked out reference (such as a branch name). Return #f (three +values) if DIRECTORY does not hold a readable Git repository." + (catch 'git-error + (lambda () + (with-repository (repository-discover directory) repository + (let* ((head (repository-head repository)) + (commit (oid->string (reference-target head)))) + (values (repository-working-directory repository) + commit + (reference-shorthand head))))) + (lambda _ + (values #f #f #f)))) + (define* (update-submodules repository #:key (log-port (current-error-port)) (fetch-options #f)) From patchwork Mon Apr 1 20:25:15 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62442 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id E012827BBEA; Mon, 1 Apr 2024 21:26:27 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 6B56A27BBE2 for ; Mon, 1 Apr 2024 21:26:26 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOEE-00082f-0d; Mon, 01 Apr 2024 16:26:02 -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 1rrOEC-00082O-K0 for guix-patches@gnu.org; Mon, 01 Apr 2024 16:26:00 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOEC-0006oJ-9Z; Mon, 01 Apr 2024 16:26:00 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOEF-0007HE-F2; Mon, 01 Apr 2024 16:26:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 03/11] channels: Move =?utf-8?b?4oCYY29tbWl0LXNo?= =?utf-8?b?b3J0LWlk4oCZ?= to (guix git). Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:26:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200315427912 (code B ref 70132); Mon, 01 Apr 2024 20:26:03 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:25:54 +0000 Received: from localhost ([127.0.0.1]:51657 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOE6-0007G7-8W for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:25:54 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:48934) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOE4-0007FV-MV for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:25:53 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrODw-0006ls-1M; Mon, 01 Apr 2024 16:25:44 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=5Bpm9i/CLHhv31C1rAdprAEtyu3N+38RkNqUCQAmL4M=; b=PG9LfvDUTIFRQon9333j ok/0SyHCLQ/0AP81K+NJZsOjCNTjhkZWjOtjgFJ5ZQbBN7WiCZ2jhk/PVulZt+X1PVwLnYl9ovMo/ Ayzne8yDVlsQ9HSak/0Vg5+8yYP40Yu28WoOME1ahEbvu9Iq4Rztquycap4krMvbtJAuevSZazyzK Xau8D8Y3ZT3z89qFuoEki+XRc1WPJC4piiDicBDdtIwJoOhhTpL+juewejydVsFtbVmc7JYoNnXHN fyYyB+ayXh7O99OdXW2cbRDINRXsx2QrGrjagl4V3wyza148BTDh4q/lBuPF89pifbv37oqUkwfpy CZMiiv06c4fvdQ==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:15 +0200 Message-ID: <40070393934abb8d6a785857dc3806217e64817b.1712002698.git.ludo@gnu.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * guix/channels.scm (commit-short-id): Move to… * guix/git.scm (commit-short-id): … here. Change-Id: If4b34b1d82b1aa5068d157f26e57e8aecc967061 --- guix/channels.scm | 4 +--- guix/git.scm | 4 ++++ 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/guix/channels.scm b/guix/channels.scm index f26ccbc3ae..0b776ab211 100644 --- a/guix/channels.scm +++ b/guix/channels.scm @@ -25,6 +25,7 @@ (define-module (guix channels) url+commit->name commit-difference repository-info + commit-short-id with-repository) #:autoload (guix git-authenticate) (authenticate-repository) #:autoload (guix openpgp) (openpgp-public-key-fingerprint @@ -339,9 +340,6 @@ (define (apply-patches checkout commit patches) (apply-patch patch checkout)) (loop rest))))) -(define commit-short-id - (compose (cut string-take <> 7) oid->string commit-id)) - (define* (authenticate-channel channel checkout commit #:key (keyring-reference-prefix "origin/")) "Authenticate the given COMMIT of CHANNEL, available at CHECKOUT, a diff --git a/guix/git.scm b/guix/git.scm index 760b064a9c..eab84ea798 100644 --- a/guix/git.scm +++ b/guix/git.scm @@ -67,6 +67,7 @@ (define-module (guix git) commit-relation commit-descendant? commit-id? + commit-short-id remote-refs @@ -233,6 +234,9 @@ (define (commit-id? str) (and (= (string-length str) 40) (string-every char-set:hex-digit str))) +(define commit-short-id + (compose (cut string-take <> 7) oid->string commit-id)) + (define (resolve-reference repository ref) "Resolve the branch, commit or tag specified by REF, and return the corresponding Git object." From patchwork Mon Apr 1 20:25:16 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62441 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id C162327BBE9; Mon, 1 Apr 2024 21:26:27 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id A479127BBEA for ; Mon, 1 Apr 2024 21:26:26 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOEU-000854-Id; Mon, 01 Apr 2024 16:26:20 -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 1rrOEE-00082i-C2 for guix-patches@gnu.org; Mon, 01 Apr 2024 16:26:02 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOED-0006on-VA; Mon, 01 Apr 2024 16:26:02 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOEG-0007HX-0I; Mon, 01 Apr 2024 16:26:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 04/11] git: Add =?utf-8?b?4oCYdGFnLT5jb21taXQ=?= =?utf-8?b?4oCZ?= and use it in (guix channels). Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:26:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200316227950 (code B ref 70132); Mon, 01 Apr 2024 20:26:03 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:26:02 +0000 Received: from localhost ([127.0.0.1]:51661 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOED-0007GS-Le for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:02 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59796) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEB-0007G8-B1 for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:25:59 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrOE2-0006mP-LR; Mon, 01 Apr 2024 16:25:50 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=jnPjGJ0K3R62W91yhymu2cQDh5GvroPIaGSYOfwFkWI=; b=CU5Oip6knmLkTm0/plRA 8PPA3VaNNWTJxvHHPWnNzjyPR6z2ymjM9Q7NTS/6mPTkfMaqUVmgCTqgXH+TZXjbO/qz5G6skaUgj Z5hDvBGy65UW0OrUSA1R6Y0cKe4EqSMQ+ITUlEfer/xAk/+9KN1lqvHhpxsgllF6KBsn127f5OrRg /eysM5phmcxZK10gQmKroTpKJR6JbkPlUtJLvCCawzQZKYr2B5SKG1j5QZ2aFGsYPuEUkxc9uaAWq R9KGhdo0wXa6qibUP2Y9nJ0T02btqRaj7AV0RWlWWsN6kDJvPUloQbPnFEn78uFFT3aAdYqqKCjpl LbWO79Lnml8zEg==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:16 +0200 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * guix/git.scm (tag->commit): New procedure, taken from… (resolve-reference): … here. Use it in the ‘tag’ case. * guix/channels.scm (resolve-channel-news-entry-tag): Use ‘tag->commit’ instead of custom code. Change-Id: I46ea387345dc1b695ce0702991a52d0cde29e2f0 --- guix/channels.scm | 11 +++-------- guix/git.scm | 24 +++++++++++++++--------- 2 files changed, 18 insertions(+), 17 deletions(-) diff --git a/guix/channels.scm b/guix/channels.scm index 0b776ab211..70608561f9 100644 --- a/guix/channels.scm +++ b/guix/channels.scm @@ -26,6 +26,7 @@ (define-module (guix channels) commit-difference repository-info commit-short-id + tag->commit with-repository) #:autoload (guix git-authenticate) (authenticate-repository) #:autoload (guix openpgp) (openpgp-public-key-fingerprint @@ -1148,14 +1149,8 @@ (define (resolve-channel-news-entry-tag repository entry) cannot be found." (if (channel-news-entry-commit entry) entry - (let* ((tag (channel-news-entry-tag entry)) - (reference (reference-lookup repository - (string-append "refs/tags/" tag))) - (target (reference-target reference)) - (oid (let ((obj (object-lookup repository target))) - (if (= OBJ-TAG (object-type obj)) ;annotated tag? - (tag-target-id (tag-lookup repository target)) - target)))) + (let* ((tag (channel-news-entry-tag entry)) + (oid (object-id (tag->commit repository tag)))) (channel-news-entry (oid->string oid) tag (channel-news-entry-title entry) (channel-news-entry-body entry))))) diff --git a/guix/git.scm b/guix/git.scm index eab84ea798..8e1d863976 100644 --- a/guix/git.scm +++ b/guix/git.scm @@ -68,6 +68,7 @@ (define-module (guix git) commit-descendant? commit-id? commit-short-id + tag->commit remote-refs @@ -237,6 +238,19 @@ (define (commit-id? str) (define commit-short-id (compose (cut string-take <> 7) oid->string commit-id)) +(define (tag->commit repository tag) + "Resolve TAG in REPOSITORY and return the corresponding object, usually a +commit." + (let* ((oid (reference-name->oid repository + (string-append "refs/tags/" tag))) + (obj (object-lookup repository oid))) + ;; OID may designate an "annotated tag" object or a "commit" object. + ;; Return the commit object in both cases. + (if (= OBJ-TAG (object-type obj)) + (object-lookup repository + (tag-target-id (tag-lookup repository oid))) + obj))) + (define (resolve-reference repository ref) "Resolve the branch, commit or tag specified by REF, and return the corresponding Git object." @@ -283,15 +297,7 @@ (define (resolve-reference repository ref) ;; There's no such tag, so it must be a commit ID. (resolve `(commit . ,str))))))) (('tag . tag) - (let* ((oid (reference-name->oid repository - (string-append "refs/tags/" tag))) - (obj (object-lookup repository oid))) - ;; OID may designate an "annotated tag" object or a "commit" object. - ;; Return the commit object in both cases. - (if (= OBJ-TAG (object-type obj)) - (object-lookup repository - (tag-target-id (tag-lookup repository oid))) - obj)))))) + (tag->commit repository tag))))) (define (switch-to-ref repository ref) "Switch to REPOSITORY's branch, commit or tag specified by REF. Return the From patchwork Mon Apr 1 20:25:17 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62443 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 1E00F27BBE9; Mon, 1 Apr 2024 21:26:29 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 1D0CA27BBE2 for ; Mon, 1 Apr 2024 21:26:28 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOEb-00089g-3G; Mon, 01 Apr 2024 16:26:25 -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 1rrOEH-00083K-1e for guix-patches@gnu.org; Mon, 01 Apr 2024 16:26:07 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOEF-0006p8-HF; Mon, 01 Apr 2024 16:26:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOEG-0007Hq-FL; Mon, 01 Apr 2024 16:26:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 05/11] channels: Autoload (git =?utf-8?b?4oCm?=) modules. Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:26:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200316327991 (code B ref 70132); Mon, 01 Apr 2024 20:26:04 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:26:03 +0000 Received: from localhost ([127.0.0.1]:51671 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEF-0007HD-Dy for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:03 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59800) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOED-0007GG-NY for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:02 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrOE4-0006n3-3i; Mon, 01 Apr 2024 16:25:52 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=QCjaqoWvZGnddRRTmah5ug4E3o1enrIoplhFq6pNJfk=; b=GckNv3TfYNp7xPpfKiZJ b3yha74jfPxX+2+qLO6bNb8rIOyftHzz+PlruxKTJeMPbGSZxKh9fUoSin0Mv8UnUNnMn5SYhNNLD UvgtqyIvhABSilZ0ibUXm/GnOsgiwfKl2csij248UR++3kxuakTQrcH7Lfx8AgaW6lZNtK52oFgDb 4Vfp6Cxs5psnmRh3ZmF3SSmNBFdcoukIodVtJZdOaoTvhLHDDy0dD5b7Ye2vsRrMVHDQEZ1Uzp9Ei 8R7N5NC5z2dEQ629xHsLOUlWos3mINHttd0iK4D6LU5AmflL5xJZkiVf/LL2WyYjclpAckgzWPMyM R1+Wwm9wqZctZQ==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:17 +0200 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches Autoloading Guile-Git is important in cases where (guix channels) is used for little more than the definition. This is the case, for example, of ‘guix describe’ or ‘guix shell’. This reduces from 177 to 121 the number of .go files loaded when running: ./pre-inst-env strace -e openat -o /tmp/log.strace \ guix describe -p /var/guix/profiles/per-user/$USER/current-guix grep 'openat.*\.go.* = [0-9]' < /tmp/log.strace |wc -l Likewise, it reduces the max RSS (as measured by ‘time -f %M guix describe -p …’) from 54 to 37 MiB. * guix/channels.scm: Autoload (git …) modules. Change-Id: Ia58a99c865bf0f6fe461a1e71390d075e760f8d6 --- guix/channels.scm | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/guix/channels.scm b/guix/channels.scm index 70608561f9..51024dcad4 100644 --- a/guix/channels.scm +++ b/guix/channels.scm @@ -20,7 +20,13 @@ ;;; along with GNU Guix. If not, see . (define-module (guix channels) - #:use-module (git) ;TODO: autoload + #:autoload (git commit) (commit-lookup + commit-id) + #:autoload (git oid) (oid->string + string->oid) + #:autoload (git object) (object-id) + #:autoload (git errors) (GIT_ENOTFOUND) + #:autoload (git structs) (git-error-code) #:autoload (guix git) (update-cached-checkout url+commit->name commit-difference From patchwork Mon Apr 1 20:25:18 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62445 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id B285327BBE9; Mon, 1 Apr 2024 21:26:41 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 15D5327BBE2 for ; Mon, 1 Apr 2024 21:26:41 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOEd-0008CH-7V; Mon, 01 Apr 2024 16:26:27 -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 1rrOEH-00083H-1A for guix-patches@gnu.org; Mon, 01 Apr 2024 16:26:06 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOEF-0006p6-9d; Mon, 01 Apr 2024 16:26:04 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOEG-0007I2-UM; Mon, 01 Apr 2024 16:26:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 06/11] guix system: Autoload some more. Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:26:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200316428008 (code B ref 70132); Mon, 01 Apr 2024 20:26:04 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:26:04 +0000 Received: from localhost ([127.0.0.1]:51677 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEF-0007HV-Rw for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:04 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59808) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEE-0007GJ-9D for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:02 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrOE5-0006nM-Jj; Mon, 01 Apr 2024 16:25:53 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=XxxCKbSEUW2Pg3/b+lua0iSJZmmODkDyB0SOTS+vwNY=; b=igzkE5zKMGNr0Rox3iXt C1qvOvKrkQCD/3auCeQ3ZtBLLCU5H7xtKMTLUax1tVv85LOcetBlGmjn6OuwJdKk0hwhM4wpq04K7 4NDymAWuGxZ14BoHuNDxnz5j0/TRoo0rJnRnM66HQCFY05dGtx4TWplIS8uf1aI+PEJc80nPd6+dF RkkBMq16kBEepY5kqA2IrXqo1UGrCTg8/DaQFP+1DFX8jIVcuRF/PyiuKdzKzZLXV9i1C/3iWneT2 AXO/djZUvoLJazRLhmbw6Ilj3M6eACeZTlqCwcRcWKwsb99yVztHHZmhrwZN48dm48IkzUF96s0be XewhzhxhSzy/6Q==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:18 +0200 Message-ID: <45625999e3252f94a596de1f75b70b5186a765cf.1712002698.git.ludo@gnu.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * guix/scripts/system.scm: Autoload more modules. Change-Id: I665857109bbfd1e3755135daacc01affcb3eb2eb --- guix/scripts/system.scm | 12 ++++++++---- 1 file changed, 8 insertions(+), 4 deletions(-) diff --git a/guix/scripts/system.scm b/guix/scripts/system.scm index bf3d2f9044..6952d454e6 100644 --- a/guix/scripts/system.scm +++ b/guix/scripts/system.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2014-2023 Ludovic Courtès +;;; Copyright © 2014-2024 Ludovic Courtès ;;; Copyright © 2016 Alex Kost ;;; Copyright © 2016, 2017, 2018 Chris Marusich ;;; Copyright © 2017, 2019 Mathieu Othacehe @@ -37,7 +37,7 @@ (define-module (guix scripts system) #:autoload (guix store database) (sqlite-register store-database-file call-with-database) #:autoload (guix build store-copy) (copy-store-item) - #:use-module (guix describe) + #:autoload (guix describe) (current-profile) #:use-module (guix gexp) #:use-module (guix derivations) #:use-module (guix diagnostics) @@ -47,7 +47,10 @@ (define-module (guix scripts system) #:use-module (guix records) #:use-module (guix profiles) #:use-module (guix scripts) - #:use-module (guix channels) + #:autoload (guix channels) (channel-name + channel-url + channel-branch + channel-commit) #:use-module (guix scripts build) #:autoload (guix scripts package) (delete-generations delete-matching-generations @@ -57,7 +60,8 @@ (define-module (guix scripts system) graph-backend-name lookup-backend) #:use-module (guix scripts system reconfigure) #:use-module (guix build utils) - #:use-module (guix progress) + #:autoload (guix progress) (progress-reporter/bar + call-with-progress-reporter) #:use-module ((guix docker) #:select (%docker-image-max-layers)) #:use-module (gnu build image) #:use-module (gnu build install) From patchwork Mon Apr 1 20:25:19 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62448 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id A9BDC27BBE9; Mon, 1 Apr 2024 21:27:36 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id D7FD127BBE2 for ; Mon, 1 Apr 2024 21:27:34 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOFc-00005B-GW; Mon, 01 Apr 2024 16:27:29 -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 1rrOFG-0008UR-PE for guix-patches@gnu.org; Mon, 01 Apr 2024 16:27:07 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOFG-0006xf-Dg; Mon, 01 Apr 2024 16:27:06 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOFC-0007LI-Pg; Mon, 01 Apr 2024 16:27:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 07/11] utils: =?utf-8?b?RG9u4oCZdA==?= re-export =?utf-8?q?=E2=80=98call-with-temporary-output-file=E2=80=99=2E?= Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, julien@lepiller.eu, lars@6xq.net, ludo@gnu.org, marius@gnu.org, othacehe@gnu.org, me@bonfacemunyoki.com, rekado@elephly.net, sharlatanus@gmail.com, zimon.toutoune@gmail.com, tanguy@bioneland.org, me@tobias.gr, jgart@dismail.de, pukkamustard@posteo.net, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Julien Lepiller , Lars-Dominik Braun , Ludovic =?utf-8?q?Court=C3=A8s?= , Marius Bakke , Mathieu Othacehe , Munyoki Kilyungi , Ricardo Wurmus , Sharlatan Hellseher , Simon Tournier , Tanguy Le Carrour , Tobias Geerinckx-Rice , jgart , pukkamustard X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Julien Lepiller , Lars-Dominik Braun , Ludovic =?utf-8?q?Court=C3=A8s?= , Marius Bakke , Mathieu Othacehe , Munyoki Kilyungi , Ricardo Wurmus , Sharlatan Hellseher , Simon Tournier , Tanguy Le Carrour , Tobias Geerinckx-Rice , jgart , pukkamustard Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200317128134 (code B ref 70132); Mon, 01 Apr 2024 20:27:02 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:26:11 +0000 Received: from localhost ([127.0.0.1]:51725 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEL-0007Jb-PW for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:10 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59828) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEJ-0007Gb-26 for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:08 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrOE6-0006na-Gb; Mon, 01 Apr 2024 16:25:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=xsYU+hhTBacQmxiR+Rpns5bzsOe5xNTZcjdpL+PMt94=; b=hXNvzIoAXsMsaLuZxJot 7DCUl2nmuiO5KQzzSDOc63qGy7tyErrVpAzg9vzO8wfSLP2Qza3QYobUbsgeLvaQomyCFWMLybLPK pVez3LxyJnJJr8YkFlFC6eOY/bpVkykhPLy8dv0RTwE+QEE6AxUAlAYgDaB8Mt9TNjD4DJOzQ0TSJ bfa3nOHS3sWRlEGeGLIq0QVH6wCApCacc8BIvfPF7txAjtW0eUPgOKswNK5Hh05rWjJTh1DdxrIg6 kQGu+FANdksT7FwbnHyCc3mrUI47mPZY5mDCn6x8nWn6vWoZM5Xzx/NLHwK4n/Ve3MTMywN6+tCKW 3gUgJCZs5J6rpQ==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:19 +0200 Message-ID: <0347e5d07c684f680ae2e983b3b44830cbcd74a5.1712002698.git.ludo@gnu.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * guix/utils.scm: Remove re-export of ‘call-with-temporary-output-file’. Autoload a number of modules. * guix/download.scm, guix/import/hackage.scm, guix/import/hexpm.scm, guix/import/opam.scm, guix/import/pypi.scm, tests/cpio.scm, tests/egg.scm, tests/opam.scm, tests/publish.scm, tests/store-database.scm, tests/utils.scm: Adjust imports accordingly. Change-Id: I3f5e94631397996a30be2ea4ff8b50a3371e8ee7 --- guix/download.scm | 2 +- guix/import/hackage.scm | 4 ++-- guix/import/hexpm.scm | 7 ++++--- guix/import/opam.scm | 7 ++++--- guix/import/pypi.scm | 5 +++-- guix/utils.scm | 17 ++++++++--------- tests/cpio.scm | 6 +++--- tests/egg.scm | 5 +++-- tests/opam.scm | 5 +++-- tests/publish.scm | 5 +++-- tests/store-database.scm | 6 +++--- tests/utils.scm | 3 ++- 12 files changed, 39 insertions(+), 33 deletions(-) diff --git a/guix/download.scm b/guix/download.scm index 3dfe143e9f..192c47f113 100644 --- a/guix/download.scm +++ b/guix/download.scm @@ -31,7 +31,7 @@ (define-module (guix download) #:autoload (guix build download) (url-fetch) #:use-module (guix monads) #:use-module (guix gexp) - #:use-module (guix utils) + #:autoload (guix build utils) (call-with-temporary-output-file) #:use-module (web uri) #:use-module (srfi srfi-1) #:use-module (srfi srfi-26) diff --git a/guix/import/hackage.scm b/guix/import/hackage.scm index bbaee73a06..79a51d3300 100644 --- a/guix/import/hackage.scm +++ b/guix/import/hackage.scm @@ -8,7 +8,7 @@ ;;; Copyright © 2021 Sarah Morgensen ;;; Copyright © 2019 Simon Tournier ;;; Copyright © 2022 Hartmut Goebel -;;; Copyright © 2023 Ludovic Courtès +;;; Copyright © 2023-2024 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -47,7 +47,7 @@ (define-module (guix import hackage) #:use-module (guix upstream) #:use-module (guix packages) #:autoload (guix build-system haskell) (hackage-uri) - #:use-module ((guix utils) #:select (call-with-temporary-output-file)) + #:autoload (guix build utils) (call-with-temporary-output-file) #:export (%hackage-url hackage->guix-package hackage-recursive-import diff --git a/guix/import/hexpm.scm b/guix/import/hexpm.scm index 628a44ff24..71a54ba973 100644 --- a/guix/import/hexpm.scm +++ b/guix/import/hexpm.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2015 Cyril Roelandt ;;; Copyright © 2016 David Craven -;;; Copyright © 2017, 2019-2021 Ludovic Courtès +;;; Copyright © 2017, 2019-2021, 2024 Ludovic Courtès ;;; Copyright © 2019 Martin Becze ;;; Copyright © 2019 Maxim Cournoyer ;;; Copyright © 2020-2022 Hartmut Goebel @@ -28,10 +28,11 @@ (define-module (guix import hexpm) #:use-module ((guix build utils) #:select ((package-name->name+version . hyphen-package-name->name+version) - dump-port)) + dump-port + call-with-temporary-output-file)) #:use-module (guix packages) #:use-module (guix upstream) - #:use-module (guix utils) + #:autoload (guix utils) (version>? file-sans-extension) #:use-module (ice-9 match) #:use-module (srfi srfi-1) #:use-module (srfi srfi-26) diff --git a/guix/import/opam.scm b/guix/import/opam.scm index 86e82cde59..a7f8092507 100644 --- a/guix/import/opam.scm +++ b/guix/import/opam.scm @@ -31,7 +31,9 @@ (define-module (guix import opam) #:use-module ((srfi srfi-26) #:select (cut)) #:use-module (srfi srfi-34) #:use-module ((web uri) #:select (string->uri uri->string)) - #:use-module ((guix build utils) #:select (dump-port find-files mkdir-p)) + #:use-module ((guix build utils) + #:select (dump-port find-files mkdir-p + call-with-temporary-output-file)) #:use-module (guix build-system) #:use-module (guix i18n) #:use-module (guix diagnostics) @@ -39,8 +41,7 @@ (define-module (guix import opam) #:use-module (guix packages) #:use-module (guix upstream) #:use-module ((guix utils) #:select (cache-directory - version>? - call-with-temporary-output-file)) + version>?)) #:use-module ((guix import utils) #:select (beautify-description guix-hash-url recursive-import diff --git a/guix/import/pypi.scm b/guix/import/pypi.scm index 1a3070fb36..6719fde330 100644 --- a/guix/import/pypi.scm +++ b/guix/import/pypi.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2014 David Thompson ;;; Copyright © 2015 Cyril Roelandt -;;; Copyright © 2015-2017, 2019-2023 Ludovic Courtès +;;; Copyright © 2015-2017, 2019-2024 Ludovic Courtès ;;; Copyright © 2017 Mathieu Othacehe ;;; Copyright © 2018, 2023 Ricardo Wurmus ;;; Copyright © 2019 Maxim Cournoyer @@ -52,7 +52,8 @@ (define-module (guix import pypi) #:select ((package-name->name+version . hyphen-package-name->name+version) find-files - invoke)) + invoke + call-with-temporary-output-file)) #:use-module (guix import utils) #:use-module (guix import json) #:use-module (json) diff --git a/guix/utils.scm b/guix/utils.scm index 29ad09d9f7..d8ce6ed886 100644 --- a/guix/utils.scm +++ b/guix/utils.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2022 Ludovic Courtès +;;; Copyright © 2012-2022, 2024 Ludovic Courtès ;;; Copyright © 2013, 2014, 2015 Mark H Weaver ;;; Copyright © 2014 Eric Bavier ;;; Copyright © 2014 Ian Denhardt @@ -47,11 +47,12 @@ (define-module (guix utils) #:use-module (rnrs io ports) ;need 'port-position' etc. #:use-module ((rnrs bytevectors) #:select (bytevector-u8-set!)) #:use-module (guix memoization) - #:use-module ((guix build utils) - #:select (dump-port mkdir-p delete-file-recursively - call-with-temporary-output-file %xz-parallel-args)) - #:use-module ((guix build syscalls) #:select (mkdtemp! fdatasync)) - #:use-module ((guix combinators) #:select (fold2)) + #:autoload (guix build utils) (dump-port + mkdir-p + delete-file-recursively + %xz-parallel-args) + #:autoload (guix build syscalls) (mkdtemp! fdatasync) + #:autoload (guix combinators) (fold2) #:use-module (guix diagnostics) ;, &error-location, etc. #:use-module (ice-9 format) #:use-module ((ice-9 iconv) #:prefix iconv:) @@ -76,9 +77,7 @@ (define-module (guix utils) &fix-hint fix-hint? - condition-fix-hint - - call-with-temporary-output-file) + condition-fix-hint) #:export (strip-keyword-arguments default-keyword-arguments substitute-keyword-arguments diff --git a/tests/cpio.scm b/tests/cpio.scm index 832101d1bb..35a704822b 100644 --- a/tests/cpio.scm +++ b/tests/cpio.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2015, 2022 Ludovic Courtès +;;; Copyright © 2015, 2022, 2024 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -19,8 +19,8 @@ (define-module (test-cpio) #:use-module (guix cpio) #:use-module (guix tests) - #:use-module ((guix build utils) #:select (which)) - #:use-module ((guix utils) #:select (call-with-temporary-output-file)) + #:use-module ((guix build utils) + #:select (which call-with-temporary-output-file)) #:use-module (ice-9 match) #:use-module (ice-9 popen) #:use-module (rnrs io ports) diff --git a/tests/egg.scm b/tests/egg.scm index a7d3378dd7..c74f954683 100644 --- a/tests/egg.scm +++ b/tests/egg.scm @@ -24,8 +24,9 @@ (define-module (test-eggs) #:use-module (gcrypt hash) #:use-module (guix tests) #:use-module ((guix build syscalls) #:select (mkdtemp!)) - #:use-module ((guix build utils) #:select (delete-file-recursively mkdir-p which)) - #:use-module ((guix utils) #:select (call-with-temporary-output-file)) + #:use-module ((guix build utils) + #:select (delete-file-recursively mkdir-p which + call-with-temporary-output-file)) #:use-module (srfi srfi-1) #:use-module (srfi srfi-64) #:use-module (web uri) diff --git a/tests/opam.scm b/tests/opam.scm index 832fea1d9b..f444ef302e 100644 --- a/tests/opam.scm +++ b/tests/opam.scm @@ -24,8 +24,9 @@ (define-module (test-opam) #:use-module (gcrypt hash) #:use-module (guix tests) #:use-module ((guix build syscalls) #:select (mkdtemp!)) - #:use-module ((guix build utils) #:select (delete-file-recursively mkdir-p which)) - #:use-module ((guix utils) #:select (call-with-temporary-output-file)) + #:use-module ((guix build utils) + #:select (delete-file-recursively mkdir-p which + call-with-temporary-output-file)) #:use-module (srfi srfi-1) #:use-module (srfi srfi-64) #:use-module (web uri) diff --git a/tests/publish.scm b/tests/publish.scm index efb5698bed..d5ec3c954f 100644 --- a/tests/publish.scm +++ b/tests/publish.scm @@ -1,7 +1,7 @@ ;;; GNU Guix --- Functional package management for GNU ;;; Copyright © 2015 David Thompson ;;; Copyright © 2020 by Amar M. Singh -;;; Copyright © 2016-2022 Ludovic Courtès +;;; Copyright © 2016-2022, 2024 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -25,7 +25,8 @@ (define-module (test-publish) #:use-module (guix scripts publish) #:use-module (guix tests) #:use-module (guix config) - #:use-module (guix utils) + #:use-module ((guix utils) #:select (call-with-temporary-directory)) + #:use-module ((guix build utils) #:select (call-with-temporary-output-file)) #:use-module (gcrypt hash) #:use-module (guix store) #:use-module (guix derivations) diff --git a/tests/store-database.scm b/tests/store-database.scm index d8f3ce8070..0f44d33191 100644 --- a/tests/store-database.scm +++ b/tests/store-database.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2017, 2018, 2020, 2021 Ludovic Courtès +;;; Copyright © 2017-2018, 2020-2021, 2024 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -21,9 +21,9 @@ (define-module (test-store-database) #:use-module (guix store) #:use-module (guix store database) #:use-module (guix build store-copy) - #:use-module ((guix utils) #:select (call-with-temporary-output-file)) #:use-module ((guix build utils) - #:select (mkdir-p delete-file-recursively)) + #:select (mkdir-p delete-file-recursively + call-with-temporary-output-file)) #:use-module (srfi srfi-26) #:use-module (srfi srfi-64)) diff --git a/tests/utils.scm b/tests/utils.scm index 52f3b58ede..462e43e2b1 100644 --- a/tests/utils.scm +++ b/tests/utils.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019, 2020, 2021 Ludovic Courtès +;;; Copyright © 2012-2021, 2024 Ludovic Courtès ;;; Copyright © 2014 Eric Bavier ;;; Copyright © 2016 Mathieu Lirzin ;;; Copyright © 2021 Simon Tournier @@ -25,6 +25,7 @@ (define-module (test-utils) #:use-module ((guix config) #:select (%gzip)) #:use-module (guix utils) + #:use-module ((guix build utils) #:select (call-with-temporary-output-file)) #:use-module ((guix store) #:select (%store-prefix store-path-package-name)) #:use-module ((guix search-paths) #:select (string-tokenize*)) #:use-module (srfi srfi-1) From patchwork Mon Apr 1 20:25:20 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62449 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 080BD27BBE9; Mon, 1 Apr 2024 21:27:41 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id D2F6927BBE2 for ; Mon, 1 Apr 2024 21:27:38 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOFI-0008US-00; Mon, 01 Apr 2024 16:27:08 -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 1rrOFC-0008T9-4O for guix-patches@gnu.org; Mon, 01 Apr 2024 16:27:02 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOFB-0006wf-5T; Mon, 01 Apr 2024 16:27:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOFC-0007L9-Az; Mon, 01 Apr 2024 16:27:02 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 08/11] guix: Delay loading of (gnutls). Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:27:02 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200316928126 (code B ref 70132); Mon, 01 Apr 2024 20:27:02 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:26:09 +0000 Received: from localhost ([127.0.0.1]:51723 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEL-0007JU-8P for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:09 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59822) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEJ-0007Ga-25 for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:07 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrOE7-0006nb-Bx; Mon, 01 Apr 2024 16:25:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=E2p+uRh0UO5UxxsqjiH5aDgm7MioOP7Q/Bh3etynzFk=; b=KVNi3TDwQsKV87tnjH5d Z6vCRfOksluRfHkZLF505kMVkYt0j5xyvTrBwvY7iQlvDnwBqtJOOBUc49GfyX3kpVyE8MWxCTuEv hT2vH3bCnU79uCGbYTgtdW55gRFBt2lbJxCzyPNzRzxWq9g6f6nOzTBSs787odiR31i0sTsKT/b85 Kc/42kbB6jXmN2EH9179aILRdq75lFQUBOPjyKM0Me40pyb+fZ8zZ8LpdjrHUfGve7GDo6z611uS1 Q00CmUV02Z3KSdlFwfGZP/n0+C3Gk8ucr3BsvEjEacNxr/eWHXVpCq4dabfrnn3gyUkyi2APmltD6 Fk02wEL7eeSURw==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:20 +0200 Message-ID: <2c9f4d6f2b10b0975be8952a1ae0bc0fc0bbe0d6.1712002698.git.ludo@gnu.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches (web …) modules pull in (gnutls) indirectly. Arrange to load them lazily, thereby reducing I/O and allocations when GnuTLS is not needed such as when running ‘guix describe’ or ‘guix shell’ on a cache hit. * guix/download.scm: Autoload (web uri). * guix/scripts/describe.scm: Likewise. * guix/store.scm: Likewise. (%default-substitute-urls): Remove ‘resolve-interface’ call and use https URLs unconditionally. Change-Id: Ide470c556a14866e8740966d25821df487a79859 --- guix/download.scm | 2 +- guix/scripts/describe.scm | 4 ++-- guix/store.scm | 13 ++++++++----- 3 files changed, 11 insertions(+), 8 deletions(-) diff --git a/guix/download.scm b/guix/download.scm index 192c47f113..b251e1f6c0 100644 --- a/guix/download.scm +++ b/guix/download.scm @@ -32,7 +32,7 @@ (define-module (guix download) #:use-module (guix monads) #:use-module (guix gexp) #:autoload (guix build utils) (call-with-temporary-output-file) - #:use-module (web uri) + #:autoload (web uri) (string->uri uri-scheme uri-path) #:use-module (srfi srfi-1) #:use-module (srfi srfi-26) #:export (%download-methods diff --git a/guix/scripts/describe.scm b/guix/scripts/describe.scm index 449ab4b252..70ae84e9f6 100644 --- a/guix/scripts/describe.scm +++ b/guix/scripts/describe.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2018, 2019, 2020, 2021, 2023 Ludovic Courtès +;;; Copyright © 2018, 2019, 2020, 2021, 2023, 2024 Ludovic Courtès ;;; Copyright © 2018 Oleg Pykhalov ;;; Copyright © 2020 Ekaitz Zarraga ;;; Copyright © 2021 Simon Tournier @@ -37,7 +37,7 @@ (define-module (guix scripts describe) #:use-module (ice-9 match) #:use-module (ice-9 format) #:autoload (ice-9 pretty-print) (pretty-print) - #:use-module (web uri) + #:autoload (web uri) (string->uri uri-host) #:export (display-profile-content channel-commit-hyperlink diff --git a/guix/store.scm b/guix/store.scm index 97c4f32a5b..e808b43ba9 100644 --- a/guix/store.scm +++ b/guix/store.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2023 Ludovic Courtès +;;; Copyright © 2012-2024 Ludovic Courtès ;;; Copyright © 2018 Jan Nieuwenhuizen ;;; Copyright © 2019, 2020 Mathieu Othacehe ;;; Copyright © 2020 Florian Pelz @@ -49,7 +49,12 @@ (define-module (guix store) #:use-module (ice-9 popen) #:autoload (ice-9 threads) (current-processor-count) #:use-module (ice-9 format) - #:use-module (web uri) + #:autoload (web uri) (uri? + string->uri + uri-scheme + uri-host + uri-port + uri-path) #:export (%daemon-socket-uri %gc-roots-directory %default-substitute-urls @@ -764,9 +769,7 @@ (define %default-substitute-urls ;; Default list of substituters. This is *not* the list baked in ;; 'guix-daemon', but it is used by 'guix-service-type' and and a couple of ;; clients ('guix build --log-file' uses it.) - (map (if (false-if-exception (resolve-interface '(gnutls))) - (cut string-append "https://" <>) - (cut string-append "http://" <>)) + (map (cut string-append "https://" <>) '("ci.guix.gnu.org" "bordeaux.guix.gnu.org"))) From patchwork Mon Apr 1 20:25:21 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62450 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id A86D827BBEA; Mon, 1 Apr 2024 21:27:41 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 24BD227BBE2 for ; Mon, 1 Apr 2024 21:27:41 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOFF-0008UJ-Md; Mon, 01 Apr 2024 16:27:05 -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 1rrOFE-0008TV-1Q for guix-patches@gnu.org; Mon, 01 Apr 2024 16:27:04 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOFB-0006wm-W6; Mon, 01 Apr 2024 16:27:03 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOFD-0007LO-9i; Mon, 01 Apr 2024 16:27:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 09/11] ui: Delay use of (guix build syscalls). Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:27:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200317128141 (code B ref 70132); Mon, 01 Apr 2024 20:27:03 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:26:11 +0000 Received: from localhost ([127.0.0.1]:51727 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEM-0007Jj-Q4 for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59832) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEJ-0007Gi-AE for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:08 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrOEA-0006nd-A3; Mon, 01 Apr 2024 16:25:58 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=ywQloDwUQn6ZdDOQbc27ynvE4p+/omn3dMl9Qc9kC7U=; b=WbcFhYRptyMj7h3u264k fiiIEJ8HD2VQ+IJgDjgk3dXeQuQXZf60+53XYk+xo8aEDCnU8WM/tB4XHW0l004gKKUmGCipPsj2s lsE0ZpK2mNeBJHFf9wCBRt6w6muqNE2s8oEIg0YHqA1UDNU8IeUD/z+su60EdzgmAMYl5tKlKXvNZ vNoTxNDvqfO4EB1ahshXOBLDBbAjp87xz2Ytjfb5Ebvk76mXL+ExFR6IVmZI3WVWbzKYomhoYaNHZ HUKZUPRm7UF/SYQTOejaTvZB2fWSKdiK5sReyTtzUHTNGgbnDny+idcHvnJMH/SYGrkj48nPwV2Ma rEAUvW8NNdfflA==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:21 +0200 Message-ID: <52b532346c5eb27375681127542bf3c8152723db.1712002698.git.ludo@gnu.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches This ensures (guix build syscalls) is loaded only when needed. * guix/ui.scm (%text-width): Unconditionally alias ‘*line-width*’. Remove initialization. : Remove code for Guile < 2.2.7. (package->recutils): Change default #:width to (terminal-columns). Change-Id: I990a1b5b0f20a6243e47e314d1d3d4f8298b7151 --- guix/ui.scm | 22 ++++------------------ 1 file changed, 4 insertions(+), 18 deletions(-) diff --git a/guix/ui.scm b/guix/ui.scm index 34ff210930..d82fa533cc 100644 --- a/guix/ui.scm +++ b/guix/ui.scm @@ -1473,23 +1473,9 @@ (define* (fill-paragraph str width #:optional (column 0)) ;;; (define %text-width - ;; '*line-width*' was introduced in Guile 2.2.7/3.0.1. On older versions of - ;; Guile, monkey-patch 'wrap*' below. - (if (defined? '*line-width*) - (let ((parameter (fluid->parameter *line-width*))) - (parameter (terminal-columns)) - parameter) - (make-parameter (terminal-columns)))) - -(unless (defined? '*line-width*) ;Guile < 2.2.7 - (set! (@@ (texinfo plain-text) wrap*) - ;; XXX: Monkey patch this private procedure to let 'package->recutils' - ;; parameterize the fill of description field correctly. - (lambda strings - (let ((indent (fluid-ref (@@ (texinfo plain-text) *indent*)))) - (fill-string (string-concatenate strings) - #:line-width (%text-width) #:initial-indent indent - #:subsequent-indent indent))))) + ;; '*line-width*' was introduced in Guile 2.2.7/3.0.1. Keep this alias for + ;; backward-compatibility and for convenience. + (fluid->parameter *line-width*)) (define (texi->plain-text str) "Return a plain-text representation of texinfo fragment STR." @@ -1535,7 +1521,7 @@ (define (string->recutils str) '() str))) -(define* (package->recutils p port #:optional (width (%text-width)) +(define* (package->recutils p port #:optional (width (terminal-columns)) #:key (hyperlinks? (supports-hyperlinks? port)) (extra-fields '()) From patchwork Mon Apr 1 20:25:22 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62446 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id 5285027BBE9; Mon, 1 Apr 2024 21:27:23 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 1D60B27BBE2 for ; Mon, 1 Apr 2024 21:27:22 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOFE-0008TO-88; Mon, 01 Apr 2024 16:27:04 -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 1rrOFA-0008Sw-SC for guix-patches@gnu.org; Mon, 01 Apr 2024 16:27:00 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOFA-0006wW-Iv; Mon, 01 Apr 2024 16:27:00 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOFD-0007LZ-PX; Mon, 01 Apr 2024 16:27:03 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 10/11] Autoload (guix build syscalls). Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:27:03 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200317128148 (code B ref 70132); Mon, 01 Apr 2024 20:27:03 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:26:11 +0000 Received: from localhost ([127.0.0.1]:51729 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEN-0007Jq-7A for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:11 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:59840) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEJ-0007H2-VL for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:08 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrOEB-0006o2-9X; Mon, 01 Apr 2024 16:25:59 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=o94aS/FA5a9/YF5WmvJxRL8+t28z9ykoZ974wS8h6oY=; b=Min0uhJX7sy86jzMD/Ag PswB8iLsrsmtzKlIFgCwnfahWiwudkYFjMS0lTLFyYDvtQzFH8IFHxuCRv9M3uJvbTC+vhOFcEuFl +H7TJccFLJJuYpOlaOoci1lQnxrt9m82b22Mhe/NQEOLIvOfH57sSrJR2Jkt8E8gcdW4WbiM7hACN GsvbcuccCcjkFmqxSNXuk3HUG7/Z/iCI2RkjeRqG3bqqPdYGCPOHVHNqB4AYrcNUlCSddNyWn39KZ kiFLGanR437A0XClL+Djpq+EN6zpzgFsGuvL09x4Wf82oFDIlUuFe8qGDii2I8mks0UU2xwO4lKHQ I7la7B4OgqsU0w==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:22 +0200 Message-ID: <8d433a8fb3e0b79dd42f526005acadd54335c019.1712002698.git.ludo@gnu.org> X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * guix/discovery.scm, guix/git.scm, guix/nar.scm, guix/scripts.scm, guix/scripts/build.scm: Autoload (guix build syscalls). * guix/packages.scm: Autoload (guix build utils). Change-Id: Ia7703b5f46e55fbfadff63b13c35bfe097ce2220 --- guix/discovery.scm | 4 ++-- guix/git.scm | 3 +-- guix/nar.scm | 4 ++-- guix/packages.scm | 5 ++--- guix/scripts.scm | 7 +++++-- guix/scripts/build.scm | 4 ++-- 6 files changed, 14 insertions(+), 13 deletions(-) diff --git a/guix/discovery.scm b/guix/discovery.scm index 0edc7fd1ae..2febfcdcb7 100644 --- a/guix/discovery.scm +++ b/guix/discovery.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2017, 2018, 2019 Ludovic Courtès +;;; Copyright © 2012-2019, 2024 Ludovic Courtès ;;; ;;; This file is part of GNU Guix. ;;; @@ -20,7 +20,7 @@ (define-module (guix discovery) #:use-module (guix i18n) #:use-module (guix modules) #:use-module (guix combinators) - #:use-module (guix build syscalls) + #:autoload (guix build syscalls) (scandir*) #:use-module (srfi srfi-1) #:use-module (ice-9 match) #:use-module (ice-9 vlist) diff --git a/guix/git.scm b/guix/git.scm index 8e1d863976..b22c8ac02a 100644 --- a/guix/git.scm +++ b/guix/git.scm @@ -33,8 +33,7 @@ (define-module (guix git) #:use-module (guix store) #:use-module (guix utils) #:use-module (guix records) - #:use-module ((guix build syscalls) - #:select (terminal-string-width)) + #:autoload (guix build syscalls) (terminal-string-width) #:use-module (guix gexp) #:autoload (guix git-download) (git-reference-url git-reference-commit git-reference-recursive?) diff --git a/guix/nar.scm b/guix/nar.scm index a817b56007..a50c191f9d 100644 --- a/guix/nar.scm +++ b/guix/nar.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012, 2013, 2014, 2015, 2016, 2018, 2019, 2020 Ludovic Courtès +;;; Copyright © 2012-2016, 2018-2020, 2024 Ludovic Courtès ;;; Copyright © 2014 Mark H Weaver ;;; ;;; This file is part of GNU Guix. @@ -19,7 +19,7 @@ (define-module (guix nar) #:use-module (guix serialization) - #:use-module (guix build syscalls) + #:autoload (guix build syscalls) (lock-file unlock-file) #:use-module ((guix build utils) #:select (delete-file-recursively with-directory-excursion)) diff --git a/guix/packages.scm b/guix/packages.scm index 930b1a3b0e..bd72b284b1 100644 --- a/guix/packages.scm +++ b/guix/packages.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2023 Ludovic Courtès +;;; Copyright © 2012-2024 Ludovic Courtès ;;; Copyright © 2014, 2015, 2017, 2018, 2019 Mark H Weaver ;;; Copyright © 2015 Eric Bavier ;;; Copyright © 2016 Alex Kost @@ -27,8 +27,7 @@ ;;; along with GNU Guix. If not, see . (define-module (guix packages) - #:use-module ((guix build utils) #:select (compressor tarball? - strip-store-file-name)) + #:autoload (guix build utils) (compressor tarball? strip-store-file-name) #:use-module (guix utils) #:use-module (guix records) #:use-module (guix store) diff --git a/guix/scripts.scm b/guix/scripts.scm index 5d11ce7fe9..c4849816ea 100644 --- a/guix/scripts.scm +++ b/guix/scripts.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2013, 2014, 2015, 2017, 2018, 2019, 2020, 2021, 2021 Ludovic Courtès +;;; Copyright © 2013-2015, 2017-2021, 2021, 2024 Ludovic Courtès ;;; Copyright © 2014 Deck Pickard ;;; Copyright © 2015, 2016 Alex Kost ;;; Copyright © 2020 Jan (janneke) Nieuwenhuizen @@ -29,7 +29,10 @@ (define-module (guix scripts) #:use-module (guix packages) #:use-module (guix derivations) #:autoload (guix describe) (current-profile-date) - #:use-module (guix build syscalls) + #:autoload (guix build syscalls) (statfs + file-system-block-size + file-system-blocks-available + file-system-block-count) #:use-module (srfi srfi-1) #:use-module (srfi srfi-19) #:use-module (srfi srfi-37) diff --git a/guix/scripts/build.scm b/guix/scripts/build.scm index 05f022a92e..da4859eeaa 100644 --- a/guix/scripts/build.scm +++ b/guix/scripts/build.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2023 Ludovic Courtès +;;; Copyright © 2012-2024 Ludovic Courtès ;;; Copyright © 2013 Mark H Weaver ;;; Copyright © 2020 Marius Bakke ;;; Copyright © 2020 Ricardo Wurmus @@ -45,7 +45,7 @@ (define-module (guix scripts build) #:use-module (guix platform) #:use-module ((guix status) #:select (with-status-verbosity)) #:use-module ((guix progress) #:select (current-terminal-columns)) - #:use-module ((guix build syscalls) #:select (terminal-columns)) + #:autoload (guix build syscalls) (terminal-columns) #:use-module (guix transformations) #:export (log-url From patchwork Mon Apr 1 20:25:23 2024 Content-Type: text/plain; charset="utf-8" MIME-Version: 1.0 Content-Transfer-Encoding: 8bit X-Patchwork-Submitter: =?utf-8?q?Ludovic_Court=C3=A8s?= X-Patchwork-Id: 62447 Return-Path: X-Original-To: patchwork@mira.cbaines.net Delivered-To: patchwork@mira.cbaines.net Received: by mira.cbaines.net (Postfix, from userid 113) id C3F6227BBEA; Mon, 1 Apr 2024 21:27:26 +0100 (BST) X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on mira.cbaines.net X-Spam-Level: X-Spam-Status: No, score=-2.7 required=5.0 tests=BAYES_00,DKIM_INVALID, DKIM_SIGNED,MAILING_LIST_MULTI,SPF_HELO_PASS,URIBL_BLOCKED autolearn=unavailable autolearn_force=no version=3.4.6 Received: from lists.gnu.org (lists.gnu.org [209.51.188.17]) by mira.cbaines.net (Postfix) with ESMTPS id 29F9C27BBE2 for ; Mon, 1 Apr 2024 21:27:26 +0100 (BST) Received: from localhost ([::1] helo=lists1p.gnu.org) by lists.gnu.org with esmtp (Exim 4.90_1) (envelope-from ) id 1rrOFH-0008UN-W8; Mon, 01 Apr 2024 16:27:08 -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 1rrOFC-0008TA-5D for guix-patches@gnu.org; Mon, 01 Apr 2024 16:27:02 -0400 Received: from debbugs.gnu.org ([2001:470:142:5::43]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_128_GCM_SHA256:128) (Exim 4.90_1) (envelope-from ) id 1rrOFB-0006wg-Sa; Mon, 01 Apr 2024 16:27:01 -0400 Received: from Debian-debbugs by debbugs.gnu.org with local (Exim 4.84_2) (envelope-from ) id 1rrOFE-0007Ll-8E; Mon, 01 Apr 2024 16:27:04 -0400 X-Loop: help-debbugs@gnu.org Subject: [bug#70132] [PATCH 11/11] Autoload (gcrypt hash). Resent-From: Ludovic =?utf-8?q?Court=C3=A8s?= Original-Sender: "Debbugs-submit" Resent-CC: guix@cbaines.net, dev@jpoiret.xyz, ludo@gnu.org, othacehe@gnu.org, rekado@elephly.net, zimon.toutoune@gmail.com, me@tobias.gr, guix-patches@gnu.org Resent-Date: Mon, 01 Apr 2024 20:27:04 +0000 Resent-Message-ID: Resent-Sender: help-debbugs@gnu.org X-GNU-PR-Message: followup 70132 X-GNU-PR-Package: guix-patches X-GNU-PR-Keywords: patch To: 70132@debbugs.gnu.org Cc: Ludovic =?utf-8?q?Court=C3=A8s?= , Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice X-Debbugs-Original-Xcc: Christopher Baines , Josselin Poiret , Ludovic =?utf-8?q?Court=C3=A8s?= , Mathieu Othacehe , Ricardo Wurmus , Simon Tournier , Tobias Geerinckx-Rice Received: via spool by 70132-submit@debbugs.gnu.org id=B70132.171200317328156 (code B ref 70132); Mon, 01 Apr 2024 20:27:04 +0000 Received: (at 70132) by debbugs.gnu.org; 1 Apr 2024 20:26:13 +0000 Received: from localhost ([127.0.0.1]:51731 helo=debbugs.gnu.org) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEO-0007K4-VD for submit@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:13 -0400 Received: from eggs.gnu.org ([2001:470:142:3::10]:53894) by debbugs.gnu.org with esmtp (Exim 4.84_2) (envelope-from ) id 1rrOEK-0007HR-R2 for 70132@debbugs.gnu.org; Mon, 01 Apr 2024 16:26:09 -0400 Received: from fencepost.gnu.org ([2001:470:142:3::e]) by eggs.gnu.org with esmtps (TLS1.2:ECDHE_RSA_AES_256_GCM_SHA384:256) (Exim 4.90_1) (envelope-from ) id 1rrOEC-0006oG-3z; Mon, 01 Apr 2024 16:26:00 -0400 DKIM-Signature: v=1; a=rsa-sha256; q=dns/txt; c=relaxed/relaxed; d=gnu.org; s=fencepost-gnu-org; h=MIME-Version:References:In-Reply-To:Date:Subject:To: From; bh=etrpTgm0efUoP+Wi4xBPkoVxi6nTQkemO+1MHMCFjLU=; b=ImXhLACW1UPrS7eVGAzi ioQ4VXmjRa/BFucB98u+44SiI8WNJ3hvqoa6qwVT8+R+7a7QTCvaUnCQUbzXozOobv9D6RdXSHzCU erE/BUS7vGzABn4cwiyfI88nn37oyMR9Lo3UCm395yIQkjLbCgJC0oXOVlc4FJ7d+wA3YRpdHjd3b vR1vy7LE4Rtuu+xMmW5N/+4JRu7IynvWtzodjLL2a3kTEPwSg0UznghwhKElXpw6H+LxRGwEFgb1A NJOBYKhqS/2bO6bgnnOFrD9UOrxGVlVi3icwQlVghIxbCww/46UIRy7LntP6HsRnCBCcYTCp6i+5D BquPwB+Jq4p1lQ==; From: Ludovic =?utf-8?q?Court=C3=A8s?= Date: Mon, 1 Apr 2024 22:25:23 +0200 Message-ID: X-Mailer: git-send-email 2.41.0 In-Reply-To: References: MIME-Version: 1.0 X-BeenThere: debbugs-submit@debbugs.gnu.org X-Mailman-Version: 2.1.18 Precedence: list X-BeenThere: guix-patches@gnu.org List-Id: List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , Errors-To: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org Sender: guix-patches-bounces+patchwork=mira.cbaines.net@gnu.org X-getmail-retrieved-from-mailbox: Patches * guix/derivations.scm: Autoload (guix utils) and (gcrypt hash). * guix/git.scm, guix/store.scm: Autoload (gcrypt hash). Change-Id: I6145231d41c61f2d8c36e28f29e91074910bdd15 --- guix/derivations.scm | 6 +++--- guix/git.scm | 2 +- guix/store.scm | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) diff --git a/guix/derivations.scm b/guix/derivations.scm index 9fec7f4f0b..a91c1ae984 100644 --- a/guix/derivations.scm +++ b/guix/derivations.scm @@ -1,5 +1,5 @@ ;;; GNU Guix --- Functional package management for GNU -;;; Copyright © 2012-2021, 2023 Ludovic Courtès +;;; Copyright © 2012-2021, 2023-2024 Ludovic Courtès ;;; Copyright © 2016, 2017 Mathieu Lirzin ;;; ;;; This file is part of GNU Guix. @@ -32,7 +32,7 @@ (define-module (guix derivations) #:use-module (ice-9 rdelim) #:use-module (ice-9 vlist) #:use-module (guix store) - #:use-module (guix utils) + #:autoload (guix utils) (%current-system string-replace-substring) #:use-module (guix base16) #:use-module (guix memoization) #:use-module (guix combinators) @@ -40,7 +40,7 @@ (define-module (guix derivations) #:use-module (guix diagnostics) #:use-module (guix i18n) #:use-module (guix monads) - #:use-module (gcrypt hash) + #:autoload (gcrypt hash) (sha256) #:use-module (guix sets) #:export ( derivation? diff --git a/guix/git.scm b/guix/git.scm index b22c8ac02a..d75a301f98 100644 --- a/guix/git.scm +++ b/guix/git.scm @@ -27,7 +27,7 @@ (define-module (guix git) #:use-module (guix i18n) #:use-module (guix base32) #:use-module (guix cache) - #:use-module (gcrypt hash) + #:autoload (gcrypt hash) (sha256) #:use-module ((guix build utils) #:select (mkdir-p delete-file-recursively invoke/quiet)) #:use-module (guix store) diff --git a/guix/store.scm b/guix/store.scm index e808b43ba9..7ff6bf7eec 100644 --- a/guix/store.scm +++ b/guix/store.scm @@ -29,7 +29,7 @@ (define-module (guix store) #:use-module (guix records) #:use-module (guix base16) #:use-module (guix base32) - #:use-module (gcrypt hash) + #:autoload (gcrypt hash) (sha256) #:use-module (guix profiling) #:autoload (guix build syscalls) (terminal-columns) #:autoload (guix build utils) (dump-port)