Linux上两个版本的python。如何使2.7成为默认我在linuxbox上有两个版本的python:$pythonPython 2.6.6 (r266:84292, Jul 10 2013, 22:48:45) [GCC 4.4.7 20120313 (Red Hat 4.4.7-3)] on linux2Type "help", "copyright", "credits" or "license" for more information.>>> $ /usr/local/bin/python2.7Python 2.7.3 (default, Oct 8 2013, 15:53:09) [GCC 4.4.7 20120313 (Red Hat 4.4.7-3)] on linux2Type "help", "copyright", "credits" or "license" for more information.>>> $ which python/usr/bin/python$ ls -al /usr/bin/python-rwxr-xr-x. 2 root root 4864 Jul 10 22:49 /usr/bin/python如何使2.7成为默认版本,所以当我键入python这让我进了2.7?
3 回答
智慧大石
TA贡献1946条经验 获得超3个赞
/usr/local/bin
PATH
/usr/bin
.
.bashrc
:
export PATH="/usr/local/bin:$PATH"
python
/usr/local/bin
/usr/bin
.
/usr/local/bin/python
python2.7
- 3 回答
- 0 关注
- 512 浏览
添加回答
举报
0/150
提交
取消