[TxMt] Re: TextMate 1.5 and Ruby 2.0.0

Matt Neuburg matt at tidbits.com
Mon Mar 11 19:36:20 UTC 2013


Allan Odgaard <mailinglist at textmate.org>
wrote:

> I pushed an update where we explictly call the system ruby for the host
>script. I don't see a way we can tell ruby 2.0 we don't want this new
>feature without breaking compatibility with 1.8.7.
>

This works perfectly. Thank you! When my scripts run inside TextMate
under Ruby 2.0, then, when we hit an exception, the exception report is
now formatted correctly. Bravo.

An easy test, if anyone is following along, is this script:

    puts RUBY_VERSION
    what

Run that as a Ruby script inside TextMate. First we print the Ruby
version, so you know you really are using 2.0. Then we deliberately
trigger a NameError by mentioning an undefined local variable. In the
RubyMate output, you will see everything nicely formatted, just as under
Ruby 1.8.7 and Ruby 1.9.3.

Still mulling over the wisdom of assuming that system ruby is 1.8.7. m.

PS By the way, if anyone is looking for a way to try out Ruby 2.0 on
Mac, I recommend rbenv. So easy. So harmless.

-- 
matt neuburg, phd = matt at tidbits.com, http://www.apeth.net/matt/
Programming iOS 5! http://shop.oreilly.com/product/0636920023562.do
RubyFrontier! http://www.apeth.com/RubyFrontierDocs/default.html



More information about the textmate mailing list