guix-devel
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: pypi URL change


From: Ben Woodcroft
Subject: Re: pypi URL change
Date: Sat, 18 Jun 2016 08:33:29 +1000

>> So I think we must either write the hash or the entire URL into the
>> package, or grab the json from pypi each time we download.

>The former, I guess.
>
>I guess the hash is SHA1, right?
>
>Maybe we could make something like:
>
>  (define-syntax-rule (pypi-origin package sha1 sha256-string)
>    (origin
>      (method url-fetch)
>      (uri (string-append … sha1 …))
>      (sha256 (base32 sha256-string))))
>
>and then use it like:
>
>  (package
>    (name "python-foo")
>    (source (pypi-origin "foo" "cabba9e" "somelongstring")))


Thanks for the specific advice. I've attached some patches, the first of which
makes this change, the others using it. However, it wasn't clear to me how to
include patches or other parts of 'origin' here. Alos, Having to define
".tar.gz" each time seems a bit inelegant.

Do you have any suggestions on how to improve this approach?

Thanks,
ben




reply via email to

[Prev in Thread] Current Thread [Next in Thread]