guix_mirror_bot pushed a commit to branch master
in repository guix.
commit 830d58dac2694584e2b8782dd169c61f8e54d69a
Author: Maxim Cournoyer <[email protected]>
AuthorDate: Wed Jan 21 10:30:06 2026 +0900
import/utils: Add #:recursive? to `git-origin'.
* guix/import/utils.scm (git-origin) [#:recursive?]: New key.
Change-Id: Ibae80e873a593f9e904b1c974dbeca18fa115074
---
guix/import/utils.scm | 7 +++++--
1 file changed, 5 insertions(+), 2 deletions(-)
diff --git a/guix/import/utils.scm b/guix/import/utils.scm
index 6cd1750ba1..a35252b343 100644
--- a/guix/import/utils.scm
+++ b/guix/import/utils.scm
@@ -214,13 +214,16 @@ the commit hash, the downloaded directory and its content
hash."
(bytevector->nix-base32-string
(query-path-hash store checkout))))))
-(define (git-origin url commit hash)
+(define* (git-origin url commit hash #:key recursive?)
"Simple helper to generate a Git origin s-expression."
`(origin
(method git-fetch)
(uri (git-reference
(url ,(and (not (eq? url 'null)) url))
- (commit ,commit)))
+ (commit ,commit)
+ ,@(if recursive?
+ '(recursive? #t)
+ '())))
(file-name (git-file-name name version))
(sha256
(base32 ,hash))))