Skip to content
Snippets Groups Projects
Unverified Commit 024a6bfb authored by Ludovic Courtès's avatar Ludovic Courtès
Browse files

guix build: '--with-branch' & co. fetch submodules.

* guix/scripts/build.scm (transform-package-source-branch)[replace]: Add
'recursive?' field to the new package.
parent 06fff484
No related branches found
No related tags found
No related merge requests found
...@@ -7289,7 +7289,8 @@ care! ...@@ -7289,7 +7289,8 @@ care!
Build @var{package} from the latest commit of @var{branch}. The @code{source} Build @var{package} from the latest commit of @var{branch}. The @code{source}
field of @var{package} must be an origin with the @code{git-fetch} method field of @var{package} must be an origin with the @code{git-fetch} method
(@pxref{origin Reference}) or a @code{git-checkout} object; the repository URL (@pxref{origin Reference}) or a @code{git-checkout} object; the repository URL
is taken from that @code{source}. is taken from that @code{source}. Git sub-modules of the repository are
fetched, recursively.
   
For instance, the following command builds @code{guile-sqlite3} from the For instance, the following command builds @code{guile-sqlite3} from the
latest commit of its @code{master} branch, and then builds @code{guix} (which latest commit of its @code{master} branch, and then builds @code{guix} (which
......
...@@ -308,7 +308,8 @@ (define (replace old url branch) ...@@ -308,7 +308,8 @@ (define (replace old url branch)
(package (package
(inherit old) (inherit old)
(version (string-append "git." branch)) (version (string-append "git." branch))
(source (git-checkout (url url) (branch branch))))) (source (git-checkout (url url) (branch branch)
(recursive? #t)))))
(let* ((replacements (evaluate-git-replacement-specs replacement-specs (let* ((replacements (evaluate-git-replacement-specs replacement-specs
replace)) replace))
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment