From 2fceb94c5232f1ba477aabe42af318fe194243b6 Mon Sep 17 00:00:00 2001 From: Lars Erik Wik Date: Tue, 15 Jul 2025 15:03:28 +0200 Subject: [PATCH 1/2] job-static-check.yml: formatted yaml Signed-off-by: Lars Erik Wik --- .github/workflows/job-static-check.yml | 65 +++++++++++++------------- 1 file changed, 32 insertions(+), 33 deletions(-) diff --git a/.github/workflows/job-static-check.yml b/.github/workflows/job-static-check.yml index 3b265a0a91..29826d4cfa 100644 --- a/.github/workflows/job-static-check.yml +++ b/.github/workflows/job-static-check.yml @@ -1,45 +1,44 @@ name: Static Check -on: - workflow_call +on: workflow_call jobs: static_check: runs-on: ubuntu-24.04 steps: - - name: Checkout Core - uses: actions/checkout@v3 - with: - submodules: recursive - path: core + - name: Checkout Core + uses: actions/checkout@v3 + with: + submodules: recursive + path: core - - name: Get Togethers - uses: cfengine/together-javascript-action@main - id: together - with: - myToken: ${{ secrets.GITHUB_TOKEN }} + - name: Get Togethers + uses: cfengine/together-javascript-action@main + id: together + with: + myToken: ${{ secrets.GITHUB_TOKEN }} - - name: Checkout Buildscripts - uses: actions/checkout@v3 - with: - repository: cfengine/buildscripts - submodules: recursive - path: buildscripts - ref: ${{steps.together.outputs.buildscripts || github.base_ref || github.ref}} + - name: Checkout Buildscripts + uses: actions/checkout@v3 + with: + repository: cfengine/buildscripts + submodules: recursive + path: buildscripts + ref: ${{steps.together.outputs.buildscripts || github.base_ref || github.ref}} - - name: Checkout Masterfiles - uses: actions/checkout@v3 - with: - repository: cfengine/masterfiles - submodules: recursive - path: masterfiles - ref: ${{steps.together.outputs.masterfiles || github.base_ref || github.ref}} + - name: Checkout Masterfiles + uses: actions/checkout@v3 + with: + repository: cfengine/masterfiles + submodules: recursive + path: masterfiles + ref: ${{steps.together.outputs.masterfiles || github.base_ref || github.ref}} - - name: Prepare Environment - run: | - sudo apt-get update && \ - sudo apt-get install -y buildah + - name: Prepare Environment + run: | + sudo apt-get update && \ + sudo apt-get install -y buildah - - name: Run The Test - working-directory: ./core - run: ./tests/static-check/run.sh + - name: Run The Test + working-directory: ./core + run: ./tests/static-check/run.sh From adff533ebf9010d908d183f4bd3d178ee304946a Mon Sep 17 00:00:00 2001 From: Lars Erik Wik Date: Tue, 15 Jul 2025 15:04:28 +0200 Subject: [PATCH 2/2] job-static-check.yml: Remove code to checkout unused repos The buildscripts and masterfiles repositories are not needed to perform static checks. Signed-off-by: Lars Erik Wik --- .github/workflows/job-static-check.yml | 16 ---------------- 1 file changed, 16 deletions(-) diff --git a/.github/workflows/job-static-check.yml b/.github/workflows/job-static-check.yml index 29826d4cfa..35616fcf16 100644 --- a/.github/workflows/job-static-check.yml +++ b/.github/workflows/job-static-check.yml @@ -18,22 +18,6 @@ jobs: with: myToken: ${{ secrets.GITHUB_TOKEN }} - - name: Checkout Buildscripts - uses: actions/checkout@v3 - with: - repository: cfengine/buildscripts - submodules: recursive - path: buildscripts - ref: ${{steps.together.outputs.buildscripts || github.base_ref || github.ref}} - - - name: Checkout Masterfiles - uses: actions/checkout@v3 - with: - repository: cfengine/masterfiles - submodules: recursive - path: masterfiles - ref: ${{steps.together.outputs.masterfiles || github.base_ref || github.ref}} - - name: Prepare Environment run: | sudo apt-get update && \