java VS Code 是否有针对 Apache Groovy 的语言扩展?

声明:本页面是StackOverFlow热门问题的中英对照翻译,遵循CC BY-SA 4.0协议,如果您需要使用它,必须同样遵循CC BY-SA许可,注明原文地址和作者信息,同时你必须将它归于原作者(不是我):StackOverFlow 原文地址: http://stackoverflow.com/questions/45538574/
Warning: these are provided under cc-by-sa 4.0 license. You are free to use/share it, But you must attribute it to the original authors (not me): StackOverFlow

提示:将鼠标放在中文语句上可以显示对应的英文。显示中英文
时间:2020-11-03 08:45:21  来源:igfitidea点击:

Does VS Code have language extension for Apache Groovy?

javagroovyvisual-studio-codetext-editor

提问by Sajuuk

Searching in extension store turned out nothing, but I found something in their master branch repo:

在扩展商店中搜索没有结果,但我在他们的主分支存储库中找到了一些东西:

https://github.com/Microsoft/vscode/tree/master/extensions/groovy

https://github.com/Microsoft/vscode/tree/master/extensions/groovy

But not quite sure if this is the extension that I want, if it is, do I just extract this into my .vscode/extensions/folder?

但不太确定这是否是我想要的扩展名,如果是,我是否只需将其解压缩到我的.vscode/extensions/文件夹中?

回答by Gama11

The extension you linked is built-in, meaning the Change Language Modecommand should already list Groovyfor you:

您链接的扩展是内置的,这意味着该Change Language Mode命令应该已经Groovy为您列出:

It provides syntax highlighting and snippets, see the "contributes" section of the package.json.

它提供语法高亮和片段,请参阅package.json.

However, I'm guessing you want something that provides more than just highlighting and snippets (i.e. completion). Interestingly enough, there doesappear to be a language server implementation for Groovy(found on langserver.org), but I couldn't find a matching VSCode extension. Documentation seems a bit lacking, but after searching the repo's issues for a bit, it seems like there's no VSCode integration yet:

但是,我猜您想要的不仅仅是突出显示和片段(即完成)。有趣的是,似乎确实Groovy语言服务器实现(在langserver.org找到),但我找不到匹配的 VSCode 扩展。文档似乎有点缺乏,但是在搜索了 repo 的问题之后,似乎还没有 VSCode 集成

It's not integrated with VS code yet. Currently we are using it with just Monaco and some glue code which is not open sourced.

它尚未与 VS 代码集成。目前我们只将它与 Monaco 和一些未开源的胶水代码一起使用。

In theory, VSCode integration shouldn't be too hard if the language server spec was followed. There's some documentation / examples on language server development here.

理论上,如果遵循语言服​​务器规范,VSCode 集成应该不会太难。有一个关于语言服务器开发的一些文档/例子在这里

回答by Alex Willian

This is a brand new extension that covers code snippet and find symbol. https://marketplace.visualstudio.com/items?itemName=marlon407.code-groovy

这是一个全新的扩展,涵盖代码片段和查找符号。https://marketplace.visualstudio.com/items?itemName=marlon407.code-groovy