From 58860e34acd79d0226c65dd9e9ab8fe9759cd46b Mon Sep 17 00:00:00 2001 From: Forbes Lindesay Date: Wed, 25 Sep 2024 11:11:56 +0100 Subject: [PATCH] fix: update CI to maintained node.js releases --- .circleci/config.yml | 2 +- .github/workflows-src/test.ts | 4 ++-- .github/workflows/test.yml | 16 ++++++++-------- .github/workflows/website.yml | 4 ++-- 4 files changed, 13 insertions(+), 13 deletions(-) diff --git a/.circleci/config.yml b/.circleci/config.yml index a568925f..191ebb02 100644 --- a/.circleci/config.yml +++ b/.circleci/config.yml @@ -3,7 +3,7 @@ version: 2 refs: - &container docker: - - image: node:14 + - image: node:20 environment: PG_URL: 'postgres://test-user@localhost:5432/test-db' MYSQL_URL: 'mysql://test-user:password@localhost:3306/test-db' diff --git a/.github/workflows-src/test.ts b/.github/workflows-src/test.ts index 366ece91..09041cac 100644 --- a/.github/workflows-src/test.ts +++ b/.github/workflows-src/test.ts @@ -30,7 +30,7 @@ export function yarnInstallWithCache(nodeVersion: Expression): Steps { run('yarn install --prefer-offline'); }; } -export function setup(nodeVersion: Expression = '14.x'): Steps { +export function setup(nodeVersion: Expression = '20.x'): Steps { return ({use, add}) => { use('actions/checkout@v2'); use('actions/setup-node@v1', { @@ -121,7 +121,7 @@ export default createWorkflow(({setWorkflowName, addTrigger, addJob}) => { const {node} = setBuildMatrix( { - node: ['14.x', '16.x', '18.x'], + node: ['18.x', '20.x', '22.x'], }, {failFast: false}, ); diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 85b5c3a0..f739e66a 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -18,7 +18,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-node@v1 with: - node-version: 14.x + node-version: 20.x registry-url: https://registry.npmjs.org - name: Get yarn cache directory path run: echo "::set-output name=dir::$(yarn cache dir)" @@ -30,7 +30,7 @@ jobs: ${{steps.step_3.outputs.dir}} node_modules packages/*/node_modules - key: ${{runner.os}}-14.x-${{hashFiles('yarn.lock')}}-2 + key: ${{runner.os}}-20.x-${{hashFiles('yarn.lock')}}-2 - run: yarn install --prefer-offline - name: Enable Cache uses: actions/cache@v2 @@ -163,9 +163,9 @@ jobs: strategy: matrix: node: - - 14.x - - 16.x - 18.x + - 20.x + - 22.x fail-fast: false steps: - uses: actions/checkout@v2 @@ -279,7 +279,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-node@v1 with: - node-version: 14.x + node-version: 20.x registry-url: https://registry.npmjs.org - name: Get yarn cache directory path run: echo "::set-output name=dir::$(yarn cache dir)" @@ -291,7 +291,7 @@ jobs: ${{steps.step_3.outputs.dir}} node_modules packages/*/node_modules - key: ${{runner.os}}-14.x-${{hashFiles('yarn.lock')}}-2 + key: ${{runner.os}}-20.x-${{hashFiles('yarn.lock')}}-2 - run: yarn install --prefer-offline - run: yarn prettier:check lint: @@ -302,7 +302,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-node@v1 with: - node-version: 14.x + node-version: 20.x registry-url: https://registry.npmjs.org - name: Get yarn cache directory path run: echo "::set-output name=dir::$(yarn cache dir)" @@ -314,7 +314,7 @@ jobs: ${{steps.step_3.outputs.dir}} node_modules packages/*/node_modules - key: ${{runner.os}}-14.x-${{hashFiles('yarn.lock')}}-2 + key: ${{runner.os}}-20.x-${{hashFiles('yarn.lock')}}-2 - run: yarn install --prefer-offline - name: "Load output: ${{needs.build.outputs.output}}" uses: actions/download-artifact@v4 diff --git a/.github/workflows/website.yml b/.github/workflows/website.yml index 69d5554e..dddc350e 100644 --- a/.github/workflows/website.yml +++ b/.github/workflows/website.yml @@ -18,7 +18,7 @@ jobs: - uses: actions/checkout@v2 - uses: actions/setup-node@v1 with: - node-version: 14.x + node-version: 20.x registry-url: https://registry.npmjs.org - name: Get yarn cache directory path run: echo "::set-output name=dir::$(yarn cache dir)" @@ -30,7 +30,7 @@ jobs: ${{steps.step_3.outputs.dir}} node_modules packages/*/node_modules - key: ${{runner.os}}-14.x-${{hashFiles('yarn.lock')}}-2 + key: ${{runner.os}}-20.x-${{hashFiles('yarn.lock')}}-2 - run: yarn install --prefer-offline - name: Enable Cache uses: actions/cache@v2