mirror of
https://github.com/nvim-treesitter/nvim-treesitter.git
synced 2026-07-16 02:10:15 -04:00
chore: query formatting
This commit is contained in:
parent
79975d6557
commit
57a8acf0c4
674 changed files with 18466 additions and 12648 deletions
|
|
@ -1,35 +1,52 @@
|
|||
((comment) @injection.content
|
||||
(#set! injection.language "comment"))
|
||||
((comment) @injection.content
|
||||
(#set! injection.language "comment"))
|
||||
|
||||
((regex) @injection.content
|
||||
(#set! injection.language "regex"))
|
||||
(#set! injection.language "regex"))
|
||||
|
||||
((heredoc_redirect
|
||||
(heredoc_body) @injection.content
|
||||
(heredoc_end) @injection.language)
|
||||
(#downcase! @injection.language))
|
||||
(#downcase! @injection.language))
|
||||
|
||||
; printf 'format'
|
||||
((command
|
||||
name: (command_name) @_command
|
||||
. argument: [(string) (raw_string)] @injection.content)
|
||||
(#eq? @_command "printf")
|
||||
(#set! injection.language "printf"))
|
||||
.
|
||||
argument:
|
||||
[
|
||||
(string)
|
||||
(raw_string)
|
||||
] @injection.content)
|
||||
(#eq? @_command "printf")
|
||||
(#set! injection.language "printf"))
|
||||
|
||||
; printf -v var 'format'
|
||||
((command
|
||||
name: (command_name) @_command
|
||||
argument: (word) @_arg
|
||||
. (_) . argument: [(string) (raw_string)] @injection.content)
|
||||
(#eq? @_command "printf")
|
||||
(#eq? @_arg "-v")
|
||||
(#set! injection.language "printf"))
|
||||
.
|
||||
(_)
|
||||
.
|
||||
argument:
|
||||
[
|
||||
(string)
|
||||
(raw_string)
|
||||
] @injection.content)
|
||||
(#eq? @_command "printf")
|
||||
(#eq? @_arg "-v")
|
||||
(#set! injection.language "printf"))
|
||||
|
||||
; printf -- 'format'
|
||||
((command
|
||||
name: (command_name) @_command
|
||||
argument: (word) @_arg
|
||||
. argument: [(string) (raw_string)] @injection.content)
|
||||
(#eq? @_command "printf")
|
||||
(#eq? @_arg "--")
|
||||
(#set! injection.language "printf"))
|
||||
.
|
||||
argument:
|
||||
[
|
||||
(string)
|
||||
(raw_string)
|
||||
] @injection.content)
|
||||
(#eq? @_command "printf")
|
||||
(#eq? @_arg "--")
|
||||
(#set! injection.language "printf"))
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue