how to open a grails 3.3 app in netbeans 9?
Asked Answered
C

1

0

I cant find a way to open a grails 3.3.8 project in netbeans 9 on the mac.

I have found several posts (see below) but none of them work.

This one says create the project via the command line, e.g. "grails create-app hello", then use The "open project" dialog to open the hello directory. However, when I open the hello grails application directory, the project name field is greyed out, and hitting the open button has no effect.

This article says to create the project using the grails plugin for netbeans. It says to go the plugins dialog in netbeans and search for grails. There is no grails plugin.

grails and java are installed with the required exports. Note, I installed netbeans from https://github.com/carljmosca/netbeans-macos-bundle as recommended in the official netbeans install guide.

Suggestions anyone?

Couch answered 15/10, 2018 at 23:49 Comment(0)
C
1

Well, I found an obscure post which lead to the answer.

It seems that they removed most of the plugins from netbeans 9, including the grails one.

A work around (not sure how safe it is) is to add the netbeans 8.2 provider:

Go to Tools | Plugins in Apache NetBeans (incubating) 9.0 and, in the Settings tab, register the NetBeans IDE 8.2 update center:

http://updates.netbeans.org/netbeans/updates/8.2/uc/final/distribution/catalog.xml.gz

Thanks to: https://blogs.apache.org/netbeans/entry/what-s-happened-to-my

I can now open a grails project, but I cant run it. It says "Grails home has not been set. Use menu Tools/Options/Groovy to set the environment."

The problem is, I have already set GRIALS_HOME in my .bash_profile,and that there is no options under tools menu.

tools menu with no optoins

After some effort, I found the grails home setting in Netbeans Menu->preferences->Miscellaneous-Groovy:

enter image description here

Now I can run grails programs, and also use the menus to create domain objects etc. Nice!

Couch answered 16/10, 2018 at 0:3 Comment(3)
[1] Try Tools > Options > Miscellaneous > select the Groovy tab >**, then select the location of your Grails directory in the Grails Home field. You may need to click the Activate Groovy button on the Groovy tab before doing that. [2] Also see this answer to Why I can't create new grails application in Netbeans 8.2?.Calycle
In netbeans 9, when you click on the tools menu, there is no menu item for options, and no dialog with options. I guess they changed it. I eventually found it under Netbeans menu->preferences->Miscellanious tab. A lot of time was wasted.Couch
They didn't change anything with respect to Options. If NetBeans 9.0 is installed correctly there is definitely a menu entry named Options under Tools, and there is no entry named Preferences (which exists in Eclipse, but not in NetBeans). Can you post a screen shot of the menu entries in your Tools menu because if Options is missing and Preferences is present then something is very wrong with your installation of NetBeans 9.0.Calycle

© 2022 - 2024 — McMap. All rights reserved.