简体   繁体   English

Cygwin与Windows的Python版本不同

[英]Cygwin not same python version as windows

Background: 背景:

I am a .NET developer trying to set up a python programming environment. 我是一个.NET开发人员,试图设置python编程环境。

I have installed python 2.7.5 . 我已经安装了python 2.7.5 However I changed my mind and uninstalled 2.7.5 and installed python 2.7.6. 但是我改变了主意, 卸载了2.7.5并安装了python 2.7.6。

If I CMD in windows command promopt, the python version is 2.7.6 如果我在Windows命令Promopt中使用CMD,则python版本为2.7.6

When I start the cygwin shell and type: 当我启动cygwin shell并键入:

python --version python --version

It says 2.7.5, this version is was uninstalled. 它说2.7.5,此版本已被卸载。

How do I get cygwin to understand it should use the new version. 我如何让cygwin理解它应该使用新版本。 2.7.6? 2.7.6?

I believe there is commands to type in cygwin shell to solve this? 我相信有输入cygwin shell的命令来解决这个问题? Thanks on advance! 提前谢谢!

Cygwin has its own option to install its own version of Python. Cygwin可以选择安装自己的Python版本。 If you run setup.exe and poke through the Development packages, you'll find it. 如果运行setup.exe并浏览“开发”软件包,则会找到它。 You probably installed Python here as well, and are running it in Bash. 您可能也在这里也安装了Python,并且正在Bash中运行它。 If you use CMD, you're running a different version. 如果使用CMD,则您正在运行其他版本。 The fact that the version numbers overlap is just coincidental. 版本号重叠的事实只是巧合。

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

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