RubyMine 1.0 Beta Released: A Solid, IntelliJ Based Ruby and Rails IDE
Five months ago JetBrains (the company behind Java IDE IntellJ IDEA) released a "public preview" of RubyMine, a new Ruby and Rails IDE. Now, they've released the beta of version 1.0, the precursor for a final 1.0 launch later this month. You can download it right away - it came in at about a 75MB download for OS X, but Windows and Linux versions are also available.
When I posted about the preview of RubyMine five months ago, several people raved about how great they thought JetBrains' IntellIJ IDEA IDE was (which RubyMine is built upon). I don't have any personal experience with IntellIJ so you'll need to make your own mind up, but in casual testing RubyMine worked well. There were a few rough edges (project file list didn't always update with new files quickly; some minor interface snafus; had to add db:migrate Rake task manually) and there's the downside that it takes several minutes to start your first project as it wants to scour through all of your Ruby libraries. On the plus side, it felt more intuitive to put together a basic Rails app than in the other IDEs I've tried so far.
Ruby Inside will feature a complete review once the final release drops.
The Feature Set
On the surface, RubyMine offers all of the features you'd expect from a high-end IDE:
- Code completion
- Code snippet support
- Refactoring tools
- Project file management / navigation
- HTML, CSS, and JavaScript editing (including Erb support)
- RSpec and Test::Unit support (with GUI-based test runner)
- Built-in Rails console
- Ruby debugger (with full support for Rails apps)
JetBrains' RubyMine blog is a good source for info about these features as most of them have been added over time.
It's Commercial - But Only $99 (or $49, if you want)
RubyMine is available as a free, 90 day trial, but is ultimately a piece of commercial software that will retail for $99. JetBrains have a sign up form where you can get a 50% off coupon for the final version of RubyMine 1.0, however, so that should take the sting out of the tail and bring the price down to $49.
I was a bit worried when I first mentioned RubyMine that it was going to be a $200+ app that people would be reluctant to buy, but if you can get the coupon to get it down to $49, it's a great deal. Even at $99, it's not bad, although, naturally, there are plenty of open source options if it's not to your taste.
April 3, 2009 at 3:33 am
After touring Netbeans, Aptana and RubyMine, I don't see anything in RM that would compel me to pay for it. It doesn't add anything Netbeans doesn't have, and lacks (or at least, lacked a few months ago) an integrated query tool like Netbeans has. Of the three, I think Netbeans offers the most bang for your buck (and I gave all three a valiant try...I even purchased Aptana before eventually slinking back to NB).
If I'm wrong, I'd love to hear why...especially with list of feature I'm missing.
April 3, 2009 at 6:22 am
Although the TextMate plugin for Cucumber is already pretty good, it would be great with some competition: http://www.jetbrains.net/jira/browse/RUBY-2361
April 3, 2009 at 9:20 am
Hi John,
> It doesn't add anything Netbeans doesn't have
Сomparing to Netbeans RM has more intelligent code completion and type inference (I can provide examples if you wish). Also RM provides inspections and smart completion for values of different rails calls, e.g. url_for, render, redirect, has_one, etc. More over RubyMine has out of the box Git support. I like RubyMine's Rails View and Rails Models relation diagram. And at last I personally don't like Netbeans UI.
April 3, 2009 at 9:35 am
Than God We have Vim. :)
April 3, 2009 at 2:11 pm
Hi Roman, could you please provide the examples you're talking about? Thanks!
April 3, 2009 at 4:34 pm
I've been closely watching RM development over the last few months. I keep trying it for a few days then falling back to Netbeans as it works better (IMHO) This is mainly due to me being very familiar with all my NB keyboard shortcuts i.e. control + tab, control + A and so on... some of which I have struggled to find RM equivalents.
I do have two minor (but growing) annoyances with Netbeans:
1. Double click (or word select keypress) does not select complete variable if it is camel-cased. This has been fixed in .rb files yet remains broken in .erb/.rhtml files.
2. Git integration is available via nbgit (many thanks to authors) although it does not work on Netbeans > 6.5.... yet.
I must admit that every time I have tried RM I've had less reason to leave it for Netbeans.
Will definitely take advantage of the 50% off coupon and thanks for the heads up on that Peter!
April 4, 2009 at 12:17 pm
Hi Sergei,
>Hi Roman, could you please provide the examples you're talking about? Thanks!
Yes, sure!
Let's compare code completion of RubyMine 1.0 beta(www.jetbrains.com/ruby) and Netbeans 6.5.1 (the latest release from official site), ruby 1.8.6, rails 2.2.2
1. Create new ruby script
#######################
p^
#######################
Let's compare completion list from NB and RM.
You can easily check that all methods suggested by RM methods defined in this scope, and NB contains a lot of false positives(pretty_print_inspect, public_class_method, etc.)
2. Create script
#######################
class Foo
end
Foo.^
#######################
Comparing to RM Netbeans suggest method "yaml_as" but in fact it is undefined in context
3. Create script
#######################
class Foo < ^
end
#######################
Compare autocompletion for super class names. RM suggest lots of classes, NB - suggests keywords
4. Create script
#######################
class Foo
end
a = Foo.new
def a.boo
end
b = Foo.new
puts defined? a.^
puts defined? b.^
#######################
RM suggests "boo" method only for 'a' instance, and NetBeans suggests "boo" also for b, which obviously doesn't have such method.
P.S: RM by default doesn't highlight method call as error if method with the same names exists somewhere in current context although type inference may not understand it. So if you enable more accurate check: RM | Settings | Inspections | Ruby | Unresolved ruby references | Warn about implicit text matched resolve results. RM will warn about missing method "boo" in "b.boo".
5. Create new Rails application and generate Person model with name:string, age:integer, adress:text using scaffold. Let's open PeopleController, index action.
Type ruby code:
#######################
Person.find(:all).each do |p|
p.a^
end
#######################
Netbeans doesn't suggest "age" and "adress" db fields. RubyMine suggest this fields and more over it understands that p.age is Fixnum and p.adress is String!
6. Also RM provides autocompletion of files in require calls:
#######################
require "^"
#######################
In Netbeans this doesn't work.
7. And more and more =)
April 4, 2009 at 2:15 pm
It seems tag which described caret position was automatically removed from post text. In examples 1..6 caret should be instead of "[CARET]"
1.p[CARET]
2.Foo.[CARET]
3.class Foo < [CARET]
4.
puts defined? a.[CARET]
puts defined? b.[CARET]
5.p.a[CARET]
6.require "[CARET]"
April 4, 2009 at 6:50 pm
I've personally never found a compelling reason to switch from Textmate, but that might be because I've given up too quickly when trying Netbeans, Aptana, and RubyMine. The obstacles they've posed might have prevented me from discovering their benefits.
Brian Leonard of Sun gave a demo of NB at acts_as_conference a year ago, and it looked pretty compelling, but I just can't get past the ugly pseudo-Cocoa interface. (If you can't make Java look like Cocoa, then make it look like something else, not a really super bad imitation of Cocoa!) Using a powerful app with a lousy UI is like watching a Shakespearean play with bad actors--it's hard to get past the awful delivery to appreciate the underlying substance.
I seem to remember older RubyMine betas suffering from this same problem, but I'm not sure. I'll definitely give it a try, and hopefully will discover the power that IntelliJ is known for.
Another problem with NB was the key bindings. I seem to remember a very important one that conflicted with QuickSilver. Hello!? They are clearly not clued into the Ruby/Rails culture. No one wants to change their keyboard habits to try a new piece of software. Sun (etc.) need to realize that Mac is the dominant Ruby platform, and Textmate the dominant editor, and Quicksilver (or Butler, etc.) is used ubiquitously, and then DESIGN accordingly. The more barriers to adoption they create, the less adoption.
Many people will find price to be a major barrier to entry. That's unfortunate. For anyone who makes their living programming, $99 is an absolutely trivial expense.
April 5, 2009 at 3:59 pm
Rubymine needs to move beyond the easy stuff and focus on providing real value to the developers. Something that would prompt me to consider working with it instead of NetBeans would be interactive debug support. Set a breakpoint and be able to do ad-hoc evaluation, variable setting etc. Also, the Rails console needs to be far more interactive and powerful than it is currently.
April 6, 2009 at 5:07 am
I like Textmate is very fast, but we know that it is not a true IDE.
With Aptana and Netbeans I like somethings on both, but the Eclipse
look and feel of Aptana and the JavaFace of NetBeans is not my loved
enviorments :)
And when someone say: I love it because bla, bla.. Read the source..
Seems to be a kind of religion boy, not a real developer man!
So my friends open your minds, try it, learn it, so after feel days
you can say one or two goods or bads words about it.
Until now my experiences with it was very productive.
And $99,00 is acceptable, or all software must be free?
We make software and, almost all of us, got money from it.
Thanks.
April 6, 2009 at 10:02 am
Hi Bharat,
>Set a breakpoint and be able to do ad-hoc evaluation, variable setting etc.
If I understand you right - this is "Evaluate Expression" feature which works in RubyMine
April 6, 2009 at 4:56 pm
I tried it out, but only for a bit. It wasn't finding my gems and I couldn't specify the gem path... It also wasn't obvious how to do a lot of the things I find absolutely necessary, such as quickly jumping from a model to its spec or migration, from a controller action to its associated view, or from a view to a partial. I'm sure the feature exists, but it wasn't intuitive in my estimation.
April 7, 2009 at 5:03 am
I've been using Intellij IDEA for a couple of years (I am Java dev at my full-time job and Ruby dev in couple of opensource projects) and I 100% sure that it is the best IDE for Java. Neither NB nor Eclipse even comparable to it.
If JetBrains would make RM even 1/5 as good as IDEA I am sure that it would be also the best Ruby IDE for Ruby.
Keep a good work JetBrains!
April 7, 2009 at 12:14 pm
Hi Brian,
1.
> jumping from a model to its spec
> from a controller action to its associated view
Just open "Go to" section in main menu. Also it is available in "Rails" project view. For me it seems quite intuitive.
2. For Navigating from view to partial you can just resolve partial name reference (ctrl+b/ctrl+mouse clikck) in call like "render :partial => 'problem_report'". May be it is good idea to provide special action to show list of used partials in current view. Thanks for the feature!
April 7, 2009 at 5:22 pm
I'm taking RubyMine for a spin, although it is doubtful anything will move me away from TextMate.
Question: Does anyone know why my RUN button (F8) is grey-ed out? Is it not possible to run a Ruby script from within RedMine?
Thanks Peter and keep up the good work with RubyInside.
April 8, 2009 at 3:40 pm
Thanks for the response, Roman. I do see now what you're talking about. I guess I'm not used to having to dig through menus to find stuff, considering my background :) What about an option to specify gem path? That really seems like a big bug. Rubymine seems to think that my gems are in ~/.gems, but they're in /usr/local/lib/ruby/gems/1.8/, which is reflected in my $GEM_PATH.
April 8, 2009 at 5:32 pm
Got excited there for a minute... I thought I read Redmine http://www.redmine.org :(
April 10, 2009 at 9:17 am
Hi Brian,
>an option to specify gem path
I suppose such option isn't necessary. RubyMine takes GEM pathes from output of "require 'rubygems'; puts Gem.path" command during creating Ruby SDK. Also what it your OS? By default MacOS applications(except Terminal.app) don't use env variables specified in .profile.
>gems are in ~/.gems
When you install gems without root access privileges gem package manager automatically installs them only for current user in ~/.gems.
April 10, 2009 at 9:26 am
Hi Markus,
> Does anyone know why my RUN button (F8) is grey-ed out? Is it not possible to run a Ruby
Just chose "run" option from context menu.
In this case RubyMine will create quick run configuration for current ruby script. If you want you can also specify ENV variables for you script etc. Also you can save several run configurations for your scripts and the use this quick list for executing your scripts, test or rake tasks.
April 12, 2009 at 1:35 pm
Thank you Roman, that did the trick. I guess I was having flashbacks from Eclipse where certain commands are only available in various contexts.
Thanks for the help.
April 15, 2009 at 10:33 am
One thing to mention is the outstanding support you get from JetBrains. I've used IntelliJ for about a year and a half now. I've contacted their support team about a half dozen times, and always got an immediate response. Several times response was in under two minutes. Which is just amazing!