mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-01 19:17:02 -04:00
Add tree-sitter-dot (#1770)
* Add tree-sitter-dot * Fix DOT highlights * highlights(DOT): add HTML string * Remove DOT ftdetect Vim and Neovim runtime have added DOT filetype detection * Update DOT highlights
This commit is contained in:
parent
34de06d4e8
commit
f900e5dfc8
4 changed files with 56 additions and 0 deletions
|
|
@ -159,6 +159,7 @@ We are looking for maintainers to add more parsers and to write query files for
|
|||
- [x] [dart](https://github.com/UserNobody14/tree-sitter-dart) (maintained by @Akin909)
|
||||
- [x] [devicetree](https://github.com/joelspadin/tree-sitter-devicetree) (maintained by @jedrzejboczar)
|
||||
- [x] [dockerfile](https://github.com/camdencheek/tree-sitter-dockerfile) (maintained by @camdencheek)
|
||||
- [x] [DOT](https://github.com/rydesun/tree-sitter-dot) (maintained by @rydesun)
|
||||
- [x] [elixir](https://github.com/ananthakumaran/tree-sitter-elixir) (maintained by @nifoc)
|
||||
- [ ] [elm](https://github.com/elm-tooling/tree-sitter-elm)
|
||||
- [x] [erlang](https://github.com/AbstractMachinesLab/tree-sitter-erlang) (maintained by @ostera)
|
||||
|
|
|
|||
|
|
@ -94,6 +94,15 @@ list.dockerfile = {
|
|||
maintainers = { "@camdencheek" },
|
||||
}
|
||||
|
||||
list.dot = {
|
||||
install_info = {
|
||||
url = "https://github.com/rydesun/tree-sitter-dot",
|
||||
branch = "main",
|
||||
files = { "src/parser.c" },
|
||||
},
|
||||
maintainers = { "@rydesun" },
|
||||
}
|
||||
|
||||
list.rust = {
|
||||
install_info = {
|
||||
url = "https://github.com/tree-sitter/tree-sitter-rust",
|
||||
|
|
|
|||
45
queries/dot/highlights.scm
Normal file
45
queries/dot/highlights.scm
Normal file
|
|
@ -0,0 +1,45 @@
|
|||
(identifier) @type
|
||||
(keyword) @keyword
|
||||
(string_literal) @string
|
||||
(number_literal) @number
|
||||
|
||||
[
|
||||
(edgeop)
|
||||
(operator)
|
||||
] @operator
|
||||
|
||||
[
|
||||
","
|
||||
";"
|
||||
] @punctuation.delimiter
|
||||
|
||||
[
|
||||
"{"
|
||||
"}"
|
||||
"["
|
||||
"]"
|
||||
"<"
|
||||
">"
|
||||
] @punctuation.bracket
|
||||
|
||||
(subgraph
|
||||
id: (id
|
||||
(identifier) @namespace)
|
||||
)
|
||||
|
||||
(attribute
|
||||
name: (id
|
||||
(identifier) @field)
|
||||
)
|
||||
|
||||
(attribute
|
||||
value: (id
|
||||
(identifier) @constant)
|
||||
)
|
||||
|
||||
[
|
||||
(comment)
|
||||
(preproc)
|
||||
] @comment
|
||||
|
||||
(ERROR) @error
|
||||
1
queries/dot/injections.scm
Normal file
1
queries/dot/injections.scm
Normal file
|
|
@ -0,0 +1 @@
|
|||
(html_internal) @html
|
||||
Loading…
Add table
Add a link
Reference in a new issue