summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorBrice Waegeneire <brice@waegenei.re>2020-04-01 15:19:25 +0200
committerGuix Patches Tester <>2020-04-01 14:21:06 +0100
commitc78490bf6d7517226b5a7c72fa7bf76b2bbe1e4b (patch)
tree743bdb4ba5d03a47141731759bc5af23a5a816c0
parente2bd0af373d3abfba645647e6ec674670f2bd1e4 (diff)
downloadguix-patches-c78490bf6d7517226b5a7c72fa7bf76b2bbe1e4b.tar
guix-patches-c78490bf6d7517226b5a7c72fa7bf76b2bbe1e4b.tar.gz
lint: Display result of checkers on stdout.
* guix/scripts/lint.scm (emit-warnings): Use 'current-output-port' instead of 'current-error-port'.
-rw-r--r--guix/scripts/lint.scm19
1 files changed, 12 insertions, 7 deletions
diff --git a/guix/scripts/lint.scm b/guix/scripts/lint.scm
index 97ffd57301..28b4db656c 100644
--- a/guix/scripts/lint.scm
+++ b/guix/scripts/lint.scm
@@ -10,6 +10,7 @@
;;; Copyright © 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
;;; Copyright © 2018, 2019 Arun Isaac <arunisaac@systemreboot.net>
;;; Copyright © 2019 Simon Tournier <zimon.toutoune@gmail.com>
+;;; Copyright © 2020 Brice Waegeneire <brice@waegenei.re>
;;;
;;; This file is part of GNU Guix.
;;;
@@ -46,13 +47,17 @@
;; given, the location of PACKAGE otherwise, the full name of PACKAGE and the
;; provided MESSAGE.
(for-each
- (lambda (lint-warning)
- (let ((package (lint-warning-package lint-warning))
- (loc (lint-warning-location lint-warning)))
- (info loc (G_ "~a@~a: ~a~%")
- (package-name package) (package-version package)
- (lint-warning-message lint-warning))))
- warnings))
+ (lambda (lint-warning)
+ (let* ((package (lint-warning-package lint-warning))
+ (name (package-name package))
+ (version (package-version package))
+ (loc (lint-warning-location lint-warning))
+ (message (lint-warning-message lint-warning)))
+ (parameterize
+ ((guix-warning-port (current-output-port)))
+ (info loc (G_ "~a@~a: ~a~%")
+ name version message) )))
+ warnings))
(define* (run-checkers package checkers #:key store)
"Run the given CHECKERS on PACKAGE."