osdir.com


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

How do I purge pip intsall --user packages?


On 17 Sep 2019 19:10:29 GMT
Martin Sch??n <martin.schoon at gmail.com> wrote:

> I have installed a bunch of packages using pip install --user and
> I went for a non-standard location for the install. Now I regret
> this and would like to wipe this and start all over again using
> the standard location. Is it enough to delete the folder I
> specified or am I missing something? Having to uninstall each
> and every package would be tedious...
> 
> /Martin

Do you want to uninstall all per user installed packages?

Then you could try: 

pip3 list --user | tail -n +3 | while read p rest; do pip3 uninstall $p;done