summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLudovic Courtès <ludo@gnu.org>2020-10-10 00:03:57 +0200
committerLudovic Courtès <ludo@gnu.org>2020-10-10 22:37:45 +0200
commitb55409b2c0a0cb53f251ceab7746d35805b64ab7 (patch)
treec853b92b135aa97861e3736092fd172ce483f6ec
parent45cad97d9ee15a4b43e83d735185ff633a95cc09 (diff)
svn-download, hg-download: Use 'report-invoke-error'.
* guix/build/hg.scm (hg-fetch): Use 'report-invoke-error' instead of 'format'. * guix/build/svn.scm (svn-fetch): Likewise.
-rw-r--r--guix/build/hg.scm8
-rw-r--r--guix/build/svn.scm10
2 files changed, 3 insertions, 15 deletions
diff --git a/guix/build/hg.scm b/guix/build/hg.scm
index 1cceb63433..0ffad7fa2d 100644
--- a/guix/build/hg.scm
+++ b/guix/build/hg.scm
@@ -41,13 +41,7 @@ Mercurial changeset identifier. Return #t on success, #f otherwise."
(mkdir-p directory)
(guard (c ((invoke-error? c)
- (format (current-error-port)
- "hg-fetch: '~a~{ ~a~}' failed with exit code ~a~%"
- (invoke-error-program c)
- (invoke-error-arguments c)
- (or (invoke-error-exit-status c)
- (invoke-error-stop-signal c)
- (invoke-error-term-signal c)))
+ (report-invoke-error c)
(delete-file-recursively directory)
#f))
(with-directory-excursion directory
diff --git a/guix/build/svn.scm b/guix/build/svn.scm
index f6b4ca0776..44d77a968f 100644
--- a/guix/build/svn.scm
+++ b/guix/build/svn.scm
@@ -1,5 +1,5 @@
;;; GNU Guix --- Functional package management for GNU
-;;; Copyright © 2014 Ludovic Courtès <ludo@gnu.org>
+;;; Copyright © 2014, 2020 Ludovic Courtès <ludo@gnu.org>
;;; Copyright © 2014 Sree Harsha Totakura <sreeharsha@totakura.in>
;;; Copyright © 2018 Mark H Weaver <mhw@netris.org>
;;; Copyright © 2020 Simon Tournier <zimon.toutoune@gmail.com>
@@ -40,13 +40,7 @@
"Fetch REVISION from URL into DIRECTORY. REVISION must be an integer, and a
valid Subversion revision. Return #t on success, #f otherwise."
(guard (c ((invoke-error? c)
- (format (current-error-port)
- "svn-fetch: '~a~{ ~a~}' failed with exit code ~a~%"
- (invoke-error-program c)
- (invoke-error-arguments c)
- (or (invoke-error-exit-status c)
- (invoke-error-stop-signal c)
- (invoke-error-term-signal c)))
+ (report-invoke-error c)
#f))
(apply invoke svn-command
"export" "--non-interactive"