How to Install Pip on Debian 10

Table of Contents
Install PIP on Debian 10
PIP stands for Python Package Index (PyPI) used for the installation and management of software packages in Python. PIP makes it very easier to install packages in Python. Now you are going to install PIP on Debian 10 and you will also learn some basic commands in PIP.
Prerequisites
Before you start to install PIP on Debian 10. You must have a non-root user account on your server with sudo privileges.
1. Install PIP for Python 3
Before start installing PIP on Debian, you should update the package index by entering the following.
sudo apt update
Now to install PIP on Debian enter following command
sudo apt install python3-pip
To confirm installation and check the version of PIP enter following command
pip3 --version
The output should be :
Output: pip 9.0.1 from /usr/lib/python3/dist-packages (python 3.6)
If output comes as above then you have successfully installed PIP on Debian.
NOTE – the version number of PIP may change with time.
2. Install PIP For Python 2
Update the package manager index by entering following command
sudo apt update
After updating the package manager index to install PIP for Python 2 enter following in a terminal
sudo apt install python-pip
Check version and confirm installation by entering the following
pip --version
The output should be :
Output pip 9.0.1 from /usr/lib/python2.7/dist-packages (python 2.7)
3. Basic usage of PIP for python 3
To list all the commands in PIP enter following
pip3 --help
Get information of specific command enter following
pip3 install --help
To search package with PIP enter following
pip3 search PACKAGE_NAME
Install package with PIP enter following in the terminal
pip3 install PACKAGE_NAME
To install package from requirements file
pip3 install -r requirements.txt
Upgrade package with PIP
pip3 install --upgrade PACKAGE_NAME
Uninstall package with PIP
pip3 uninstall PACKAGE_NAME
4. Basic usage of PIP for python 2
To list all the commands in PIP enter following
pip --help
Get information of specific command enter following
pip install --help
To search package with PIP enter following
pip search PACKAGE_NAME
Install package with PIP enter following in the terminal
pip install PACKAGE_NAME
To install package from requirements file
pip install -r requirements.txt
Upgrade package with PIP
pip install --upgrade PACKAGE_NAME
Uninstall package with PIP
pip uninstall PACKAGE_NAME
Conclusion
Here you have learned how to install PIP on Debian 10 for python 3 and python 2. If you have any queries regarding this please don’t forget to comment below.
LATEST POSTS
-
How to Install Arduino IDE on Linux Mint 19
-
How to install Pip on Debian 9
-
How to Install MySQL on Ubuntu 18.04
-
How to Install Notepad++ on Ubuntu 18.04
-
How to Install Google Chrome on Debian 10
-
How to Install R on CentOS 7
-
How to Install WebStorm on Ubuntu 18.04
-
How to Change or Rename Username and UID in Linux
-
How to Install R on Debian 10
-
How to Install Eclipse IDE on Debian 9
-
How To Secure Nginx with Let’s Encrypt SSL on Debian 9
-
How to Install Anaconda on Debian 9