2014-10-21 41 views
0

如何在命令提示符中为Python 2和3设置永久路径,以便我可以在每次打开命令窗口时调用命令窗口,即用于python 2解释器的'python2'或用于python 3解释器的'python3'Python双重安装

+2

你有什么操作系统? – 2014-10-21 21:24:01

+0

对于Windows 7: http://stackoverflow.com/questions/3809314/how-to-install-both-python-2-x-and-python-3-x-in-windows-7 – jgritty 2014-10-21 21:26:29

+0

@ SimeonVisser Windows 7旗舰版 – user3731606 2014-10-21 21:27:45

回答

0

创建一个python2.bat和一个python3.bat文件在你的路径上(可以在你的主python文件夹中)。该文件只包含相关python.exe的位置,例如

C:\Programs\Python26\python.exe %*