How to install pip and a python package for self installed python?
If you install it from source you need to run:
/usr/local/bin/python2.7 -m ensurepip
This will actually install the pip
application into /usr/local/bin
.
Python 2.7.9 and later (on the python2 series), and Python 3.4 and later include pip by default 1, so you may have pip already.
To install pip, securely download get-pip.py
Then run the following (which may require administrator access):
python get-pip.py
Source: https://pip.pypa.io/en/latest/installing.html