mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-18 11:20:07 -04:00
feat: add groovy support
This commit is contained in:
parent
bad9f5bf5b
commit
016cba16a0
3 changed files with 61 additions and 0 deletions
|
|
@ -603,6 +603,15 @@ list.gowork = {
|
||||||
maintainers = { "@omertuc" },
|
maintainers = { "@omertuc" },
|
||||||
}
|
}
|
||||||
|
|
||||||
|
list.groovy = {
|
||||||
|
install_info = {
|
||||||
|
url = "https://github.com/Decodetalkers/tree-sitter-groovy",
|
||||||
|
files = { "src/parser.c" },
|
||||||
|
branch = "gh-pages",
|
||||||
|
},
|
||||||
|
maintainers = { "@Decodetalkers" },
|
||||||
|
}
|
||||||
|
|
||||||
list.graphql = {
|
list.graphql = {
|
||||||
install_info = {
|
install_info = {
|
||||||
url = "https://github.com/bkegley/tree-sitter-graphql",
|
url = "https://github.com/bkegley/tree-sitter-graphql",
|
||||||
|
|
|
||||||
51
queries/groovy/highlights.scm
Normal file
51
queries/groovy/highlights.scm
Normal file
|
|
@ -0,0 +1,51 @@
|
||||||
|
(unit
|
||||||
|
(identifier) @variable)
|
||||||
|
(string
|
||||||
|
(identifier) @variable)
|
||||||
|
|
||||||
|
(escape_sequence) @string.escape
|
||||||
|
|
||||||
|
(block
|
||||||
|
(unit
|
||||||
|
(identifier) @namespace))
|
||||||
|
|
||||||
|
(func
|
||||||
|
(identifier) @function)
|
||||||
|
|
||||||
|
(number) @number
|
||||||
|
|
||||||
|
((identifier) @boolean
|
||||||
|
(#any-of? @boolean "true" "false" "True" "False"))
|
||||||
|
|
||||||
|
((identifier) @constant
|
||||||
|
(#lua-match? @constant "^[A-Z][A-Z%d_]*$"))
|
||||||
|
|
||||||
|
((identifier) @type.definition
|
||||||
|
(#any-of? @type.definition
|
||||||
|
"string"
|
||||||
|
"String"
|
||||||
|
"void"
|
||||||
|
"id"
|
||||||
|
"version"
|
||||||
|
"apply"
|
||||||
|
"implementation"
|
||||||
|
"testImplementation"
|
||||||
|
"androidTestImplementation"
|
||||||
|
"debugImplementation"))
|
||||||
|
|
||||||
|
((identifier) @keyword
|
||||||
|
(#any-of? @keyword
|
||||||
|
"static"
|
||||||
|
"class"
|
||||||
|
"def"
|
||||||
|
"import"
|
||||||
|
"new"))
|
||||||
|
|
||||||
|
(string) @string
|
||||||
|
|
||||||
|
(comment) @comment
|
||||||
|
|
||||||
|
(operators) @operator
|
||||||
|
(leading_key) @operator
|
||||||
|
|
||||||
|
["(" ")" "[" "]" "{" "}"] @punctuation.bracket
|
||||||
1
queries/groovy/injections.scm
Normal file
1
queries/groovy/injections.scm
Normal file
|
|
@ -0,0 +1 @@
|
||||||
|
(comment) @comment
|
||||||
Loading…
Add table
Add a link
Reference in a new issue