Skip to content

Commit e957d01

Browse files
committed
ci: retrieve Node.js version from package.json
Signed-off-by: Sora Morimoto <[email protected]>
1 parent 7592d76 commit e957d01

File tree

1 file changed

+9
-9
lines changed

1 file changed

+9
-9
lines changed

.github/workflows/ci.yml

Lines changed: 9 additions & 9 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ jobs:
135135
- name: Use Node.js
136136
uses: actions/setup-node@v4
137137
with:
138-
node-version: 18
138+
node-version-file: package.json
139139

140140
- name: Get artifact dir name
141141
run: node .github/workflows/get_artifact_dir_name.js
@@ -248,7 +248,7 @@ jobs:
248248
- name: "Windows: set SHELLOPTS=igncr"
249249
if: runner.os == 'Windows'
250250
run: echo "SHELLOPTS=igncr" >>"$GITHUB_ENV"
251-
251+
252252
- name: Build compiler
253253
if: runner.os != 'Linux'
254254
run: opam exec -- dune build --display quiet --profile release
@@ -274,7 +274,7 @@ jobs:
274274
if: steps.ninja-build-cache.outputs.cache-hit != 'true'
275275
uses: actions/setup-python@v5
276276
with:
277-
python-version: '3.10'
277+
python-version: "3.10"
278278

279279
- name: Setup MSVC for ninja build (Windows)
280280
if: steps.ninja-build-cache.outputs.cache-hit != 'true' && runner.os == 'Windows'
@@ -338,7 +338,7 @@ jobs:
338338
with:
339339
path: ./tests/benchmark-cache
340340
key: syntax-benchmark-v1
341-
341+
342342
- name: Create new benchmark data and comment on alert
343343
# Do not run for PRs created from other repos as those won't be able to write to the pull request
344344
if: ${{ matrix.benchmarks && (github.event_name != 'pull_request' || github.event.pull_request.head.repo.full_name == github.event.repository.full_name) }}
@@ -359,7 +359,7 @@ jobs:
359359
with:
360360
path: ./tests/benchmark-cache
361361
key: syntax-benchmark-v1
362-
362+
363363
- name: Build playground compiler
364364
if: matrix.build_playground
365365
run: |
@@ -396,7 +396,7 @@ jobs:
396396
needs:
397397
- build-compiler
398398
- build-rewatch
399-
399+
400400
runs-on: ubuntu-latest
401401

402402
steps:
@@ -406,7 +406,7 @@ jobs:
406406
- name: Use Node.js
407407
uses: actions/setup-node@v4
408408
with:
409-
node-version: 18
409+
node-version-file: package.json
410410

411411
- name: NPM install
412412
run: npm ci --ignore-scripts
@@ -466,7 +466,7 @@ jobs:
466466
- name: Use Node.js
467467
uses: actions/setup-node@v4
468468
with:
469-
node-version: 18
469+
node-version-file: package.json
470470

471471
- name: Download artifacts
472472
uses: actions/download-artifact@v4
@@ -500,7 +500,7 @@ jobs:
500500
- name: Use Node.js
501501
uses: actions/setup-node@v4
502502
with:
503-
node-version: 18
503+
node-version-file: package.json
504504
registry-url: https://registry.npmjs.org # Needed to make auth work for publishing
505505

506506
- name: Download artifacts

0 commit comments

Comments
 (0)