From fd4858c03d5457872408bef3e58305c9233e78fc Mon Sep 17 00:00:00 2001 From: Michael Davis Date: Thu, 2 Jun 2022 23:56:47 -0500 Subject: [PATCH] add tree-sitter-jsdoc (#2650) --- 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 3f8bc0a4e..aa9fc1417 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 b29efc199..1f42ddcc0 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 000000000..4b4266c9f --- /dev/null +++ b/runtime/queries/jsdoc/highlights.scm @@ -0,0 +1,2 @@ +(tag_name) @keyword +(type) @type