lint: patch-file-names: Simplify 'search-patch' error handling.
* guix/lint.scm (check-patch-file-names): Remove 'message-condition?'
guard, which is useless since d51bfe242f
.
Remove call to 'format' in the 'formatted-message?' case.
master
parent
1cbda46d4a
commit
b73981369e
|
@ -663,17 +663,11 @@ from ~a")
|
||||||
(define (check-patch-file-names package)
|
(define (check-patch-file-names package)
|
||||||
"Emit a warning if the patches requires by PACKAGE are badly named or if the
|
"Emit a warning if the patches requires by PACKAGE are badly named or if the
|
||||||
patch could not be found."
|
patch could not be found."
|
||||||
(guard (c ((message-condition? c) ;raised by 'search-patch'
|
(guard (c ((formatted-message? c) ;raised by 'search-patch'
|
||||||
(list
|
|
||||||
;; Use %make-warning, as condition-mesasge is already
|
|
||||||
;; translated.
|
|
||||||
(%make-warning package (condition-message c)
|
|
||||||
#:field 'patch-file-names)))
|
|
||||||
((formatted-message? c)
|
|
||||||
(list (%make-warning package
|
(list (%make-warning package
|
||||||
(apply format #f
|
(formatted-message-string c)
|
||||||
(G_ (formatted-message-string c))
|
(formatted-message-arguments c)
|
||||||
(formatted-message-arguments c))))))
|
#:field 'source))))
|
||||||
(define patches
|
(define patches
|
||||||
(match (package-source package)
|
(match (package-source package)
|
||||||
((? origin? origin) (origin-patches origin))
|
((? origin? origin) (origin-patches origin))
|
||||||
|
|
Reference in New Issue