简体   繁体   English

如何在 Windows 上默认将 Python 3.8 切换到 Python 3.6?

[英]How can I switch Python 3.8 to Python 3.6 as default on windows?

I got two versions of Python on Windows, and try to set Python 3.6 as default.我在 Windows 上有两个版本的 Python,并尝试将 Python 3.6 设置为默认值。 Does anyone know how can I set it?有谁知道我该如何设置? Many thanks!非常感谢!

This is most likely due to the path variable.这很可能是由于路径变量造成的。 You can see this in a command window by typing您可以通过键入在命令窗口中看到这一点

Path小路

at your prompt.在您的提示下。

To update the settings,要更新设置,

Open the 'System' properties.打开“系统”属性。 System Properties系统属性

Open Environment Variables Path Variables开放环境变量路径变量

Highlight the 'Path' Variable and click edit.突出显示“路径”变量并单击编辑。 Edit Path Variable编辑路径变量

Edit the values for the Python entries, to point to the desired python version.编辑 Python 条目的值,以指向所需的 Python 版本。 enter image description here在此处输入图片说明

OK on all boxes, close any CMD windows open, and open new one.在所有框上确定,关闭任何打开的 CMD 窗口,然后打开新的窗口。 Python command should now reference the correct location. Python 命令现在应该引用正确的位置。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM