Monday, December 4, 2006

JRuby IRB Applet Revisited

Damian Steer, regular JRuby contributor, has taken the IRB applet and run with it. He's gotten readline working (history, line editing, tab-completion), added some fonts and colors to differentiate things, and even put in an intellisense-like menu for tab completion of method names.

Very cool stuff. Keep in mind also that this could be embedded in any app (like an IDE) to provide a really nice looking interactive console. Thanks Damian!


  1. I'll update this soon with a standard swing widget for completion (now I've finally found one). Looks a bit odd in linux. Once that's done I'll port it to ruby, which will remove a nasty hack, and allow others to play.

    The colours are muted because I'm colour blind and stick to a conservative pallet :-) Suggestions welcome.

  2. Damian -
    Could you share your source code? I'm really interested to see how you did these things.

    Thanks - AYAL

  3. fantastic stuff. would be a great method to offer to allow people to try out your new classes etc.
    --> is there an easy way to
    require 'mylib' ?


  4. weepie:
    Not hard. Grab the jruby source, install your lib (in lib/ruby/site_ruby), then:

    ant jar-complete

    Simple enough?

  5. is there any place on the web where I can use a working jruby irb applet?