aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--book/src/generated/lang-support.md1
-rw-r--r--languages.toml13
-rw-r--r--runtime/queries/task/highlights.scm4
-rw-r--r--runtime/queries/task/injections.scm2
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"))