Subject: [bug#30833] [PATCH] git-download: Fix recursive checkouts.

From: Eric Bavier <[email-masked]>
Date: Thu, 15 Mar 2018 23:28:07 -0500

Hello Guix,

The attached patch fixes a regression in recursive git checkouts of
package source, which I believe was introduced in
6dff905e51202bbdebbad8811b6509584d12a796 (2017-09-05!)

This would have only affected 6 packages:

scheme@(guile-user)> (format #t "~{~a~%~}"
  (fold-packages
   (lambda (p r) 
     (if (and=> (package-source p)
                (lambda (s) 
                  (and (git-reference? (origin-uri s))
                       (git-reference-recursive? (origin-uri s))))) 
       (cons p r)
       r))
   '())
#<package [email-masked] gnu/packages/compression.scm:912 2928000>
#<package [email-masked] gnu/packages/robotics.scm:79 3199e40>
#<package [email-masked] gnu/packages/terminals.scm:446 2e28b40>
#<package termite@13 gnu/packages/terminals.scm:102 2e25240>
#<package [email-masked] gnu/packages/wget.scm:126 2728900>
#<package [email-masked] gnu/packages/zile.scm:83 3c660c0>
$8 = #t

`~Eric
From 7798ecb3e61b042e4af3c0501f32d6b8888c1a13 Mon Sep 17 00:00:00 2001
From: Eric Bavier <[email-masked]>
Date: Thu, 15 Mar 2018 23:25:01 -0500
Subject: [PATCH] git-download: Fix recursive checkouts.

* guix/git-download.scm (git-fetch)<build>: Fix match on INPUTS, which may
contain package outputs.
---
 guix/git-download.scm | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/guix/git-download.scm b/guix/git-download.scm
index 731e549b3..33f102bc6 100644
--- a/guix/git-download.scm
+++ b/guix/git-download.scm
@@ -109,7 +109,7 @@ HASH-ALGO (a symbol).  Use NAME as the file name, or a generic name if #f."
           ;; grep, etc. to be in $PATH.
           (set-path-environment-variable "PATH" '("bin")
                                          (match '#+inputs
-                                           (((names dirs) ...)
+                                           (((names dirs outputs ...) ...)
                                             dirs)))
 
           (or (git-fetch (getenv "git url") (getenv "git commit")
-- 
2.16.2