[Ironruby-core] Using the console in IronRuby on Rails

Shay Friedman shay.friedman at gmail.com
Fri Oct 30 14:50:23 EDT 2009

Hi there,

I tried to use the Ruby on Rails console with IronRuby on an application I'm
building by executing "ir script/console". Doing so ended up with an
exception from RubyProcess.CreateProcess.

I debugged and found out that RoR tries to execute irb.bat which is MRI's,
so I modified rails-2.3.3\lib\commands\console.rb to point to iirb.bat
instead. That didn't work as well.
I continued and discovered that RubyProcess doesn't consider bat files as
executables. I don't know if it's on purpose but in order to fix the
problem, I added the bat extension to the valid executable extension list
and set the full path of iirb.bat in rails' console.rb file.

Am I doing something wrong or is my little patch correct?


Shay Friedman
Author of IronRuby Unleashed
Follow me: http://twitter.com/ironshay
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://rubyforge.org/pipermail/ironruby-core/attachments/20091030/3402fd67/attachment.html>

More information about the Ironruby-core mailing list