mirror of
https://codeberg.org/guix/guix.git
synced 2025-10-02 02:15:12 +00:00
guix: lint: Warn only if GitHub URI is not same as the package URI.
* guix/scripts/lint.scm (check-github-url): Warn only if the GitHub URI obtained after following redirects is not same as the original URI. * tests/lint.scm ("github-url: already the correct github url"): New test.
This commit is contained in:
parent
394207c1ee
commit
40fa21c22e
2 changed files with 17 additions and 7 deletions
|
@ -8,7 +8,7 @@
|
|||
;;; Copyright © 2017 Alex Kost <alezost@gmail.com>
|
||||
;;; Copyright © 2017 Tobias Geerinckx-Rice <me@tobias.gr>
|
||||
;;; Copyright © 2017, 2018 Efraim Flashner <efraim@flashner.co.il>
|
||||
;;; Copyright © 2018 Arun Isaac <arunisaac@systemreboot.net>
|
||||
;;; Copyright © 2018, 2019 Arun Isaac <arunisaac@systemreboot.net>
|
||||
;;;
|
||||
;;; This file is part of GNU Guix.
|
||||
;;;
|
||||
|
@ -820,10 +820,11 @@ descriptions maintained upstream."
|
|||
(lambda (uri)
|
||||
(and=> (follow-redirects-to-github uri)
|
||||
(lambda (github-uri)
|
||||
(emit-warning
|
||||
package
|
||||
(format #f (G_ "URL should be '~a'") github-uri)
|
||||
'source))))
|
||||
(unless (string=? github-uri uri)
|
||||
(emit-warning
|
||||
package
|
||||
(format #f (G_ "URL should be '~a'") github-uri)
|
||||
'source)))))
|
||||
(origin-uris origin)))))
|
||||
|
||||
(define (check-derivation package)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue