Closed ShalokShalom closed 2 years ago
There are three things that are generally included in "support" for a particular language/interpreter:
There is moonscript plugin that implements 1 and 3. The debugging support is implemented using linemap
in MobDebug, so if Yuescript is using something similar, then it should be possible to integrate it the same way.
For syntax-highlighting someone can use the moonscript lexer and extend it to cover Yuescript syntax. The lexer can then be registered with editor.specmap
table to link a specific file extension to the Yuescript lexer.
It's also possible to package everything within one plugin (including the lexer) using ide:AddLexer
command.
I can help with any questions/issues that may arise, but you'd need to find someone to do and test this.
Well, 1 is already implemented, I guess, it simply compiles to Lua.
2 is not so different from Moon, it supports just a handful of new features (implicit objects, pipes etc)
3 Is not so important (to me)
To syntax-highlighting Yuescript files add this line in Settings: System
(Edit menu/Preferences):
ide.config.editor.specmap.yue = "moonscript"
and restart IDE
@billboardsDAO, thank you for the suggestion! Also, you can drop ide.config
, so editor.specmap.yue = "moonscript"
should work as well.
Can we make this default?
Pushed the change for it. @ShalokShalom, is that enough for you for now?
Thanks a lot
Hi @pkulchenko
Could you add the conf
extension (nginx/openresty) using css
syntax as default? It works well and helps :)
editor.specmap.conf = "css"
What does this change?
Yuescript is an extended and actively developed version of Moonscript
Is there any chance, to add support for it?