mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-01 19:17:02 -04:00
Add turtle
This commit is contained in:
parent
bc4019f4be
commit
a0f03ec333
6 changed files with 94 additions and 0 deletions
|
|
@ -172,6 +172,7 @@ We are looking for maintainers to add more parsers and to write query files for
|
|||
- [x] [teal](https://github.com/euclidianAce/tree-sitter-teal) (maintained by @euclidianAce)
|
||||
- [x] [toml](https://github.com/ikatyang/tree-sitter-toml) (maintained by @tk-shirasaka)
|
||||
- [ ] [tsx](https://github.com/tree-sitter/tree-sitter-typescript)
|
||||
- [x] [turtle](https://github.com/BonaBeavis/tree-sitter-turtle) (maintained by @bonabeavis)
|
||||
- [x] [typescript](https://github.com/tree-sitter/tree-sitter-typescript) (maintained by @steelsojka)
|
||||
- [x] [verilog](https://github.com/tree-sitter/tree-sitter-verilog) (maintained by @zegervdv)
|
||||
- [ ] [vue](https://github.com/ikatyang/tree-sitter-vue)
|
||||
|
|
|
|||
|
|
@ -399,6 +399,15 @@ list.gdscript = {
|
|||
maintainers = {"not @tjdevries"},
|
||||
}
|
||||
|
||||
list.turtle = {
|
||||
install_info = {
|
||||
url = "https://github.com/BonaBeavis/tree-sitter-turtle",
|
||||
files = { "src/parser.c" },
|
||||
branch = "main",
|
||||
},
|
||||
maintainers = { "@bonabeavis" },
|
||||
}
|
||||
|
||||
local M = {
|
||||
list = list
|
||||
}
|
||||
|
|
|
|||
4
queries/turtle/folds.scm
Normal file
4
queries/turtle/folds.scm
Normal file
|
|
@ -0,0 +1,4 @@
|
|||
[
|
||||
(statement)
|
||||
(blank_node_property_list)
|
||||
] @fold
|
||||
58
queries/turtle/highlights.scm
Normal file
58
queries/turtle/highlights.scm
Normal file
|
|
@ -0,0 +1,58 @@
|
|||
(string) @string
|
||||
|
||||
(lang_tag) @type
|
||||
|
||||
[
|
||||
"_:"
|
||||
"<"
|
||||
">"
|
||||
(namespace)
|
||||
] @namespace
|
||||
|
||||
[
|
||||
(iri_reference)
|
||||
(prefixed_name)
|
||||
] @variable
|
||||
|
||||
(blank_node_label) @variable
|
||||
|
||||
"a" @variable.builtin
|
||||
|
||||
(integer) @number
|
||||
|
||||
[
|
||||
(decimal)
|
||||
(double)
|
||||
] @float
|
||||
|
||||
(boolean_literal) @boolean
|
||||
|
||||
[
|
||||
"BASE"
|
||||
"PREFIX"
|
||||
"@prefix"
|
||||
"@base"
|
||||
] @keyword
|
||||
|
||||
[
|
||||
"."
|
||||
","
|
||||
";"
|
||||
] @punctuation.delimiter
|
||||
|
||||
[
|
||||
"("
|
||||
")"
|
||||
"["
|
||||
"]"
|
||||
(anon)
|
||||
] @punctuation.bracket
|
||||
|
||||
(comment) @comment
|
||||
|
||||
(echar) @string.escape
|
||||
|
||||
|
||||
(rdf_literal
|
||||
"^^" @type
|
||||
datatype: (_ ["<" ">" (namespace)] @type) @type)
|
||||
10
queries/turtle/indents.scm
Normal file
10
queries/turtle/indents.scm
Normal file
|
|
@ -0,0 +1,10 @@
|
|||
[
|
||||
(statement)
|
||||
(blank_node_property_list)
|
||||
(collection)
|
||||
] @indent
|
||||
[
|
||||
"]"
|
||||
")"
|
||||
] @branch
|
||||
|
||||
12
queries/turtle/locals.scm
Normal file
12
queries/turtle/locals.scm
Normal file
|
|
@ -0,0 +1,12 @@
|
|||
(turtle_doc) @scope
|
||||
|
||||
(subject
|
||||
[
|
||||
(prefixed_name)
|
||||
(iri_reference)
|
||||
] @definition.var)
|
||||
|
||||
[
|
||||
(prefixed_name)
|
||||
(iri_reference)
|
||||
] @reference
|
||||
Loading…
Add table
Add a link
Reference in a new issue