From 15a9536b06e5bf9eb118cedd6ec288d2534a491f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Vladim=C3=ADr=20Gorej?= Date: Fri, 22 Nov 2024 10:47:08 +0100 Subject: [PATCH] chore: use Node.js 22 for dev env (#3720) --- .github/workflows/nodejs.yml | 15 +++++++++++---- .github/workflows/release.yml | 2 +- .nvmrc | 2 +- docs/development/setting-up.md | 4 ++-- 4 files changed, 15 insertions(+), 8 deletions(-) diff --git a/.github/workflows/nodejs.yml b/.github/workflows/nodejs.yml index 73a142b9a..a2e905eb2 100644 --- a/.github/workflows/nodejs.yml +++ b/.github/workflows/nodejs.yml @@ -15,7 +15,7 @@ jobs: strategy: matrix: - node-version: [16.x, 18.x, 20.x] + node-version: [16.x, 18.x, 20.x, 22.x] steps: - uses: actions/checkout@v4 @@ -47,7 +47,7 @@ jobs: - name: Build swagger-js run: npm run build - name: Upload commonjs build artifacts - if: startsWith(matrix.node-version, '20') + if: startsWith(matrix.node-version, '22') uses: actions/upload-artifact@v4 with: name: commonjs @@ -60,10 +60,10 @@ jobs: steps: - uses: actions/checkout@v4 - - name: Use Node.js 20 + - name: Use Node.js 22 uses: actions/setup-node@v4 with: - node-version: 20 + node-version: 22 - name: Cache Node Modules id: cache-node-modules @@ -116,3 +116,10 @@ jobs: - name: Run commonjs build artifacts on Node.js 20.x run: node -p "require('./commonjs')" + - name: Use Node 22.x + uses: actions/setup-node@v4 + with: + node-version: 22.x + - name: Run commonjs build artifacts on Node.js 22.x + run: node -p "require('./commonjs')" + diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index d01cb759b..53ebdd45c 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -23,7 +23,7 @@ jobs: - name: Setup Node.js uses: actions/setup-node@v4 with: - node-version: 20 + node-version: 22 - name: Install dependencies run: npm ci diff --git a/.nvmrc b/.nvmrc index 4adfbc353..7af24b7dd 100644 --- a/.nvmrc +++ b/.nvmrc @@ -1 +1 @@ -20.3.0 +22.11.0 diff --git a/docs/development/setting-up.md b/docs/development/setting-up.md index 008150e7e..d81f95065 100644 --- a/docs/development/setting-up.md +++ b/docs/development/setting-up.md @@ -3,8 +3,8 @@ ### Prerequisites - git, any version -- Node.js >=20.3.0 -- NPM >=9.6.7 +- Node.js >=22.11.0 +- NPM >=10.9.0 ### Setting up