mirror of
https://github.com/zoriya/flake.git
synced 2026-06-05 11:39:51 +00:00
Match all sql like strings as sql
This commit is contained in:
@@ -3,3 +3,8 @@
|
|||||||
function: (attribute attribute: (identifier) @id (#match? @id "execute|read_sql"))
|
function: (attribute attribute: (identifier) @id (#match? @id "execute|read_sql"))
|
||||||
arguments: (argument_list
|
arguments: (argument_list
|
||||||
(string (string_content) @injection.content (#set! injection.language "sql"))))
|
(string (string_content) @injection.content (#set! injection.language "sql"))))
|
||||||
|
|
||||||
|
(string
|
||||||
|
(string_content) @injection.content
|
||||||
|
(#match? @injection.content "\\s*(SELECT|CREATE|DROP|INSERT|UPDATE|ALTER|DELETE|select|create|drop|insert|update|alter|delete)\\W+")
|
||||||
|
(#set! injection.language "sql"))
|
||||||
|
|||||||
Reference in New Issue
Block a user