[Distutils] The future of invoking pip
Marius Gedminas
marius at gedmin.as
Fri Nov 6 10:23:42 EST 2015
On Fri, Nov 06, 2015 at 02:04:38PM +1300, Robert Collins wrote:
> On 6 November 2015 at 10:08, Donald Stufft <donald at stufft.io> wrote:
> > * It's more to type, 10 more characters on *nix and 6 more characters on
> > Windows which makes it more akward and annoying to use. This is particularly
> > annoying inside of a virtual environment where there isn't really any
> > ambiguity when one is activated.
>
> cat > /usr/bin/pip << EOF
> python -m pip $@
> EOF
>
> Seriously - isn't the above entirely sufficient?
It doesn't help with my usual pattern, which used to be
$ virtualenv .
$ bin/pip install foo
but then changed[*] into
$ virtualenv .venv && ln -sfn .venv/bin bin
$ bin/pip install foo
and is likely to change[+] into
$ virtualenv .venv && mkdir -p bin && ln -sfn .venv/bin/pip bin/pip
$ bin/pip install foo
I am not running these by hand -- I have Makefiles to set up my app
environment by creating a local virtualenv and pip installing all the
tools, plus '-e .', into it. But once the basic environment is done,
I'm often installing ad-hoc one-time-use extra tools with commands like
$ bin/pip install runsnakerun
---
[*] because virtualenv's root is becoming too cluttered with files like
pip-selftest.json, and because some evil packages on PyPI install
files named README.txt into the virtualenv root.
[+] because if you symlink just the bin/ directory, bin/python fails to
set up sys.path correctly
Marius Gedminas
--
I'm sure it would be possible to speed apport up a lot, after we're done
making boot and login instantaneous.
-- Lars Wirzenius
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 173 bytes
Desc: Digital signature
URL: <http://mail.python.org/pipermail/distutils-sig/attachments/20151106/c08c6364/attachment.sig>
More information about the Distutils-SIG
mailing list