Donnerstag, 26. Februar 2009

Using multiple Ruby versions with Textmate

I have currently Ruby 1.8.6 and 1.9.1 on my machine. To test my libraries against both versions, it would be very convenient to switch between versions within your IDE . With Netbeans there's no problem as you can define different ruby environments (Tools/Ruby Platforms). In Textmate I couldn't find anything like that. But there's an easy way too: just define the path to your ruby version in the start script, just like you would do it for a shell script.
puts RUBY_VERSION # => 1.8.6
puts RUBY_VERSION # => 1.9.1

Keine Kommentare: