The Devver Blog

A Boulder startup improving the way developers work.

Leaving NetBeans for Emacs as my Ruby Editor

When I first started working with Ruby I used RadRails (which still has the best integrated test runner I have used). Various problems and crashes with RadRails along with exciting features being added to Ruby NetBeans enticed me to switch. I enjoyed NetBeans and some of its features, but the weight of my IDE began slowing me down. I didn’t have the control to tell it not to do some things that annoyed me.

My cofounder Ben had been using Emacs since learning Ruby. The quick speed that he could work with code, made me wonder what features I was actually using in my bloated IDE. It turned out that I had been getting annoyed with most of the advanced features because they stalled my system, crashed occasionally, or really weren’t that useful. An example of a cool feature that I hardly found useful would be Netbean’s Ruby code completion. In the past I had used Emacs to develop all my C and C++ code and I always liked it, so I decided to switch away from NetBeans and see how Emacs would hold up as my editor.

I have enjoyed using Emacs and think that I can more quickly work with code with far less hassle and frustration. I don’t expect to move back to a large IDE anytime soon. That being said there are definitely pros and cons to working with a full IDE vs an editor, and I find myself missing features sometimes. So I thought I would list out some of the pros and cons so others can weigh these issues themselves.

Reasons I miss NetBeans:

  • Graphical test integration linking to the lines of code in the stack trace
  • Navigate -> ‘Go to Declaration’, ‘Go to Test’, ‘Go to Action or View’
  • Easy code refactoring and renaming
  • Code completion, occasionally (e.g. was the Array function called include? or includes?)
  • File browsing with folder tree view
  • Graphical SVN browsing, easy branch, merge, get version, diff
  • Easy project file search (Yes, you can do, ‘grep -Ri ‘Logger’ lib/* bin/* app/* | grep -v .svn’, but that is a pain to type)
  • Easy code commenting (Apple-/ which toggles, is much nicer than Ctrl-x, Ctrl-m comment-region / uncomment-region which has to be added to your Emacs configuration)
  • Easy code formatting (Apple-shift-f, is easier than Ctrl-x, Ctrl-m indent-buffer / indent-region)

Reasons I hate NetBeans:

  • Frequently stalls (Especially if you have been out of the application for awhile)
  • Crashes (At least every couple days)
  • Not enough user control (stop indexing everything)
  • Magic behind the scenes (constantly connecting to SVN every time I saved a file)
  • Debugger didn’t work well (ended up running on the command line to get debugging)
  • Ruby Console didn’t work well (ended up using irb on the command line instead)
  • All tasks that NetBeans handles nicely for you like testing or migrations were slower (ended up running all rake task and tests on the command line)
  • Resource hog, making everything else I am running far slower
  • NetBeans ignores canceling tasks and continues trying to run them
  • Booting up takes a few minute before NetBeans completes its various start-up tasks (You can work during some of the start-up tasks, but it is slow and unresponsive until it has completed the tasks)

Things I like about Emacs:

  • Better/more key commands (I love kill/yank – the ability to kill until the end of line is incredibly useful)
  • Incredibly fast, if I am working live with someone I can jump in make an edit and be back live showing them the change on the project (Imagine having to boot NetBeans to do this)
  • Multiple copy and paste buffers. This is something you get with GNU Emacs on an X system. I can use both kill/yank from Emacs while also using my normal copy and paste to maintain two independent copy and paste buffers, very handy
  • Complete control over the editor, no longer do I have to deal with auto closing brackets or any other ‘helpful’ defaults the editor includes (You can turn them all off, but I get annoyed having to go change a bunch of settings)
  • An unexplainable feeling of being closer to the system and the code.

Written by DanM

August 8, 2008 at 3:27 pm

Posted in Development, Hacking, Misc, Ruby

15 Responses

Subscribe to comments with RSS.

  1. Having two copy/paste buffers is nice, but emacs also gives you access to a few dozen named buffers called registers. You can save the current region to a register with "C-x r s (character)" and recall it with "C-x r i (character)". You can actually do quite a bit of cool stuff with registers. They're pretty underutilized by most people.

    Burke Libbey

    August 8, 2008 at 10:37 am

  2. Welcome aboard. You'll find most of the features you miss are actually there (try "M-x speedbar" for example), and that Emacs crashes less often than the OS.


    August 8, 2008 at 10:53 am

  3. im a java developer so Im gonna comment from java standpoint as someone who used both emacs and eclipse for development: There is no way in hell that Im gonna give up conditional breakpoints, refactoring, instance searches within subsets of code, and so forth for the simplicity of emacs. The resource hog issues of big IDEs are easy to deal with by putting a couple more of cheap memory modules in your machines


    August 8, 2008 at 11:05 am

  4. Very cool, I haven't used registers I will have to look into them. Perhaps I will have to get a good Emacs book so I can just get up to speed on everything.


    August 8, 2008 at 12:12 pm

  5. Nice speedbar looks like it will make yet another disadvantage disappear.


    August 8, 2008 at 12:14 pm

  6. Yeah when I worked with Java, I was on eclipse and it was great. I think with dynamic languages many of those feature are not as important. The refactoring of Ruby code was pretty limited and didn't really work as well as Java refactoring tools. You can create conditional breakpoints in Ruby without eclipse. The searching is still annoying and I get your point there. If I was coding Java I think I would still be in an IDE.

    Also another thing to note is that NetBeans did run better on my desktop but since I am moving around so much now I code nearly all the time on my laptop which just doesn't have as much power to run the giant IDEs, getting some memory would help but I am poor… haha


    August 8, 2008 at 12:21 pm

  7. For Subversion integration, have you looked at vc-mode?

    M-; toggles comments on the region, and C-M- runs indent-region. Also, in general, M-x is probably easier than C-x C-m.

    Nathan Weizenbaum

    August 10, 2008 at 9:37 am

  8. Happy to see another ruby-mode user.
    Another option for subversion is psvn (, which I'm quite happy with. I must admit I miss netbeans'/IDEA's side-by-side diffs and svn notation in the fringe, but emacs colors the diffs nicely enough.

    For easy indenting, C-M- after marking a region. I tend to M-< M-> C-M- to reindent the whole file.

    For navigating, check out emacs-rails ( or the rinari project ( Rinari's find-file-in-project is at least as fast as netbeans' find file, but that might be damning by faint praise.

    Jacob Rothstein

    September 18, 2008 at 5:14 am

  9. I've used Emacs since I used Ruby and am still tweaking it to my liking. If you want an easy project search, I just started using ctags and *love* it. I can have the cursor on any method name, press C-Tab Enter and jump to the source file immediately. This even includes frozen Rails code.

    I setup the Rakefile to run every night to reindex my projects, just add the name and path to the List.

    Eric Davis

    September 24, 2008 at 1:50 pm

  10. […] you be a better developer. I am ignoring the entire topic of IDEs as tools, as I have written about Ruby IDEs before, and it is basically a religious war. If you use any Ruby tools I don’t mention be sure to […]

  11. C-M- Will comment any region too


    October 12, 2008 at 9:03 pm

  12. One question – were you using just the Ruby download or the full download? Ruby download should be pretty snappy.


    November 20, 2008 at 9:59 am

  13. Just the Ruby download


    November 20, 2008 at 10:02 am

  14. Hey Dave, do try out NetBeans 6.7 now – on a faster newer machine. NetBeans is admittedly slow and bloated (especially with the Java Runtime requirements). But if you've a fast enough machine, NetBeans for ROR should be god-sent.

    Also the Debugger has improved a lot – though I'm yet to get JavaScript debugging from within the IDE. But I hope that would get fixed by NetBeans 7.

    Jasim A Basheer

    November 18, 2009 at 1:29 pm

  15. “(You can turn them all off [in Netbeans], but I get annoyed having to go change a bunch of settings)”

    Since setting up Emacs the way you like doesn’t require any tinkering at all…

    Eric 'Siggy' Scott

    March 10, 2012 at 9:08 pm

Comments are closed.

%d bloggers like this: