From b687dea2dcf739a5ab22164a236cfa002737c713 Mon Sep 17 00:00:00 2001 From: hugo-syn Date: Tue, 21 Jan 2025 14:40:25 +0100 Subject: [PATCH] feat: improve dependabot regexp --- common/helpers.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/common/helpers.go b/common/helpers.go index 2316afb..f1ef3c7 100644 --- a/common/helpers.go +++ b/common/helpers.go @@ -24,7 +24,7 @@ var GitHubOutputPwshRegexp = regexp.MustCompile(`(?m)(?i:env):GITHUB_OUTPUT`) var GitHubOutputBashRegexp = regexp.MustCompile(`(?m)>>\s*"*\${*GITHUB_OUTPUT`) var GitHubEnvPwshRegexp = regexp.MustCompile(`(?m)(?i:env):GITHUB_ENV`) var GitHubEnvBashRexexp = regexp.MustCompile(`(?m)>{1,2}\s*"*\${*GITHUB_ENV`) -var BotActor = regexp.MustCompile(`(?m)github.actor\s*==\s*["'].*\[bot\]`) +var BotActor = regexp.MustCompile(`(?m)github.(triggering_)?actor\s*?(=|!)=\s*?["'].*?\[bot\]`) // GitCheckoutBashRexexp It’s not possible to include a backtick in a raw string literal (https://yourbasic.org/golang/multiline-string/) var GitCheckoutBashRexexp = regexp.MustCompile(`(?m)git checkout.*(\$|` + regexp.QuoteMeta("`") + `)`)