pip版本的安装:
sudo apt-get install python3-pip
pip版本的查看:
pip3 --version
pip3 -V
pip更新:
sudo pip3 install --upgrade pip
pip卸载:
sudo apt-get remove python3-pip
pip3安装过后在查看版本的时候会出现这个问题
1 Original exception was: 2 Traceback (most recent call last): 3 File "/usr/bin/pip3", line 9, in <module> 4 from pip import main 5 ImportError: cannot import name 'main'
执行下面命令改变里面的文件即可
sudo vi /usr/bin/pip3
1 #!/usr/bin/python3 2 # GENERATED BY DEBIAN 3 4 import sys 5 6 # Run the main entry point, similarly to how setuptools does it, but because 7 # we didn't install the actual entry point from setup.py, don't use the 8 # pkg_resources API. 9 from pip import __main__ 10 if __name__ == '__main__': 11 sys.exit(__main__._main())