sudo add-apt-repository ppa:jonathonf/python-3.6

 

sudo apt-get update
sudo apt-get install python3.6

 

sudo update-alternatives --install /usr/bin/python3 python3 /usr/bin/python3.6 1

update-alternatives命令可以修改系统默认命令的软链指向,参考这里,上面两句指令就是修改了系统默认的/usr/bin/python3 的软链指向,指向了两个位置,最后面的1和2是优先级。

 

通过以下命令,可以切换Python3的指向

sudo update-alternatives --config python3

 

 

参考:

https://blog.csdn.net/YubaoLouisLiu/article/details/88594309

 

相关文章:

  • 2022-02-09
  • 2022-12-23
  • 2021-12-31
  • 2022-02-25
  • 2021-11-19
  • 2022-12-23
  • 2021-04-18
猜你喜欢
  • 2021-12-02
  • 2022-12-23
  • 2022-12-23
  • 2021-09-11
  • 2022-02-28
  • 2021-11-23
相关资源
相似解决方案