Skip to main content

Ruby development support advancing in NetBeans 6

As an outsider looking in it's difficult to determine when the time is right to try out new bleeding-edge NetBeans features. One new feature being developed for for NetBeans 6 is Ruby and Rails support. It doesn't come bundled with the latest milestone release (7). Instead you have to download it from the Update Center.

The Update Center modules are in a folder labeled 'Ruby'. With the Ruby modules NetBeans acquires the tools to create Ruby projects as well as create Rails projects that run on top of the Ruby tools. Unlike Eclipse's Ruby support, NetBeans uses JRuby entirely. There might be arguments as to which is better, but having tried both I see no advantage of one over the other. If there is any kind of advantage then it would be with NetBeans, since it can be installed and run without an external Ruby installation. But I can't imagine a Ruby developer not having a Ruby installation. Nor could I imagine a developer choosing JRuby over standard Ruby. JRuby is slower, and compared to the upcoming YARV, much, much slower. See "Ruby Implementations Shootout: Ruby vs Yarv vs JRuby vs Gardens Point Ruby .NET vs Rubinius vs Cardinal" for further details. I'd recommend that if you use NetBeans Ruby to develop and initially test, then deploy to regular Ruby to finish testing.

I also learned why Tor Norbye is called "a programming machine" and "epic". Yes. He is. I could not create a Rails project when I first installed the Ruby modules from the Update Center. So I sent an email to Charles Ditzel with a cry for help. Charles forwarded it to Tor. And Tor then replied back. We passed a number of emails between us, but in less than 12 hours Tor had solved the problem and provided a solution. It turned out that the update center modules were missing two files; activesupport-1.3.1.gemspec and activerecord-1.14.4.gemspec. Tor sent me the files, I dropped them where they were supposed to be, and bingo! Everything worked after that. There's even a bug (with fix) filed against the problem.

Here's a successful creation of a Rails application, and the automatic startup of WEBrick within the IDE running on OpenSuse 10.2.

Followed by the ubiquitous Rails stock web page.

Being an initial release running in a NetBeans milestone (essentially an alpha), there are some rough edges. But that's to be expected. I hope, as a user, I can provide quality feedback to make Ruby support as successful as I believe it can be. Far more valuable than the technology being developed are the people developing the technology. I've 'met' a lot of really great people lately as I've written about my various experiences with Suse, Ubuntu and NetBeans. Tor Norbye and Charles Ditzel are two more super folks. Thanks guys for all your help.

Comments

  1. Thank you so much for the compliments!

    One comment on JRuby: JRuby and Rails are bundled to give you a very nice and clean out-of-the-box experience. No fiddling with other installers, modifying PATH variables, etc. (Unfortunately as an early adopter it didn't work out that way for you - but it should be easier for everyone else now that most of the issues are resolved.)


    You can however use native ruby and rails if you want. You can modify it under Tools | Options (Preferences on the Mac) under Miscellaneous. There are apparently problems with this on Windows; there is some documentation of the issue
    here.


    On Linux it worked for me - but note that you have to restart after modifying the ruby pointer. See
    issue 89234 for more.

    Yes, I will try to make this more intuitive, something ala the Java Platform manager.

    ReplyDelete
  2. Performance is about to become the primary goal for JRuby development, so rest assured we're working on it. And of the benchmarks in that shootout, JRuby is already faster than MRI for the ones we can compile with our prototype compiler. Things should improve very quickly over the next two months.

    ReplyDelete
  3. Any change anyone else can get the two files need to make ruby work in netbeans?

    Dave

    ReplyDelete
  4. As a matter of fact Ruby language was created much earlier than even PHP, but it was used for the most part in Japan. The situation remained like this until Rails came in, owing to David Heinemeier Hansson. Combined Ruby language and Rails framework, or simply Ruby on Rails, have become a powerful and highly effective tool in developing web applications, used by programmers all around the globe. Moreover, Ruby has a great future as it's quite possible that in a few years other even better frameworks designed for it will appear. ruby on rails canada

    ReplyDelete

Post a Comment

All comments are checked. Comment SPAM will be blocked and deleted.

Popular posts from this blog

cat-in-a-box channels greta garbo

So I'm sitting at my computer, when I start to notice a racket in back. I ignore it for a while until I hear a load "thump!", as if something had been dropped on the floor, followed by a lot of loud rattling. I turn around and see Lucy in the box just having a grand old time, rolling around and rattling that box a good one. I grab the GX1 and snap a few shots before she notices me and the camera, then leaps out and back into her chair (which used to be my chair before she decided it was her chair).

Just like caring for Katie my black Lab taught me about dogs, caring for Lucy is teaching me about cats. She finds me fascinating, as I do her. And she expresses great affection and love toward me without coaxing. I try to return the affection and love, but she is a cat, and she takes a bat at me on occasion, although I think that's just her being playful. She always has her claws in when she does that.

She sits next to me during the evening in her chair while I sit in mi…

first night for the gingersnaps

The first night has passed and the two have managed to survive, in spite of what their tiny hearts might have thought when first arriving. Greebo, the larger of the two, has been in hiding the entire time so far. Ponder has spent the time zipping in and out of hiding spots, checking things out, and learning just how comfortable pillows are for resting your head.

During the night I felt the tiny body of Ponder hitting the bed as he leaped up on the side, and then climbed to the top to run around on top of me. At least once he play-attacked my fingers. He might be small but his claws are still quite sharp.

When I got up in the morning the bowl of cat kitten food was fairly well depleted. It's been refilled and fresh water put in the big dish on the floor. I'm assuming that both Greebo and Ponder are feeding and drinking. I have seen Greebo under the furniture peeking out at me when I went looking for him. I'm leaving him alone while he continues to adjust.

So far the guys h…

vm networking problem fixed

Over the weekend I upgraded to Windows 8.1, then discovered that networking for the virtual machines wouldn't work. Then I tried something incredibly simple and fixed the problem.

Checking the system I noticed that three VMware Windows services weren't running; VMnetDHCP, VMUSBArbService, and VMwareNatService. VMware Player allows you to install, remove, or fix an existing installation. I chose to try fixing the installation, and that fixed the problem. The services were re-installed/restarted, and the virtual machines had networking again.

Once network connectivity was established there was exactly one updated file for Ubuntu 13.10, a data file. This underscores how solid and finished the release was this time. Every other version of every other Linux installation I've ever dealt with has always been succeeded by boatloads of updates after the initial installation. But not this time.

Everything is working properly on my notebook. All's right with the world.