how to open a grails 3.3 app in netbeans 9?

本秂侑毒 提交于 2019-12-20 07:32:35

问题


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?


回答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.

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

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



来源:https://stackoverflow.com/questions/52826163/how-to-open-a-grails-3-3-app-in-netbeans-9

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!