aboutsummaryrefslogtreecommitdiff
path: root/runtime/queries/git-commit
diff options
context:
space:
mode:
authorMichael Davis2021-12-30 22:58:47 +0000
committerGitHub2021-12-30 22:58:47 +0000
commit8fda87af2bb0625c502a23ddbd78a7447ada7bcb (patch)
tree62a9f9a0cdd007bb3de78b7a153fcf8d00b8de84 /runtime/queries/git-commit
parenta066f59dc87608935ef4a3a3df3edf180c809e11 (diff)
add tree-sitter-git-rebase (#1402)
* add submodule on tree-sitter-rebase, add to languages * add basic highlights query * inject bash in execute statements * update tree-sitter-rebase * tree-sitter-rebase->tree-sitter-git-rebase * get injection working with tree-sitter-git-commit * set scope under source.gitrebase * unset include-children on commit message injections * Revert "unset include-children on commit message injections" This reverts commit 2ecee155ea8e229651920b291062c2ee84b47944. * fix generated language docs * use rebase_command scopes from tree-sitter-git-commit
Diffstat (limited to 'runtime/queries/git-commit')
-rw-r--r--runtime/queries/git-commit/highlights.scm1
-rw-r--r--runtime/queries/git-commit/injections.scm8
2 files changed, 3 insertions, 6 deletions
diff --git a/runtime/queries/git-commit/highlights.scm b/runtime/queries/git-commit/highlights.scm
index ffcc31ae..0b50d419 100644
--- a/runtime/queries/git-commit/highlights.scm
+++ b/runtime/queries/git-commit/highlights.scm
@@ -4,7 +4,6 @@
(commit) @constant
(item) @markup.link.url
(header) @tag
-(rebase_command) @markup.raw
(change kind: "new file" @diff.plus)
(change kind: "deleted" @diff.minus)
diff --git a/runtime/queries/git-commit/injections.scm b/runtime/queries/git-commit/injections.scm
index bd96f1de..cf0657f7 100644
--- a/runtime/queries/git-commit/injections.scm
+++ b/runtime/queries/git-commit/injections.scm
@@ -3,8 +3,6 @@
(#set! injection.include-children)
(#set! injection.language "diff"))
-; once a rebase grammar is available, we can inject rebase highlighting into
-; interactive rebase summary sections like so:
-;
-; ((rebase_command) @injection.content
-; (#set! injection.language "git-rebase"))
+((rebase_command) @injection.content
+ (#set! injection.include-children)
+ (#set! injection.language "git-rebase"))