On Tuesday, July 25, 2017, Nick Timkovich <prometheus...@gmail.com> wrote:

> On Tue, Jul 25, 2017 at 1:45 PM, Aleks Bunin <b...@enlnt.com
> <javascript:_e(%7B%7D,'cvml','b...@enlnt.com');>> wrote:
>
>>  I’m writing installation instructions for a package and have a question:
>> what is the correct predictable URL for the package?
>>
>
> I would guess you need to start from the API (e.g.
> https://wiki.python.org/moin/PyPIJSON) and go wherever it says.
>

$ pip download pkgname><ver

Determines the package URL.

https://pip.pypa.io/en/stable/reference/pip_download/#examples

https://github.com/pypa/pip/blob/master/pip/commands/download.py

Would this solve?:

- [ ] ENH: pip.commands.download: --only-print-url



> If writing your own automated thing, you could access the API yourself, or
> just delegate it to pip. For user-facing instructions, I would highly
> suggest having them do "pip install X" rather than have them download a
> tarball, extract it, find and run setup.py. If you want to pin it at a
> version, you can do something like:
>
> pip install "virtualenv==15.1.0"
> pip install "django>=1.11,<1.12" # for a range of versions
>
> Nick
>
>
>
_______________________________________________
Distutils-SIG maillist  -  Distutils-SIG@python.org
https://mail.python.org/mailman/listinfo/distutils-sig

Reply via email to