Ruby and Ruby on Rails

Ruby and Rails development in the NetBeans IDE
Click image for fullscreen preview

NOTE: As of NetBeans IDE 7.0, support for Ruby and Ruby on Rails is no longer available in the standard NetBeans IDE build. Please see the Ruby Support Wiki page for more information.

Ruby Source Code Editor

The editor indents, completes, and highlights your Ruby code syntactically as well as semantically. It assists you with rename refactoring, type inference, and navigation. The editor parses your code live as you type, so it can match words and brackets, mark errors and occurrences, and display new quick fixes and RDoc. With a few keystrokes you insert commonly used code snippets from live templates.

ruby editor

Ruby Projects

The Ruby project type supports Ruby files, RSpec specification files, and YAML files. Use the Ruby Platform manager to choose between executing projects using JRuby, or any other native Ruby interpreter on your system.

The IDE has Rake build tool integration and gives you access to the Interactive Ruby Shell (IRB). Refactoring and support for Test::Unit, Auto Test, Shoulda tests, and RSpec are well integrated. You can also track hints and errors in the task list.

Ruby on Rails Projects

The Ruby on Rails project type supports Rake targets and database migrations. The Rake Runner dialog keeps a list of the previously entered parameters and automatically populates the list of parameters for migrate and fixtures tasks. You can generate Rails 3 projects, or generate code through the Rails code generator graphical wizard. The logical project view clearly separates controllers from models, views, and database migrations.

Edit ERB files and deploy projects directly to the WEBrick and Mongrel web servers. You can jump quickly between a Rails action and its corresponding view, and warp to the browser for the URL most relevant to the file you are editing.

Ruby and Rails Debugger

Single-step or run through Ruby code and ERB files. Set breakpoints, look at local variables, navigate the call stack, switch threads. Hover the mouse over a variable in the Editor to evaluate the expressions and show it in a tooltip. The NetBeans IDE supports the Fast Ruby Debugger, which also works with JRuby. You can debug Ruby files that are not part of a NetBeans project, or attach the debugger to any remote process started from the command line, and get all the advantages of a user-friendly debugger frontend.

ruby testing

ruby files

rails generator

ruby debugger

Ruby Gems Installation Manager

Extend your Ruby installation using the integrated Ruby Gems packaging system. You can configure $GEM_PATH or $GEM_HOME using the Gems installation manager. Add and manage freely available Ruby software libraries, and distribute your own packages. The Gem Manager even allows you to uninstall a certain version of a gem.

If you install the Bundler gem, you can run Bundler actions from the project context menu.


- The Ruby Wiki

- Ruby Support Wiki

ruby gems manager