mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-01 19:17:02 -04:00
feat(latex): injections for luacode, asy{def} environments
This commit is contained in:
parent
874b99065b
commit
35fa869b53
2 changed files with 13 additions and 8 deletions
|
|
@ -387,7 +387,7 @@
|
|||
"revision": "854a40e99f7c70258e522bdb8ab584ede6196e2e"
|
||||
},
|
||||
"latex": {
|
||||
"revision": "08d8b885a3fa67a6e8aa8edd8988eaa55db46ba4"
|
||||
"revision": "107435ada4c4c422ba4f951336b5e566b86ac3ca"
|
||||
},
|
||||
"ledger": {
|
||||
"revision": "8a841fb20ce683bfbb3469e6ba67f2851cfdf94a"
|
||||
|
|
|
|||
|
|
@ -17,15 +17,20 @@
|
|||
code: (source_code) @injection.content
|
||||
(#set! injection.language "python"))
|
||||
|
||||
(luacode_environment
|
||||
code: (source_code) @injection.content
|
||||
(#set! injection.language "lua"))
|
||||
|
||||
(asy_environment
|
||||
code: (source_code) @injection.content
|
||||
(#set! injection.language "c"))
|
||||
|
||||
(asydef_environment
|
||||
code: (source_code) @injection.content
|
||||
(#set! injection.language "c"))
|
||||
|
||||
(minted_environment
|
||||
(begin
|
||||
language: (curly_group_text
|
||||
(text) @injection.language))
|
||||
(source_code) @injection.content)
|
||||
|
||||
((generic_environment
|
||||
(begin
|
||||
name: (curly_group_text
|
||||
(text) @_env))) @injection.content
|
||||
(#set! injection.language "c")
|
||||
(#any-of? @_env "asy" "asydef"))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue