You can try:
easy_install pip
if you have easy_install installed
. If not you can download get_pip.py
and then do:
python get_pip.py
as documented here
This was caused by the package rst2pdf
being (indirectly) depending on pip
, combined with that you don't have write permissions on /usr/local
on your system.
The best structural solution would be to run all such programs from a python virtualenv, but since you would have to add the path to the bin
directory of that virtualenv to your PATH, you might break existing programs that rely
on the systems python and programs it got installed. So if you try that at least use the system python as base for the virtualenv and do not specify a different interpreter with --python
The lazy solution I have taken on my system, is that I changed the group permission on /usr/local
and subdirectories with sudo chgrp -R grpname /usr/local/*
. That way I am allowed to write in /usr/local
subdirectories as myself.
Of course it would be nice if pip
would check up-front if it has the rights to re-install itself before uninstalling itself.