Skip to content Skip to sidebar Skip to footer

How To Pip Install To An External Drive?

I have a USB with a python installation that I carry around with me & use on computers that don't have python installed/don't allow you to install modules. I'd like to install

Solution 1:

The package is installed on your PC because you did not explicitly specify which pip binary to use.

If you execute where pip, it would display the directory of the pip binary which is currently active. In your case, it will most likely be in D: directory.

To install packages in your USB, use h:\<path>\<to>\<pip>\pip install rebound-cli.

A better option would be, creating a virtual environment in your USB and activating that environment whenever you want to use Python in your USB. Using an environment will save you from the need to explicitly specify the path to pip/python binary located in your USB

Post a Comment for "How To Pip Install To An External Drive?"