向 NetBeans 中的 .less 文件添加语法突出显示
我想让带有 .less 扩展名的文件在 NetBeans 中使用 CSS 语法突出显示,但我不知道如何执行此操作。
我发现了一种相当耗时的方法来做到这一点(http://netbeans.dzone. com/tips/quickstart-guide-language-supp),但我突然意识到这一定是更简单的方法。
有人知道吗?
I want to have files with a .less extension use the CSS syntax highlighting in NetBeans, and I don't have any clue how to do this.
I found a rather time consuming way to do this (http://netbeans.dzone.com/tips/quickstart-guide-language-supp), but it hit me that it must be easier way to do this.
Anyone knows?
如果你对这篇内容有疑问,欢迎到本站社区发帖提问 参与讨论,获取更多帮助,或者扫码二维码加入 Web 技术交流群。
绑定邮箱获取回复消息
由于您还没有绑定你的真实邮箱,如果其他用户或者作者回复了您的评论,将不能在第一时间通知您!
发布评论
评论(5)
您只需在 Netbeans > 中添加新的文件类型即可工具>选项>杂项>文件。请注意,Netbeans 会将一些较少的功能(例如变量等)标记为错误
You just have to add a new file type in Netbeans > Tools > Options > Miscellaneous > Files. Note that Netbeans will mark as errors some less features like variables...etc
可以从以下页面下载添加完整较少突出显示支持的模块:
http://plugins.netbeans.org/plugin/32782/lesscss-module
我测试了该模块netbeans 7.0 运行完美。
a module which adds full less highlighting support can be downloaded from the following page:
http://plugins.netbeans.org/plugin/32782/lesscss-module
i tested the module with netbeans 7.0 and it worked flawless.
您可以尝试已经提到的插件的新版本:
http://plugins.netbeans.org/plugin/41315/lesscss-module
GitHub 存储库现已消失,可在以下位置找到:
https://github.com/khairie/lesscss-module
对我来说,它似乎很有效尽管着色上有一些小错误,但还不错。但它缺少一些功能,例如不提供自动格式化功能。
请注意,NetBeans 开发版本中已添加对 Sassy CSS 和 LESS CSS 预处理器文件的基本编辑支持:
http://wiki.netbeans.org/NewAndNoteWorthy
You might try out the new version of the plugin that was already mentioned:
http://plugins.netbeans.org/plugin/41315/lesscss-module
GitHub repository, now gone, was available at:
https://github.com/khairie/lesscss-module
For me it seems to work quite fine despite some minor bugs in coloring. It is missing some features and e.g. does not offer automatic formatting, though.
Note that basic editing support for Sassy CSS and LESS CSS preprocessor files has been added to NetBeans dev build:
http://wiki.netbeans.org/NewAndNoteWorthy
SCSS 支持插件 也适用于 less 文件,只需添加“less “工具/选项/杂项/文件中带有 text/x-scss MIME 的文件扩展名。
The SCSS Support plugin also works with less files, just need to add the "less" file extension with text/x-scss MIME in Tools/Options/Miscellaneous/Files.
自 Netbeans 7.4 起,Netbeans 支持的版本较少,无需额外的插件。
对于旧版本的 Netbeans,有两个插件:
http://plugins.netbeans.org/plugin/32782/lesscss-module
和 http://plugins.netbeans.org/plugin/41315/lesscss-module
Since Netbeans 7.4 less is supported by Netbeans without the need for an additional plugin.
For older version of Netbeans there are two plugins:
http://plugins.netbeans.org/plugin/32782/lesscss-module
and http://plugins.netbeans.org/plugin/41315/lesscss-module