Diff

.semgrep.yml @ 12717:898e99f49d80

semgrep: Catch stanza:text() (assuming it's meant to be :get_text())
author Matthew Wild <mwild1@gmail.com>
date Sat, 03 Sep 2022 21:17:38 +0100
parent 11289:c6965f3c321c
line wrap: on
line diff
--- a/.semgrep.yml	Mon Jul 11 18:48:57 2022 +0200
+++ b/.semgrep.yml	Sat Sep 03 21:17:38 2022 +0100
@@ -22,3 +22,9 @@
   message: Non-string default from :get_option_string
   severity: ERROR
   languages: [lua]
+- id: stanza-empty-text-constructor
+  patterns:
+    - pattern: $A:text()
+  message: Use :get_text() to read text, or pass a value here to add text
+  severity: WARNING
+  languages: [lua]