« Bliss | Main | Pipelines Using Fibers in Ruby 1.9 »

December 25, 2007

TrackBack

TrackBack URL for this entry:
http://www.typepad.com/services/trackback/6a00d83451c41c69e200e54fb22b0b8833

Listed below are links to weblogs that reference Ruby 1.9—Right for You?:

» Ruby 1.9 Released from Mandarin Soda
Enjoy the Holidays with a new 1.9 Dev Release. Apparently Mongrel and Rails are fairly close to being compatible. Nice overview here. Update. PragDave has some rather pragmatic advice for approaching the 1.9 development release. And yes, the l... [Read More]

Comments

Joon You

Excellent post! I think creating a VM using Parallels or VMWare to play with 1.9 is another good option without taking any risk. Just my $.02.

Dr Nic

I created another user account, installed ruby19 locally and added it to the front of the path; then checked out copies of all my gems and tried to run their tests. First problem was with the rake command requiring a 1.8 library that's no longer in 1.9 (ftools).

The process of moving to 1.9 will take time as we iron out new dependencies, deprecations etc 1 by 1.

It'll be worth the effort though!

Rick DeNatale

Nic,

Assuming you are talking about yesterdays release of 1.9.0, Rake is now part of the distribution, so rather than using a gem version of Rake with 1.9 you should be using the 1.9 version of Rake.

Rubygems is also now part of the standard 1.9.0 distribution. The intent is for much if not all of the standard library to be repackaged as pre-installed gems, at least according to what's been said of late on ruby-core.

M. Edward (Ed) Borasky

What you describe is pretty much my plan with one exeception: I want to be able to use all the Ruby behavior/test driven development tools, and I want to be able to run benchmarks against multiple versions of Ruby. So I need a "master" Ruby, probably MRI, running RSpec, flog, heckle, ZenTest, etc., and multiple sandboxes, one for each "Ruby Under Test". This sort of thing is more or less trivial on Linux -- chroot is your friend, etc. But what about Windows? How do you do a "sandbox" on a Windows machine?

dubek

irb(main):001:0> RUBY_VERSION
=> "1.8.6"
irb(main):002:0> "cat"[1]
=> 97
irb(main):003:0> "cAt"[1]
=> 65


:-)

Ach

Hi Dave,
Thanks for informative post. I am a beginner Ruby experimenter and am going to read a solid book (preferably yours!) to learn about it. So which version do you recommend for jump start? Will I lost a lot if I read your current book?
-Thanks for help

Dave Thomas

Ach:

I think I'd recommend starting with the stable Ruby 1.8. In that case, the second edition of the PickAxe is the guide to take with you. If you get it from our site, you'll be able to upgrade to the third edition, which covers Ruby 1.9, for a relatively small amount.


Dave

Ruby what?

Is this another fad? Why don't you use Mod Perl?

Ryan Allen

Ah, integrated rake and rubygems, I think that's excellent! I wonder what's going to happen to all those other VM projects still working on 1.8?

Luca

Hi Dave,

Great post! Do you already debugged with ruby 1.9?
I tried to install ruby-debug gem, but it fails during the building. I also noticed a fatal error with the -r debug argument.

Dave Thomas

Luca:

The debugger hangs for me (on OSX). It's one of the things broken in the development release.

Carl Bourne

Great article - compiled and installed easily.

Only problem is the TextMate's RubyMate throws the following error:

RubyMate r8136 running Ruby r1.9.0 (/Users/cbourne/ruby19/bin/ruby)
>>> testversion.rb

:0:in `require': /Applications/TextMate.app/Contents/SharedSupport/Bundles/Ruby.tmbundle/Support/RubyMate/catch_exception.rb:13: invalid multibyte char (SyntaxError)
/Applications/TextMate.app/Contents/SharedSupport/Bundles/Ruby.tmbundle/Support/RubyMate/catch_exception.rb:13: invalid multibyte char
/Applications/TextMate.app/Contents/SharedSupport/Bundles/Ruby.tmbundle/Support/RubyMate/catch_exception.rb:13: syntax error, unexpected $end, expecting ')'
...ML e.message.sub(/`(\w+)'/, '‘\1’').sub(/ -- /, ' — ')...
...

Any suggestions on how to fix it?

Andrew

I prefer to use configure --program-suffix=19

This creates everything as normal but calls the binary "ruby19", irb19, ri19, etc

Stefan Kroes

I had had a lot of issues getting ruby 1.9 to work in this way and other simiilar ways. Finally I tried macports (google!) and that installed ruby 1.9 and all dependencies on both my macs without problems.

Install the package from the site
Add export PATH=/opt/local/bin:/opt/local/sbin:$PATH to your .profile in your home dir
Run: sudo port selfupdate (in the console)
Run: sudo port install ruby19 (in the console)
Wait quite a long time (like 20 minutes) and you are all done!

John Griffiths

As always you are a genius, I'll try this over the weekend and see if my blogging engine handles the new 1.9 release; would be pretty awesome if it did without a hitch ;-)

All the best, love the screencasts you did for pragmatic programmer.

Luca Guidi

Dave, I successfully installed ruby-debug on my macbook with multiruby: http://bit.ly/zMKdZ

The comments to this entry are closed.

Now in Beta

  • Programming Ruby, 3rd Edition
    Third Edition, Covering Ruby 1.9, now available
My Photo

Pragmatic Stuff

Photos

  • www.flickr.com
    This is a Flickr badge showing public photos from pragdave tagged with pragdave_badge. Make your own badge here.