Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

How to change version of Python picked up by Cygwin

Tags:

python

cygwin

I have two versions of python installed on Win7. (Python 2.5 and Python 2.7).

These are located in 'C:/Python25' and 'C:/Python27' respectively.

I am trying to run a file using Python 2.5 but by default Cygwin picks up 2.7.

How do I change which version Cygwin uses?

like image 698
Robert Whitley Avatar asked Mar 07 '12 09:03

Robert Whitley


1 Answers

The fast way is to reorder your $PATH so that 2.5 is picked up first. The correct way is to use virtualenv to create a jail environment that's specific to a python version.

like image 136
canadadry Avatar answered Sep 28 '22 10:09

canadadry