From 7bf8022d8bdd959de579452b01cd4c79668a5cbb Mon Sep 17 00:00:00 2001 From: Jens Kuerschner Date: Tue, 7 Nov 2023 16:06:10 +0100 Subject: [PATCH] workflow updates --- .github/workflows/gh-pages.yml | 6 +++--- .github/workflows/npm-publish.yml | 21 ++++++++++++++------- .github/workflows/tests.yml | 6 +++--- 3 files changed, 20 insertions(+), 13 deletions(-) diff --git a/.github/workflows/gh-pages.yml b/.github/workflows/gh-pages.yml index 8d3ca09..bc62dd5 100644 --- a/.github/workflows/gh-pages.yml +++ b/.github/workflows/gh-pages.yml @@ -20,11 +20,11 @@ jobs: runs-on: ubuntu-latest steps: - name: Checkout - uses: actions/checkout@v3 + uses: actions/checkout@v4 - name: Setup Node - uses: actions/setup-node@v3 + uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 20 registry-url: https://registry.npmjs.org/ cache: 'npm' - name: npm ci diff --git a/.github/workflows/npm-publish.yml b/.github/workflows/npm-publish.yml index 962c266..1389bf2 100644 --- a/.github/workflows/npm-publish.yml +++ b/.github/workflows/npm-publish.yml @@ -11,24 +11,31 @@ jobs: test: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 20 + registry-url: https://registry.npmjs.org/ + cache: 'npm' - run: npm ci - run: npm test build-and-publish: needs: test runs-on: ubuntu-latest + permissions: + contents: read + id-token: write steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: - node-version: 16 + node-version: 20 registry-url: https://registry.npmjs.org/ + cache: 'npm' + - run: npm install -g npm - run: npm ci - run: npm run build - - run: npm publish + - run: npm publish --provenance env: NODE_AUTH_TOKEN: ${{secrets.NPM_SECRET}} diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml index 916aa10..f510ae8 100644 --- a/.github/workflows/tests.yml +++ b/.github/workflows/tests.yml @@ -9,12 +9,12 @@ jobs: strategy: matrix: platform: [ubuntu-latest] - node-version: ['16'] + node-version: ['18', '20'] toolchain: [stable] runs-on: ${{ matrix.platform }} steps: - - uses: actions/checkout@v2 - - uses: actions/setup-node@v2 + - uses: actions/checkout@v4 + - uses: actions/setup-node@v4 with: node-version: ${{ matrix.node-version }} - name: Run tests