Skip to content

Commit

Permalink
add Node.js 18, 20 and 22 to engines (#51)
Browse files Browse the repository at this point in the history
* chore: disable colors for npm tests

* add Node.js 18, 20 and 22 to `engines`

npm 10.8.2 doesn't install the `latest` tagged version of @pkgjs/support
with Node.js 22 as Node.js 22 is outside of the declared specification
for `engines`->`node`.

Regardless of whether the change in behaviour of npm is correct for a
semver-patch release of npm, update the `engines` field to include the
supported Node.js release lines at this point in time.
  • Loading branch information
richardlau authored Aug 8, 2024
1 parent c042dc4 commit 81a010c
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
4 changes: 3 additions & 1 deletion .github/workflows/test.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,7 +10,7 @@ jobs:
runs-on: ubuntu-latest
strategy:
matrix:
node-version: [10.x, 12.x, 14.x, 16.x, 17.x]
node-version: [10.x, 12.x, 14.x, 16.x, 17.x, 18.x, 20.x, 22.x]
os: [ubuntu-latest, windows-latest]

steps:
Expand All @@ -21,3 +21,5 @@ jobs:
node-version: ${{ matrix.node-version }}
- name: npm install and test
run: npm it
env:
NO_COLOR: 1
2 changes: 1 addition & 1 deletion package.json
Original file line number Diff line number Diff line change
Expand Up @@ -48,6 +48,6 @@
"mocha": "^6.2.0"
},
"engines": {
"node": "^17 || ^16 || ^14 || ^13 || ^12 || ^11 || ^10.19"
"node": ">=10.19"
}
}

0 comments on commit 81a010c

Please sign in to comment.