From 7757cff548f12b5133a6eb2c9dde4d7142a0fbbb Mon Sep 17 00:00:00 2001 From: Jonas Geiler Date: Sat, 24 Aug 2024 14:43:46 +0200 Subject: [PATCH 1/3] refactor: improved problem matcher --- problem-matcher.json | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/problem-matcher.json b/problem-matcher.json index 215a6e0..d59ca53 100644 --- a/problem-matcher.json +++ b/problem-matcher.json @@ -4,10 +4,12 @@ "owner": "brpaz/hadolint-action", "pattern": [ { - "regexp": "(.*)\\:(\\d+)\\s(.*)", + "regexp": "^(.*):(\\d+)\\s(DL\\d+)\\s(style|info|warning|error):\\s(.*)$", "file": 1, "line": 2, - "message": 3 + "code": 3, + "severity": 4, + "message": 5 } ] } From cdaca39e4ea6a6066ee28817eeba6d2537e31be9 Mon Sep 17 00:00:00 2001 From: Jonas Geiler Date: Sat, 24 Aug 2024 14:51:39 +0200 Subject: [PATCH 2/3] fix: support shellcheck codes --- problem-matcher.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/problem-matcher.json b/problem-matcher.json index d59ca53..6d1c1c4 100644 --- a/problem-matcher.json +++ b/problem-matcher.json @@ -4,7 +4,7 @@ "owner": "brpaz/hadolint-action", "pattern": [ { - "regexp": "^(.*):(\\d+)\\s(DL\\d+)\\s(style|info|warning|error):\\s(.*)$", + "regexp": "^(.*):(\\d+)\\s((?:DL|SC)\\d+)\\s(style|info|warning|error):\\s(.*)$", "file": 1, "line": 2, "code": 3, From eceec51e2c39841c3093065ff072c8ffd1223744 Mon Sep 17 00:00:00 2001 From: Jonas Geiler Date: Sat, 24 Aug 2024 15:04:57 +0200 Subject: [PATCH 3/3] fix: support shell colors --- problem-matcher.json | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/problem-matcher.json b/problem-matcher.json index 6d1c1c4..ef5389c 100644 --- a/problem-matcher.json +++ b/problem-matcher.json @@ -4,7 +4,7 @@ "owner": "brpaz/hadolint-action", "pattern": [ { - "regexp": "^(.*):(\\d+)\\s((?:DL|SC)\\d+)\\s(style|info|warning|error):\\s(.*)$", + "regexp": "^(.*):(\\d+)\\s((?:DL|SC)\\d+)\\s(?:\\x1b\\[\\d+m)*(style|info|warning|error)(?:\\x1b\\[\\d+m)?:\\s(.*)$", "file": 1, "line": 2, "code": 3,