mirror of
https://codeberg.org/guix/guix.git
synced 2026-01-25 03:55:08 -06:00
import: pypi: Enforce home-page https prefix.
* guix/import/pypi.scm (make-pypi-sexp): Improve home-page handling to enforce an https:// prefix, even in the case where upstream uses http://. Change-Id: Iff4164a5f1ddc96af67ca7b092d3b9bbd6e2a827 Signed-off-by: Sharlatan Hellseher <sharlatanus@gmail.com>
This commit is contained in:
parent
73fe38fd56
commit
d66e9698a1
1 changed files with 7 additions and 2 deletions
|
|
@ -601,7 +601,12 @@ VERSION."
|
|||
(sha256 (or (and=> sha256 bytevector->nix-base32-string)
|
||||
(guix-hash-url (with-store store
|
||||
(download-to-store store source-url)))))
|
||||
(source (pypi-package->upstream-source pypi-package version)))
|
||||
(source (pypi-package->upstream-source pypi-package version))
|
||||
(home-page (project-info-home-page info))
|
||||
(home-page (if (and (string? home-page)
|
||||
(string-prefix? "http://" home-page))
|
||||
(string-append "https" (string-drop home-page 4))
|
||||
home-page)))
|
||||
(values
|
||||
`(package
|
||||
(name ,(python->package-name name))
|
||||
|
|
@ -626,7 +631,7 @@ VERSION."
|
|||
'propagated-inputs)
|
||||
,@(maybe-inputs (upstream-source-native-inputs source)
|
||||
'native-inputs)
|
||||
(home-page ,(project-info-home-page info))
|
||||
(home-page ,home-page)
|
||||
(synopsis ,(project-info-summary info))
|
||||
(description ,(and=> (non-empty-string-or-false
|
||||
(project-info-summary info))
|
||||
|
|
|
|||
Loading…
Add table
Reference in a new issue