I am trying to run Cygwin version of ruby.exe from a .NET application, but I am stuck.
c:\>"c:\cygwin\bin\ruby.exe" c:\test\ruby.rb /usr/bin/ruby: no such file to load -- ubygems (LoadError)
As you can see, Ruby cannot find libraries because it is looking for some Linux-style paths.
Obviously, when I run ruby.exe from .NET, since it cannot find the libraries, it fails, as shown above.
If I do not load any library, it works fine:
c:\>"c:\cygwin\bin\ruby.exe" -v ruby 1.8.7 (2008-08-11 patchlevel 72) [i386-cygwin]
Initially, cygwin starts with this cygwin.bat
chdir C:\cygwin\bin bash --login -i
How can I get .NET to first go into a cygwin environment and then run ruby ββin that environment?
- I can not use Windows Ruby, I need cygwin ruby.
- I know about the potential use of "bash" interactive driving, but that sounds dirty unless there is a good way to do it.
source share