[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
09/09: lint: Append "/info/refs" to git-reference-url.
From: |
guix-commits |
Subject: |
09/09: lint: Append "/info/refs" to git-reference-url. |
Date: |
Mon, 27 Mar 2023 12:52:23 -0400 (EDT) |
civodul pushed a commit to branch master
in repository guix.
commit c9af27d4ca733b20f09019f1465d3e5fdc1ec724
Author: Felix Lechner <felix.lechner@lease-up.com>
AuthorDate: Mon Mar 20 21:25:41 2023 -0700
lint: Append "/info/refs" to git-reference-url.
For the atftp package added in the preceeding commit, lint produced this
warning:
gnu/packages/networking.scm:2924:5: atftp@0.8.0:
URI https://git.code.sf.net/p/atftp/code not reachable:
404 ("Not Found")
Thanks to Sergey Trofimov for suggesting a fix! [1]
[1] https://issues.guix.gnu.org/62156#3
It was implemented here, and the warning disappeared.
* guix/lint.scm (check-source): Append "/info/refs" to git-reference-url.
Co-authored-by: Sergey Trofimov <sarg@sarg.org.ru>
Signed-off-by: Ludovic Courtès <ludo@gnu.org>
---
guix/lint.scm | 9 ++++++++-
tests/lint.scm | 2 +-
2 files changed, 9 insertions(+), 2 deletions(-)
diff --git a/guix/lint.scm b/guix/lint.scm
index 9eece374ff..3a93ba5325 100644
--- a/guix/lint.scm
+++ b/guix/lint.scm
@@ -1224,7 +1224,14 @@ password, provided REF's URI is HTTP or HTTPS."
'())))
((git-reference? (origin-uri origin))
(warnings-for-uris
- (list (string->uri (git-reference-url (origin-uri origin))))))
+ ;; for atftp, lint produced a warning:
+ ;; gnu/packages/networking.scm:2924:5: atftp@0.8.0:
+ ;; URI https://git.code.sf.net/p/atftp/code not reachable:
+ ;; 404 ("Not Found")
+ ;; fix from here: https://issues.guix.gnu.org/62156#3
+ (list (string->uri (string-append
+ (git-reference-url (origin-uri origin))
+ "/info/refs")))))
((or (svn-reference? (origin-uri origin))
(svn-multi-reference? (origin-uri origin)))
(let ((uri (svn-reference-uri-with-userinfo (origin-uri origin))))
diff --git a/tests/lint.scm b/tests/lint.scm
index ce22e2355a..71e38550a1 100644
--- a/tests/lint.scm
+++ b/tests/lint.scm
@@ -1052,7 +1052,7 @@
(parameterize ((%http-server-port 0))
(with-http-server `((,redirect ""))
(test-equal "source, git-reference: 301 -> 200"
- (format #f "permanent redirect from ~a to ~a"
+ (format #f "permanent redirect from ~a/info/refs to ~a"
(%local-url) initial-url)
(let ((pkg (dummy-package
"x"
- branch master updated (da410b45a9 -> c9af27d4ca), guix-commits, 2023/03/27
- 04/09: substitute: Gracefully handle TLS termination while fetching narinfos., guix-commits, 2023/03/27
- 05/09: gnu: hevea: Update to 2.36., guix-commits, 2023/03/27
- 01/09: services: syslog: Add 'configuration' action., guix-commits, 2023/03/27
- 06/09: syscalls: 'getxattr' throws upon error., guix-commits, 2023/03/27
- 03/09: services: ntpd: Add 'configuration' action., guix-commits, 2023/03/27
- 09/09: lint: Append "/info/refs" to git-reference-url.,
guix-commits <=
- 02/09: services: network-manager: Add 'configuration' action., guix-commits, 2023/03/27
- 07/09: lint: Prevent inlining of 'package-vulnerabilities'., guix-commits, 2023/03/27
- 08/09: gnu: Add atftp., guix-commits, 2023/03/27