-
-
Notifications
You must be signed in to change notification settings - Fork 2.5k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add support for Teal language #12081
base: master
Are you sure you want to change the base?
Conversation
@@ -1276,6 +1277,22 @@ language-servers = [ "lua-language-server" ] | |||
name = "lua" | |||
source = { git = "https://github.com/tree-sitter-grammars/tree-sitter-lua", rev = "88e446476a1e97a8724dff7a23e2d709855077f2" } | |||
|
|||
[[grammar]] | |||
name = "teal" | |||
source = { git = "https://github.com/euclidianAce/tree-sitter-teal", rev = "485fbdc00d811b01b2090dff4d0469fd1d0350f5" } |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
It looks like the tree-sitter-teal repo doesn't have a LICENSE yet. Could you propose adding one and update the commit here once one is merged?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Issue filed: euclidianAce/tree-sitter-teal#36. Though, I'm not sure how active is the maintainer, I hope it will be resolved soon.
runtime/queries/teal/highlights.scm
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
The captures in this file will need to be updated to use our capture names: https://docs.helix-editor.com/master/themes.html#syntax-highlighting
For example @boolean
should become @constant.character.boolean
, @parameter
should become @variable.parameter
runtime/queries/teal/locals.scm
Outdated
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
For the locals file we follow tree-sitter https://tree-sitter.github.io/tree-sitter/syntax-highlighting#local-variables
So only @local.definition
, @local.reference
and @local.scope
are allowed
I've updated |
Add basic support for Teal language.
Queries and grammar are from euclidianAce/tree-sitter-teal. Language server is tl/teal-language-server. I couldn't find a proper formatter.