Skip to content

Commit f451bef

Browse files
authored
ci: upgrade to Node.js 22 (#10374)
### Description Upgrading our repository to Node.js 22 by reducing our source of truth to the value in `package.json#engines`. Notably, this PR also adds Node.js 22 to the JS package test matrix. ### Testing Instructions CI
1 parent c65d8bb commit f451bef

File tree

14 files changed

+12
-28
lines changed

14 files changed

+12
-28
lines changed

.github/actions/examples-tests/action.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -24,7 +24,6 @@ runs:
2424
uses: ./.github/actions/setup-turborepo-environment
2525
with:
2626
github-token: "${{ inputs.github-token }}"
27-
node-version: "22"
2827

2928
- name: Install Global Turbo
3029
uses: ./.github/actions/install-global-turbo

.github/actions/setup-node/action.yml

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -16,7 +16,6 @@ inputs:
1616
node-version:
1717
description: "Node version to install"
1818
required: false
19-
default: "18"
2019

2120
runs:
2221
using: "composite"
@@ -27,6 +26,8 @@ runs:
2726
- name: Setup Node.js
2827
uses: actions/setup-node@v4
2928
with:
29+
# node-version-file is the default, but can be overridden using node-version
30+
node-version-file: "package.json"
3031
node-version: ${{ inputs.node-version }}
3132
cache: pnpm
3233

.github/actions/setup-turborepo-environment/action.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,6 @@ inputs:
77
node-version:
88
description: Node version
99
required: false
10-
default: "18"
1110

1211
runs:
1312
using: "composite"

.github/workflows/docs.yml

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -18,8 +18,6 @@ jobs:
1818
uses: actions/checkout@v4
1919

2020
- uses: ./.github/actions/setup-node
21-
with:
22-
node-version: 20
2321

2422
- name: Run link checker
2523
run: cd docs/link-checker && pnpm run check-links

.github/workflows/lint.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -63,7 +63,6 @@ jobs:
6363
uses: ./.github/actions/setup-node
6464
with:
6565
extra-flags: --no-optional
66-
node-version: "20"
6766

6867
- name: Install Global Turbo
6968
uses: ./.github/actions/install-global-turbo

.github/workflows/test-js-packages.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -36,6 +36,7 @@ jobs:
3636
node-version:
3737
- 18
3838
- 20
39+
- 22
3940
env:
4041
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
4142
TURBO_TEAM: ${{ vars.TURBO_TEAM }}

.github/workflows/turborepo-compare-cache-item.yml

Lines changed: 4 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -16,10 +16,8 @@ jobs:
1616
runs-on: ${{ matrix.os }}
1717

1818
steps:
19-
- name: Setup Node.js
20-
uses: actions/setup-node@v4
21-
with:
22-
node-version: 18
19+
- name: Setup Node
20+
uses: ./.github/actions/setup-node
2321

2422
- name: create-turbo
2523
run: |
@@ -50,10 +48,8 @@ jobs:
5048
runs-on: ${{ matrix.os }}
5149

5250
steps:
53-
- name: Setup Node.js
54-
uses: actions/setup-node@v4
55-
with:
56-
node-version: 18
51+
- name: Setup Node
52+
uses: ./.github/actions/setup-node
5753

5854
- name: create-turbo
5955
run: |

.github/workflows/turborepo-native-lib-test.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -27,6 +27,7 @@ jobs:
2727
node-version:
2828
- 18
2929
- 20
30+
- 22
3031
env:
3132
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
3233
TURBO_TEAM: ${{ vars.TURBO_TEAM }}

.github/workflows/turborepo-release.yml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -109,7 +109,6 @@ jobs:
109109
uses: ./.github/actions/setup-turborepo-environment
110110
with:
111111
github-token: "${{ secrets.GITHUB_TOKEN }}"
112-
node-version: "20"
113112
- name: Install Global Turbo
114113
uses: ./.github/actions/install-global-turbo
115114
with:

.github/workflows/turborepo-test.yml

Lines changed: 1 addition & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ jobs:
135135
uses: ./.github/actions/setup-turborepo-environment
136136
with:
137137
github-token: "${{ secrets.GITHUB_TOKEN }}"
138-
node-version: "18.20.2"
138+
node-version: "18.20.2" # TODO: Update integration tests with changed log output in Node.js 22
139139

140140
- name: Install Global Turbo
141141
uses: ./.github/actions/install-global-turbo
@@ -187,7 +187,6 @@ jobs:
187187
uses: ./.github/actions/setup-turborepo-environment
188188
with:
189189
github-token: "${{ secrets.GITHUB_TOKEN }}"
190-
node-version: "18.20.2"
191190

192191
- name: Run cargo fmt check
193192
run: |
@@ -220,7 +219,6 @@ jobs:
220219
uses: ./.github/actions/setup-turborepo-environment
221220
with:
222221
github-token: "${{ secrets.GITHUB_TOKEN }}"
223-
node-version: "18.20.2"
224222

225223
- name: Run cargo check
226224
run: |
@@ -256,7 +254,6 @@ jobs:
256254
uses: ./.github/actions/setup-turborepo-environment
257255
with:
258256
github-token: "${{ secrets.GITHUB_TOKEN }}"
259-
node-version: "18.20.2"
260257

261258
- name: Run sccache-cache
262259
uses: mozilla-actions/sccache-action@v0.0.6

0 commit comments

Comments
 (0)