guix_mirror_bot pushed a commit to branch next-master
in repository guix.
commit 8998751799a9ed7ad7276fcdf1a1c3b27cd79827
Author: Ludovic Courtès <[email protected]>
AuthorDate: Mon Dec 22 16:23:42 2025 +0100
git-authenticate, inferior: Autoload Git modules.
The primary motivation is that, since (guix git-authenticate) is part of
the (guix describe) closure and might thus end up on the build side,
autoloading allows us to not add a ‘with-extensions’ stanza for Guile-Git to
every gexp that pulls in (guix describe).
This situation happens with (guix platform) in the following commit.
* guix/git-authenticate.scm: Explicitly autoload (git …) modules and (guix
git).
* guix/inferior.scm: Autoload (guix git).
Change-Id: Ie26f302cd88603d2d787048213864013bfff572f
Signed-off-by: Ludovic Courtès <[email protected]>
---
guix/git-authenticate.scm | 25 ++++++++++++++++++++-----
guix/inferior.scm | 2 +-
2 files changed, 21 insertions(+), 6 deletions(-)
diff --git a/guix/git-authenticate.scm b/guix/git-authenticate.scm
index ccd3e65740..c20c2aae27 100644
--- a/guix/git-authenticate.scm
+++ b/guix/git-authenticate.scm
@@ -17,14 +17,29 @@
;;; along with GNU Guix. If not, see <http://www.gnu.org/licenses/>.
(define-module (guix git-authenticate)
- #:use-module (git)
+ #:autoload (git oid) (oid->string
+ string->oid)
+ #:autoload (git blob) (blob-lookup blob-content)
+ #:autoload (git branch) (branch-lookup BRANCH-ALL)
+ #:autoload (git commit) (commit-lookup
+ commit-parents
+ commit-id
+ commit-tree
+ commit-extract-signature)
+ #:autoload (git errors) (GIT_ENOTFOUND)
+ #:autoload (git reference) (reference-target)
+ #:autoload (git repository) (repository-directory repository-head)
+ #:autoload (git structs) (git-error-code)
+ #:autoload (git tree) (tree-entry-bypath
+ tree-list
+ tree-entry-id
+ tree-entry-name)
#:autoload (gcrypt hash) (sha256)
#:use-module (guix base16)
#:autoload (guix base64) (base64-encode)
- #:use-module ((guix git)
- #:select (commit-difference
- commit-descendant?
- false-if-git-not-found))
+ #:autoload (guix git) (commit-difference
+ commit-descendant?
+ false-if-git-not-found)
#:use-module (guix i18n)
#:use-module ((guix diagnostics) #:select (formatted-message))
#:use-module (guix openpgp)
diff --git a/guix/inferior.scm b/guix/inferior.scm
index ddea46ba2f..76c2a767c6 100644
--- a/guix/inferior.scm
+++ b/guix/inferior.scm
@@ -40,7 +40,7 @@
#:use-module (guix search-paths)
#:use-module (guix profiles)
#:use-module (guix channels)
- #:use-module ((guix git) #:select (update-cached-checkout commit-id?))
+ #:autoload (guix git) (update-cached-checkout commit-id?)
#:use-module (guix monads)
#:use-module (guix store)
#:use-module (guix derivations)