Ubuntu16.04安装Python3.6 和pip(python3 各版本切换)


安装

sudo add-apt-repository ppa:jonathonf/python-3.6
sudo apt-get update
sudo apt-get install python3.6

配置只输入python3时就默认使用3.6版本

也可使用上面链接里说明的方法

1、update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.1

2、update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.2

3、update-alternatives --config python3

4、python3 -V

设置pip:

1、apt-get install python3-pip    # Python3

2、apt-get install python-pip      # Python2

 


免责声明!

本站转载的文章为个人学习借鉴使用,本站对版权不负任何法律责任。如果侵犯了您的隐私权益,请联系本站邮箱yoyou2525@163.com删除。



 
粤ICP备18138465号  © 2018-2025 CODEPRJ.COM