mirror of
https://github.com/nix-community/nixvim.git
synced 2025-07-09 16:54:36 +02:00
plugins/treesitter: Add a treesitter injection query for raw lua
This commit is contained in:
parent
29118021b3
commit
023dc1c93a
1 changed files with 14 additions and 1 deletions
|
@ -11,7 +11,20 @@
|
||||||
((string_fragment) @injection.content
|
((string_fragment) @injection.content
|
||||||
(#set! injection.language "lua")))
|
(#set! injection.language "lua")))
|
||||||
]
|
]
|
||||||
(#match? @_path "(^extraConfigLua(Pre|Post)?)$"))
|
(#match? @_path "(^(extraConfigLua(Pre|Post)?|__raw))$"))
|
||||||
|
|
||||||
|
(apply_expression
|
||||||
|
function: (_) @_func
|
||||||
|
argument: [
|
||||||
|
(string_expression
|
||||||
|
((string_fragment) @injection.content
|
||||||
|
(#set! injection.language "lua")))
|
||||||
|
(indented_string_expression
|
||||||
|
((string_fragment) @injection.content
|
||||||
|
(#set! injection.language "lua")))
|
||||||
|
]
|
||||||
|
(#match? @_func "(^|\\.)mkRaw$")
|
||||||
|
(#set! injection.combined))
|
||||||
|
|
||||||
(binding
|
(binding
|
||||||
attrpath: (attrpath
|
attrpath: (attrpath
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue