From ccf4407d44a092d7fb63efed0a714c8474172183 Mon Sep 17 00:00:00 2001 From: Iampete1 Date: Thu, 19 Dec 2024 21:32:54 +0000 Subject: [PATCH] actions: add problem matcher to lua checks --- .github/problem-matchers/Lua.json | 32 ++++++++++++++++++++++++++++ .github/workflows/test_scripting.yml | 3 +++ 2 files changed, 35 insertions(+) create mode 100644 .github/problem-matchers/Lua.json diff --git a/.github/problem-matchers/Lua.json b/.github/problem-matchers/Lua.json new file mode 100644 index 0000000000..c62c44f18d --- /dev/null +++ b/.github/problem-matchers/Lua.json @@ -0,0 +1,32 @@ +{ + "problemMatcher": [ + { + "owner": "Luacheck-problem-matcher", + "fileLocation": [ "relative", "${GITHUB_WORKSPACE}" ], + "pattern": [ + { + "regexp": "^( *)(.+.lua):(\\d+):(\\d+): (.*)$", + "file": 2, + "line": 3, + "column": 4, + "message": 5 + } + ] + }, + { + "owner": "Lua-language-server-problem-matcher", + "pattern": [ + { + "regexp": "^(.+.lua):(\\d+):(\\d+)", + "file": 1, + "line": 2, + "column": 3 + }, + { + "regexp": "^(.*)", + "message": 1 + } + ] + } + ] +} diff --git a/.github/workflows/test_scripting.yml b/.github/workflows/test_scripting.yml index 53dbf016f5..9c425e59a2 100644 --- a/.github/workflows/test_scripting.yml +++ b/.github/workflows/test_scripting.yml @@ -29,6 +29,9 @@ jobs: with: submodules: 'recursive' + - name: Register lua problem matcher + run: echo "::add-matcher::.github/problem-matchers/Lua.json" + - name: Lua Linter shell: bash run: |