diff options
author | Alexander Brevig | 2022-08-20 00:16:54 +0000 |
---|---|---|
committer | GitHub | 2022-08-20 00:16:54 +0000 |
commit | aef00a3ab640417f06dc9f59938283ffde5c451e (patch) | |
tree | 97a96614b4349ede9cb12dffc0cbaec6f1fdbd1a | |
parent | 9b0fd51318202c97d1206a02bc9b0dfe95762e8a (diff) |
feat: add taskwarrior to languages so `task N edit` is nice (#3468)
Co-authored-by: Michael Davis <mcarsondavis@gmail.com>
-rw-r--r-- | book/src/generated/lang-support.md | 1 | ||||
-rw-r--r-- | languages.toml | 13 | ||||
-rw-r--r-- | runtime/queries/task/highlights.scm | 4 | ||||
-rw-r--r-- | runtime/queries/task/injections.scm | 2 |
4 files changed, 20 insertions, 0 deletions
diff --git a/book/src/generated/lang-support.md b/book/src/generated/lang-support.md index 941b7a7a..e9ef56cf 100644 --- a/book/src/generated/lang-support.md +++ b/book/src/generated/lang-support.md @@ -99,6 +99,7 @@ | svelte | ✓ | | ✓ | `svelteserver` | | swift | ✓ | | | `sourcekit-lsp` | | tablegen | ✓ | ✓ | ✓ | | +| task | ✓ | | | | | tfvars | | | | `terraform-ls` | | toml | ✓ | | | `taplo` | | tsq | ✓ | | | | diff --git a/languages.toml b/languages.toml index 056fb9fa..eb4cc5d8 100644 --- a/languages.toml +++ b/languages.toml @@ -1640,3 +1640,16 @@ language-server = { command = "slint-lsp", args = [] } [[grammar]] name = "slint" source = { git = "https://github.com/jrmoulton/tree-sitter-slint", rev = "0d4dda94f96623302dfc234e06be62a5717f47da" } + +[[language]] +name = "task" +scope = "source.task" +injection-regex = "task" +file-types = ["task"] +roots = [] +comment-token = "#" +indent = { tab-width = 2, unit = " " } + +[[grammar]] +name = "task" +source = { git = "https://github.com/alexanderbrevig/tree-sitter-task", rev = "f2cb435c5dbf3ee19493e224485d977cb2d36d8b" } diff --git a/runtime/queries/task/highlights.scm b/runtime/queries/task/highlights.scm new file mode 100644 index 00000000..90441307 --- /dev/null +++ b/runtime/queries/task/highlights.scm @@ -0,0 +1,4 @@ +(comment) @comment +(datetime) @type +(identifier) @variable +(keyword) @keyword diff --git a/runtime/queries/task/injections.scm b/runtime/queries/task/injections.scm new file mode 100644 index 00000000..321c90ad --- /dev/null +++ b/runtime/queries/task/injections.scm @@ -0,0 +1,2 @@ +((comment) @injection.content + (#set! injection.language "comment")) |