From e916c47d3e5a179e64e3fd248a7f5b053f5a5ade Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20=C5=A0tefka?= Date: Wed, 4 Oct 2023 08:43:16 +0200 Subject: [PATCH 1/6] fix(cicd): manually setup StyLua and Luacheck as GH Actions don't work --- .gitea/workflows/luacheck.yml | 8 +++++++- .gitea/workflows/stylua.yml | 14 ++++++++------ 2 files changed, 15 insertions(+), 7 deletions(-) diff --git a/.gitea/workflows/luacheck.yml b/.gitea/workflows/luacheck.yml index fefcaf9..105265f 100644 --- a/.gitea/workflows/luacheck.yml +++ b/.gitea/workflows/luacheck.yml @@ -6,5 +6,11 @@ jobs: steps: - name: Checkout uses: actions/checkout@v3 + + - name: Setup Luacheck + run | + apt update && apt -y install lua-check + - name: Luacheck linter - uses: lunarmodules/luacheck@v1 + run: | + luacheck . diff --git a/.gitea/workflows/stylua.yml b/.gitea/workflows/stylua.yml index 800f11f..86d21b0 100644 --- a/.gitea/workflows/stylua.yml +++ b/.gitea/workflows/stylua.yml @@ -6,10 +6,12 @@ jobs: steps: - name: Checkout uses: actions/checkout@v3 + + - name: Setup StyLua + run: | + apt update && apt install cargo -y + cargo install stylua + - name: StyLua check - uses: JohnnyMorganz/stylua-action@v3 - with: - token: ${{ secrets.GH_TOKEN }} - version: v0.18.2 # NOTE: we recommend pinning to a specific version in case of formatting changes - # CLI arguments - args: --check . + run: | + stulua . -- 2.45.2 From 634b1c2964cb282faad566582a11c7c514b37df8 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20=C5=A0tefka?= Date: Wed, 4 Oct 2023 08:46:04 +0200 Subject: [PATCH 2/6] fix(cicd-luacheck): missing : --- .gitea/workflows/luacheck.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/luacheck.yml b/.gitea/workflows/luacheck.yml index 105265f..b22d5be 100644 --- a/.gitea/workflows/luacheck.yml +++ b/.gitea/workflows/luacheck.yml @@ -8,7 +8,7 @@ jobs: uses: actions/checkout@v3 - name: Setup Luacheck - run | + run: | apt update && apt -y install lua-check - name: Luacheck linter -- 2.45.2 From a39b81f4b9fd3b718204a4d35d82df96c02e2067 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20=C5=A0tefka?= Date: Wed, 4 Oct 2023 08:46:28 +0200 Subject: [PATCH 3/6] fix(cicd): move back to ubuntu-latest as full ubuntu is not needed --- .gitea/workflows/luacheck.yml | 2 +- .gitea/workflows/stylua.yml | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/.gitea/workflows/luacheck.yml b/.gitea/workflows/luacheck.yml index b22d5be..c66da86 100644 --- a/.gitea/workflows/luacheck.yml +++ b/.gitea/workflows/luacheck.yml @@ -2,7 +2,7 @@ name: Luacheck on: [push, pull_request] jobs: Luacheck: - runs-on: ubuntu-full-latest + runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v3 diff --git a/.gitea/workflows/stylua.yml b/.gitea/workflows/stylua.yml index 86d21b0..6f4622f 100644 --- a/.gitea/workflows/stylua.yml +++ b/.gitea/workflows/stylua.yml @@ -2,7 +2,7 @@ name: StyLua on: [push, pull_request] jobs: StyLuacheck: - runs-on: ubuntu-full-latest + runs-on: ubuntu-latest steps: - name: Checkout uses: actions/checkout@v3 -- 2.45.2 From a2b08f49bbdbc0a0a229ab504562de00e6e5f068 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20=C5=A0tefka?= Date: Wed, 4 Oct 2023 08:50:14 +0200 Subject: [PATCH 4/6] fix(cicd-luacheck): identation missing --- .gitea/workflows/luacheck.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/luacheck.yml b/.gitea/workflows/luacheck.yml index c66da86..37f3d1d 100644 --- a/.gitea/workflows/luacheck.yml +++ b/.gitea/workflows/luacheck.yml @@ -9,7 +9,7 @@ jobs: - name: Setup Luacheck run: | - apt update && apt -y install lua-check + apt update && apt install lua-check -y - name: Luacheck linter run: | -- 2.45.2 From 592fac89eaf2806f0b81e0fbeaeda68cabe3bc51 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20=C5=A0tefka?= Date: Wed, 4 Oct 2023 08:53:08 +0200 Subject: [PATCH 5/6] fix(cicd-stylua): move to npx cargo is built from source and not working --- .gitea/workflows/stylua.yml | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/.gitea/workflows/stylua.yml b/.gitea/workflows/stylua.yml index 6f4622f..4eb444c 100644 --- a/.gitea/workflows/stylua.yml +++ b/.gitea/workflows/stylua.yml @@ -7,11 +7,6 @@ jobs: - name: Checkout uses: actions/checkout@v3 - - name: Setup StyLua - run: | - apt update && apt install cargo -y - cargo install stylua - - name: StyLua check run: | - stulua . + npx @johnnymorganz/stylua-bin -- 2.45.2 From 0171ced17c69e28a4b3d09ffafcb7d2529187226 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Ji=C5=99=C3=AD=20=C5=A0tefka?= Date: Wed, 4 Oct 2023 08:54:39 +0200 Subject: [PATCH 6/6] fix(cicd-stylua): provide project path to stylua --- .gitea/workflows/stylua.yml | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/.gitea/workflows/stylua.yml b/.gitea/workflows/stylua.yml index 4eb444c..4e3869a 100644 --- a/.gitea/workflows/stylua.yml +++ b/.gitea/workflows/stylua.yml @@ -9,4 +9,4 @@ jobs: - name: StyLua check run: | - npx @johnnymorganz/stylua-bin + npx @johnnymorganz/stylua-bin . -- 2.45.2