• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

best IDEs, editors for Groovy/Grails?

 
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Scott and others - any input on which IDEs or editors are best for Groovy and Grails? What do you use? I know IntelliJ has a plugin which I've jsut downloaded, and I'm pretty sure there's one for Eclipse. Any preferences?
 
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I've used the IDEA plugin and while the groovy bits work well its been hit and miss with the grails plugin. I can't think of any specifics off the top of my head and it's been a few months since I've looked at it but I just remember having issues with many of the features like kicking off generator scripts and what not.
 
Jim Yingst
Wanderer
Posts: 18671
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thanks, Gregg.

A related question I'd add: for Java, we (here at JavaRanch at least) usually recommend that people first learn the basics without an IDE, because it hides too many details that you really should learn. Do Scott and others think that anything like that hold true for Groovy/Grails?
 
author
Posts: 77
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Forgive me for jumping in, but I also use IDEA with the JetGroovy plugin and it is working very well for both Groovy and Grails. Some of the generate scripts were not directly supported in earlier releases but they are in the latest. Even then it was easy to jump out to a shell and run those scripts.

The syntax highlighting, code completion (to an extent), refactoring and debugging are a huge productivity boost but the IDE does not really do anything for you that you would need to learn to do yourself. Much of what Java IDEs do in that regard is boilerplate code. And I agree that when you need to work with that stuff yourself and you're used to your IDE doing it you can get stuck. But with Groovy and Grails there is so much less boiler plate code so that issue all but goes away.

Just another POV,
Dave
 
Gregg Bolinger
Ranch Hand
Posts: 15304
6
Mac OS X IntelliJ IDE Chrome
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
I started playing around with Spring's Scripting support using Groovy tonight so I got to use the plugin quite a bit while creating my Groovy code. Just some notes:
  • When you try and use a class in a groovy file that needs to be imported you don't get the normal notification. You can still alt+enter on the class and then you get prompted for the correct action but auto import on alt+enter is no longer available.
  • When creating a new groovy file if you choose script, even though you are in a package, the package statement is not generated for you. If you tell IDEA you want to create a Groovy class then all is well. This isn't good or bad. Just something to be aware of.
  • Autocompletion is so-so. Yes, I am aware that Groovy is somewhat of a dynamic language however something as simple as accessor methods, IDEA should be aware those are automatically available and allow autocompletion for you. On the other hand it does autocomplete for message.message and since in Groovy that is the same as message.getMessage() I suppose its fine. But I still think IDEA should be smart enough to know that getMessage() is available.
  • I can't find a way to tell IDEA to execute scripts as scripts. IDEA compiles them to bytecode prior to executing. Is this a big deal? Probably not and the code executes faster but seems unnecessary if I could turn it off.


  • That's all I came up with so far. If I find anything else I will post it here.
    [ February 19, 2008: Message edited by: Gregg Bolinger ]
     
    Gregg Bolinger
    Ranch Hand
    Posts: 15304
    6
    Mac OS X IntelliJ IDE Chrome
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
  • I created a class in a package and I needed to move it to a different package. I used IDEA's refactor and moved it to the new package however the package declaration in the groovy file didn't update to reflect its new home.

  •  
    Gregg Bolinger
    Ranch Hand
    Posts: 15304
    6
    Mac OS X IntelliJ IDE Chrome
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
  • When implemeting an interface or extending an abstract class with abstract methods, IDEA doesn't warn you about required methods that need to be implemented. You can still alt+insert to see what needs to be done but until you compile/run your groovy code you won't know about it.
  •  
    Ranch Hand
    Posts: 883
    3
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    How about a good plug-in for NetBeans or Eclipse. Mostly I'm looking for a worthwhile debugger.

    I tried one a few months ago (Coyote, I think) and I could set a breakpoint in Java code that was executing a Groovy script and step into the Groovy code, but it didn't let me set a breakpoint in the Groovy code itself - which is very frustrating.

    Any recommendations for either browser are welcome. Thanks!
     
    Ranch Hand
    Posts: 959
    Eclipse IDE Java Linux
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    Yeah, I'm also looking for a good plugin for NetBeans. I know there's one out there, but so far it only does some simple syntax checking and some other simple stuff without any Grails support. Hopefully the NetBeans team has already had a plan to build this plugin.
     
    Greenhorn
    Posts: 1
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    Neither NetBeans nor Eclipse are not there yet as far as the Groovy support is concerned. With all the buzz around Groovy and Grails, shouldn't be long before we see very good groovy support from these IDEs
     
    Ranch Hand
    Posts: 43
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    Does anybody know if there is a JDE equivalent package for Emacs for Groovy/Grails?
     
    Greenhorn
    Posts: 4
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    I don't use netbeans at all until it becomes a little more flexible on project layouts.

    Eclipse is my main IDE at work (we have Rational App Dev licenses, but it stinks). Groovy support in eclipse is poor. It is difficult to get the groovy plugin to pickup GSP files. There is no source formatting, completion is hit or miss but syntax highlighting does seem to work ok. I really miss the source formatting.

    I have used Idea 7 with Groovy and Grails. As Dave Klein mentioned, JetGroovy is working pretty well in the current release. It's a little awkward to run the generate scripts in idea. Having a terminal handy is still really helpful.

    I found TextMate (Mac-Only) to be one of the best interfaces to work with Ruby on Rails, and there are some textmate bundles for groovy. Groovy TextMate Bundle I imagine the grails support would work similar to RoR. TextMate's appeal, from what I can tell, is that it closely ties the file system and the editor. At least it feels a little more intuitive.

    Disclaimer: my experience is based on a few weeks of trial use for Idea and TextMate. I still use a terminal with vi. If I did purchase an IDE, it would probably be Idea (I feel a little guilty for being a huge fan but not budgeting for this). Honestly, I put my fun money towards books and a good computer every few years, for now.
     
    Greenhorn
    Posts: 8
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    I use Eclise and Vi for all my code/text editing.

    Groovy eclipse plug-in is not that great. When editing, I am all on my own. Is anybody aware of any vi/vim based utility for groovy/grails?

    Regards,

    -Deepak
     
    Ranch Hand
    Posts: 156
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    Personally I've been using gedit under linux and I'm loving it. Create some custom snippets and its a beautiful thing!

    I blogged about how to set it all up, but if you want that info, ask me...I don't want to post the URL in hear for fear of "spamming" ya'll.
     
    Greenhorn
    Posts: 5
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator
    I've used all three. Eclipse is my main workhorse for normal Java development and is my favorite IDE. I have a license for IDEA and was excited to use it for Grails/Groovy development - but I find it to be sluggish.
    However, I'd been playing around with Netbeans for a while as it's Javascript editor is awesome. Netbeans 6.5 includes better groovy/grails support and I've been using it for a couple of days. Earlier releases did not have a stable or usable groovy/grails plugin, but this latest version (I d/l nightly of NB6.5) shows great promise and is actually usable.
    Another poster commented that 'you don't really need all them fancy features when working with Groovy' - I can't agree more. Once we get to a certain level of proficiency with Groovy, all you really need is a good editor and a shell.
    [ July 06, 2008: Message edited by: Pratik R Patel ]
     
    Ranch Hand
    Posts: 163
    • Mark post as helpful
    • send pies
      Number of slices to send:
      Optional 'thank-you' note:
    • Quote
    • Report post to moderator

    Originally posted by Pratik R Patel:
    I have a license for IDEA and was excited to use it for Grails/Groovy development - but I find it to be sluggish.
    [ July 06, 2008: Message edited by: Pratik R Patel ]



    I'm not sure what sluggish looks like. I'm running the Groovy/Grails plug in using IntelliJ 7.0.3 and it's anything but sluggish. The integration between Groovy, Java, Spring, and Hibernate is fantastic.

    %
    reply
      Bookmark Topic Watch Topic
    • New Topic