tree-sitter-d2/README.md

37 lines
694 B
Markdown
Raw Normal View History

2022-12-08 01:57:24 +03:00
# tree-sitter-d2
d2 grammar for tree-sitter.
2022-12-08 02:22:58 +03:00
References:
2022-12-08 02:22:58 +03:00
- https://d2lang.com/
## Highlights
2023-06-16 01:42:08 +03:00
![screenshot_1](./assets/screenshot_1.png)
![screenshot_2](./assets/screenshot_2.png)
2022-12-08 02:22:58 +03:00
# Install
## Neovim
Using `nvim-treesitter`, add to your configuration
```lua
local parser_config = require("nvim-treesitter.parsers").get_parser_configs()
parser_config.d2 = {
install_info = {
url = 'https://git.pleshevski.ru/pleshevskiy/tree-sitter-d2',
revision = 'main',
files = { 'src/parser.c', 'src/scanner.cc' },
},
filetype = 'd2',
};
```
2023-06-15 12:09:18 +03:00
# Mirrors
- [Git Pleshevski](https://git.pleshevski.ru/pleshevskiy/tree-sitter-d2)
- [Codeberg](https://codeberg.org/p8i/tree-sitter-d2)