Pages

Sunday, April 25, 2021

Uninstall python2.7 ubuntu 20.04

1. Check your current python version using: Mine shows 2.7.8
python --version
2. Remove all python 2.7 artifacts
sudo apt purge -y python2.7-minimal

3. Ubuntu 20.04 comes with python3 installed.  Instead of typing python3 every time, You can create a symlink to make it accessible using python command.

sudo ln -s /usr/bin/python3 /usr/bin/python

4. Check if pip3(python3 package manger) installed or not by typging:

pip3

5. If not installed, use below command to install it:

sudo apt-get install python3-pip