Unnamed repository; edit this file 'description' to name the repository.
Diffstat (limited to 'runtime/queries/ruby/injections.scm')
-rw-r--r--runtime/queries/ruby/injections.scm12
1 files changed, 12 insertions, 0 deletions
diff --git a/runtime/queries/ruby/injections.scm b/runtime/queries/ruby/injections.scm
index 3e0d8bb8..b87ea8cb 100644
--- a/runtime/queries/ruby/injections.scm
+++ b/runtime/queries/ruby/injections.scm
@@ -21,3 +21,15 @@
(#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"))