在Ubuntu 20 版本的时候,不支持直接下载python2的pip ,所以,有下面的解决方法
Start by enabling the universe repository:
1
sudo add-apt-repository universe
Update the packages index and install Python 2:
1
2sudo apt update
sudo apt install python2Use curl to download the get-pip.py script:
1
curl https://bootstrap.pypa.io/get-pip.py --output get-pip.py
Once the repository is enabled, run the script as sudo user with python2 to install pip :
1
sudo python2 get-pip.py
Verify the installation
1
pip2 --version