Cygwin Python and Windows Ruby

Posted by Cheezo on Super User See other posts from Super User or by Cheezo
Published on 2012-06-13T03:49:05Z Indexed on 2012/06/13 4:43 UTC
Read the original article Hit count: 562

Filed under:
|
|
|
|

I have a peculiar setup as follows:

  1. I have cygwin installed on a Windows 7 machine. I need execute a python script setup in cygwin from the windows CLI. This works fine :

    c:\cygwin\bin\python2.6.exe c:\cygwin\bin\python-script

This python-script accesses a file: ~/.some_config_file which translates to /home/user-name when i execute it from Windows as above. So this works as expected.

Now, the next step is to execute this python script from ruby(which is setup on Windows natively w/o Cygwin). When i execute the script from ruby, the ~/.some_config_file translates to /cygdrive/c/Users/user-name instead of the expected /home/user-name leading to the script failing.

I understand that something in the environment, PATH etc needs to be set correctly although i cannot seem to find what exactly.

© Super User or respective owner

Related posts about windows-7

Related posts about linux