简体   繁体   English

Windows 10 Python路径更新

[英]Windows 10 Python Path Update

I recently began using Windows 10. Obviously, after the upgrade, my environmental PATH variable migrated to the new OS. 我最近开始使用Windows10。显然,升级后,我的环境PATH变量迁移到了新操作系统。 On windows 10, I installed Python 3.4. 在Windows 10上,我安装了Python 3.4。 After the install, I updated my PATH variable with: 安装后,我使用以下命令更新了PATH变量:

;C:\Python34\Scripts;C:\Python34\python.exe;

However, the cmd still does not find the python commands. 但是,cmd仍然找不到python命令。 It would seem as if the PATH variable just plainly was not updated. 似乎PATH变量显然没有被更新。 Any advice on how to fix this? 有关如何解决此问题的任何建议?

Open the command prompt using console. 使用控制台打开命令提示符。

write command as python [Press Enter] 将命令写为python [按Enter]

在此处输入图片说明

If it shows the above error of "not recognized" command, don't worry. 如果它显示以上“无法识别”命令的错误,请不要担心。

Write you Python installed path in below statement, as for me It is C:\\Python34 在下面的语句中为您写Python安装路径,对我来说是C:\\ Python34

setx path "%PATH%";C:\Python34"

Run the above command on your command prompt as below Screenshot 在命令提示符下运行上述命令,如下所示

在此处输入图片说明

Run command python again, still shows same error. 再次运行命令python ,仍然显示相同的错误。

Okay, close you command prompt window & open again, type now python and press enter, It will now show what you are expecting. 好的,关闭命令提示符窗口并再次打开,现在键入python并按Enter,它将显示您的期望。

Hope it works!! 希望它能工作!!

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

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