Unnamed repository; edit this file 'description' to name the repository.
-rw-r--r--runtime/queries/tolk/indents.scm24
-rw-r--r--runtime/queries/tolk/injections.scm3
2 files changed, 27 insertions, 0 deletions
diff --git a/runtime/queries/tolk/indents.scm b/runtime/queries/tolk/indents.scm
new file mode 100644
index 00000000..cc094127
--- /dev/null
+++ b/runtime/queries/tolk/indents.scm
@@ -0,0 +1,24 @@
+; indent
+; ------
+
+[
+ (block_statement)
+ (match_expression)
+ (struct_declaration)
+ (object_literal)
+] @indent
+
+; outdent
+; -------
+
+[
+ "}"
+ ")"
+ ">"
+] @outdent
+
+; indent.always
+; outdent.always
+; align
+; extend
+; extend.prevent-once
diff --git a/runtime/queries/tolk/injections.scm b/runtime/queries/tolk/injections.scm
new file mode 100644
index 00000000..8dc19181
--- /dev/null
+++ b/runtime/queries/tolk/injections.scm
@@ -0,0 +1,3 @@
+((comment) @injection.content
+ (#set! injection.language "comment")
+ (#match? @injection.content "^//"))