Software Development

Install Any pip Package Globally – Linux

Instead of the package installing in:

/home/username/.local/bin

and install it globally and have it accessed from any Linux user, install it with sudo -H flag. For example:

sudo -H pip3 install seaborn

The above installs it in /usr/local/lib/python3.5/dist-packages and is accessible globally by any user or Python application.

This issue arose when I was trying to run a Jupyter notebook. There was a missing seaborn Python package but it was only installed in the .local folder of the logged in user (/home/user/.local).

Advertisements

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out /  Change )

Google+ photo

You are commenting using your Google+ account. Log Out /  Change )

Twitter picture

You are commenting using your Twitter account. Log Out /  Change )

Facebook photo

You are commenting using your Facebook account. Log Out /  Change )

Connecting to %s