1
0
mirror of https://github.com/helix-editor/helix synced 2026-03-12 10:48:32 +01:00
helix/runtime/queries/ruby/injections.scm
2025-09-02 17:51:42 -05:00

36 lines
825 B
Scheme

((comment) @injection.content
(#set! injection.language "comment"))
((heredoc_body
(heredoc_content) @injection.content
(heredoc_end) @name
(#set! injection.language "sql"))
(#eq? @name "SQL"))
((heredoc_body
(heredoc_content) @injection.content
(heredoc_end) @name
(#set! injection.language "graphql"))
(#any-of? @name
"GQL"
"GRAPHQL"))
((heredoc_body
(heredoc_content) @injection.content
(heredoc_end) @name
(#set! injection.language "erb"))
(#eq? @name "ERB"))
; `<command>`
; %x{<command>}
(subshell
(string_content) @injection.content
(#set! injection.language "bash"))
(call
method: (identifier) @_method (#any-of? @_method "system" "spawn" "exec")
arguments: (argument_list
(string
(string_content) @injection.content))
(#set! injection.language "bash"))