From 4ceced14db95ade17adeb731e1f858aa426b1388 Mon Sep 17 00:00:00 2001 From: Jen Jones Arnesen Date: Tue, 29 Oct 2024 14:46:21 +0100 Subject: [PATCH] chore: update gh actions with latest version --- .github/workflows/dhis2-preview-pr.yml | 8 +++--- .github/workflows/dhis2-verify-commits.yml | 12 ++++---- .github/workflows/verify.yml | 32 +++++++++++----------- 3 files changed, 27 insertions(+), 25 deletions(-) diff --git a/.github/workflows/dhis2-preview-pr.yml b/.github/workflows/dhis2-preview-pr.yml index 696dbe0e4..f79b618d3 100644 --- a/.github/workflows/dhis2-preview-pr.yml +++ b/.github/workflows/dhis2-preview-pr.yml @@ -21,12 +21,12 @@ jobs: runs-on: ubuntu-latest if: "!github.event.push.repository.fork && github.actor != 'dependabot[bot]'" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 14.x - - uses: c-hive/gha-yarn-cache@v1 + - uses: c-hive/gha-yarn-cache@v2 - run: yarn install --frozen-lockfile - name: Build @@ -34,7 +34,7 @@ jobs: - name: Deploy id: netlify-deploy - uses: nwtgck/actions-netlify@v1.2.2 + uses: nwtgck/actions-netlify@v3 timeout-minutes: 1 with: github-token: ${{ secrets.DHIS2_BOT_GITHUB_TOKEN }} diff --git a/.github/workflows/dhis2-verify-commits.yml b/.github/workflows/dhis2-verify-commits.yml index ae7831b56..dda60ceb5 100644 --- a/.github/workflows/dhis2-verify-commits.yml +++ b/.github/workflows/dhis2-verify-commits.yml @@ -8,8 +8,8 @@ jobs: lint-pr-title: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: c-hive/gha-yarn-cache@v1 + - uses: actions/checkout@v4 + - uses: c-hive/gha-yarn-cache@v2 - run: yarn install --frozen-lockfile - id: commitlint run: echo ::set-output name=config_path::$(node -e "process.stdout.write(require('@dhis2/cli-style').config.commitlint)") @@ -20,13 +20,15 @@ jobs: lint-commits: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: fetch-depth: 0 - - uses: c-hive/gha-yarn-cache@v1 + - uses: c-hive/gha-yarn-cache@v2 - run: yarn install --frozen-lockfile - id: commitlint + # This will return a config file with a .js extensions for @dhis2/cli-style v10 run: echo ::set-output name=config_path::$(node -e "process.stdout.write(require('@dhis2/cli-style').config.commitlint)") - - uses: wagoid/commitlint-github-action@v4 + # commitlint-github-action@v6+ requires a .mjs extension for the config file, so the highest version we can use is 5 + - uses: wagoid/commitlint-github-action@v5 with: configFile: ${{ steps.commitlint.outputs.config_path }} diff --git a/.github/workflows/verify.yml b/.github/workflows/verify.yml index f5a97e7d9..12406d685 100644 --- a/.github/workflows/verify.yml +++ b/.github/workflows/verify.yml @@ -17,8 +17,8 @@ jobs: if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 14.x @@ -37,8 +37,8 @@ jobs: needs: install if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 14.x @@ -51,7 +51,7 @@ jobs: - name: Build run: yarn build - - uses: actions/upload-artifact@v2 + - uses: actions/upload-artifact@v4 with: name: app-build path: | @@ -64,8 +64,8 @@ jobs: needs: install if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 14.x @@ -86,8 +86,8 @@ jobs: needs: install if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v1 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: 14.x @@ -115,9 +115,9 @@ jobs: steps: - name: Checkout - uses: actions/checkout@v2 + uses: actions/checkout@v4 - - uses: actions/setup-node@v1 + - uses: actions/setup-node@v4 with: node-version: 14.x @@ -158,15 +158,15 @@ jobs: needs: [build, lint, test, e2e] if: "!contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: token: ${{env.GH_TOKEN}} - - uses: actions/setup-node@v1 + - uses: actions/setup-node@v4 with: node-version: 14.x - - uses: actions/download-artifact@v2 + - uses: actions/download-artifact@v4 with: name: app-build @@ -180,11 +180,11 @@ jobs: needs: [publish] if: "github.event_name == 'push' && !contains(github.event.head_commit.message, '[skip ci]')" steps: - - uses: actions/checkout@v2 + - uses: actions/checkout@v4 with: token: ${{env.GH_TOKEN}} - - uses: actions/setup-node@v1 + - uses: actions/setup-node@v4 with: node-version: 14.x