summaryrefslogtreecommitdiff
path: root/guix/build/git.scm
diff options
context:
space:
mode:
authorMaxim Cournoyer <maxim.cournoyer@gmail.com>2018-10-24 08:49:50 -0400
committerMaxim Cournoyer <maxim.cournoyer@gmail.com>2018-10-28 22:17:17 -0400
commit2f18b7329d9260cbada8cdec081765adfa82a5f4 (patch)
treecd28f4f1da5432a693f3b878bd9ef2708e23ea97 /guix/build/git.scm
parent63eb2b899be7ac857454442e09d0ebd23fe4f871 (diff)
git-download: Print a message when falling back to a full fetch.
Otherwise the user might believe that git-fetch stalled, observing the lack of output following a 'fatal' git error message (see: https://debbugs.gnu.org/33100). * guix/build/git.scm (git-fetch): Print message when falling back to a full fetch.
Diffstat (limited to 'guix/build/git.scm')
-rw-r--r--guix/build/git.scm2
1 files changed, 2 insertions, 0 deletions
diff --git a/guix/build/git.scm b/guix/build/git.scm
index 14d415a6f8..2d1700a9b9 100644
--- a/guix/build/git.scm
+++ b/guix/build/git.scm
@@ -45,6 +45,8 @@ recursively. Return #t on success, #f otherwise."
(if (zero? (system* git-command "fetch" "--depth" "1" "origin" commit))
(invoke git-command "checkout" "FETCH_HEAD")
(begin
+ (setvbuf (current-output-port) 'line)
+ (format #t "Failed to do a shallow fetch; retrying a full fetch...~%")
(invoke git-command "fetch" "origin")
(invoke git-command "checkout" commit)))
(when recursive?