Skip to content

Commit a58cabd

Browse files
authored
ci: Fail-fast "npm ci" if deps require unsupported node version (#912)
When upgrading a dependency to a newer version, it might require a different node version than before which could be unsupported by the repo. Unfortunately, this could be easily overseen. This PR adds the flag `--engine-strict` to the dependency installation step during the GH Actions job. Incase such a version requirement change, this flag will now fail-fast the job which should attract attention.
1 parent 9fca939 commit a58cabd

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

.github/workflows/ci.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -22,7 +22,7 @@ jobs:
2222
node-version: 20.11.0
2323

2424
- name: Install dependencies
25-
run: npm ci
25+
run: npm ci --engine-strict # --engine-strict is used to fail-fast if deps require node versions unsupported by the repo
2626

2727
- name: Perform ESLint check
2828
run: npm run lint

0 commit comments

Comments
 (0)