From a506683ccc75e25c9f906b0cd87c72879c4efacc Mon Sep 17 00:00:00 2001 From: Michael Davis Date: Thu, 2 Jun 2022 11:06:18 -0500 Subject: [PATCH] add tree-sitter-jsdoc --- book/src/generated/lang-support.md | 1 + languages.toml | 12 ++++++++++++ runtime/queries/jsdoc/highlights.scm | 2 ++ 3 files changed, 15 insertions(+) create mode 100644 runtime/queries/jsdoc/highlights.scm diff --git a/book/src/generated/lang-support.md b/book/src/generated/lang-support.md index 3f8bc0a4e6af..aa9fc1417eab 100644 --- a/book/src/generated/lang-support.md +++ b/book/src/generated/lang-support.md @@ -41,6 +41,7 @@ | iex | ✓ | | | | | java | ✓ | | | `jdtls` | | javascript | ✓ | | ✓ | `typescript-language-server` | +| jsdoc | ✓ | | | | | json | ✓ | | ✓ | `vscode-json-language-server` | | jsx | ✓ | | ✓ | `typescript-language-server` | | julia | ✓ | | | `julia` | diff --git a/languages.toml b/languages.toml index b29efc1995a0..1f42ddcc0049 100644 --- a/languages.toml +++ b/languages.toml @@ -1421,3 +1421,15 @@ indent = { tab-width = 4, unit = " " } [[grammar]] name = "edoc" source = { git = "https://github.com/the-mikedavis/tree-sitter-edoc", rev = "1691ec0aa7ad1ed9fa295590545f27e570d12d60" } + +[[language]] +name = "jsdoc" +scope = "source.jsdoc" +injection-regex = "jsdoc" +file-types = ["jsdoc"] +roots = [] +indent = { tab-width = 2, unit = " " } + +[[grammar]] +name = "jsdoc" +source = { git = "https://github.com/tree-sitter/tree-sitter-jsdoc", rev = "189a6a4829beb9cdbe837260653b4a3dfb0cc3db" } diff --git a/runtime/queries/jsdoc/highlights.scm b/runtime/queries/jsdoc/highlights.scm new file mode 100644 index 000000000000..4b4266c9fd1c --- /dev/null +++ b/runtime/queries/jsdoc/highlights.scm @@ -0,0 +1,2 @@ +(tag_name) @keyword +(type) @type