Try NetBeans v.6.7 (not the current production release 6.5) with the NetBeans Groovy/Grails plugin enabled. This is a nice clean IDE interface (easier to use than Eclipse IMHO), and you can set it up to integrate with your Grails installation. You can call all your Grails tasks from the IDE, edit your code, test and run your project. Then, if you want to format your code, you just right-click in the code editor and select "Format". Easy!
发布评论
评论(6)
尝试使用 NetBeans Groovy 来使用 NetBeans v.6.7(不是当前的生产版本 6.5) /Grails 插件已启用。 这是一个漂亮干净的 IDE 界面(恕我直言,比 Eclipse 更容易使用),您可以将其设置为与 Grails 安装集成。 您可以从 IDE 调用所有 Grails 任务、编辑代码、测试和运行项目。 然后,如果您想格式化代码,只需在代码编辑器中右键单击并选择“格式化”即可。 简单的!
Try NetBeans v.6.7 (not the current production release 6.5) with the NetBeans Groovy/Grails plugin enabled. This is a nice clean IDE interface (easier to use than Eclipse IMHO), and you can set it up to integrate with your Grails installation. You can call all your Grails tasks from the IDE, edit your code, test and run your project. Then, if you want to format your code, you just right-click in the code editor and select "Format". Easy!
我正在使用 VIM / GVIM 在 Groovy/Grails 中输入代码。 它有代码格式,我只需要告诉我的VIM groovy和java是相似的......
然后按gg = G [enter](从上到下的格式)
I am using VIM / GVIM for typing code in Groovy/Grails. it has code formatting, I just need to tell my VIM that groovy and java are similar....
and then press gg = G [enter] (format from top to bottom)
为此,此线程推荐了一个工具。 我没有尝试过,但也许值得一看。
There is a tool recommended in this thread for this purpose. I have not tried it but maybe worth a look.
以下是关于如何让 Grails 与 NetBean 一起工作的一些说明(无法在我的网站中提交第二个 URL)最后一篇文章)。
Here's some instructions on how to get Grails working with NetBeans (couldn't submit the second URL in my last post).
groovy eclipse 插件在格式化 groovy 代码方面做得很好。 sts 可能对某些 grails 代码更聪明。
the groovy eclipse plugin does a decent job of formatting groovy code. sts might be smarter about some of the grails code.
您可以在命令行中使用 npm-groovy-lint,在 Visual Studio Code IDE 中使用 VsCode Groovy Lint :)
https://www.npmjs.com/package/npm-groovy-lint
https://marketplace.visualstudio.com/items?itemName=NicolasVuillamy.vscode-groovy-lint
You can use npm-groovy-lint for command line, and VsCode Groovy Lint in Visual Studio Code IDE :)
https://www.npmjs.com/package/npm-groovy-lint
https://marketplace.visualstudio.com/items?itemName=NicolasVuillamy.vscode-groovy-lint