Skip to content

Commit 274ca4d

Browse files
committed
fix(package): specify supported node engine to v10 (LTS)
Supported node versions the same as the Node.js LTS versions, and of course the current versions. The CI builds and tests against node v10 through v15 (latest).
1 parent 1ca51c1 commit 274ca4d

File tree

3 files changed

+14
-3
lines changed

3 files changed

+14
-3
lines changed

.github/workflows/build.yml

+10-2
Original file line numberDiff line numberDiff line change
@@ -24,27 +24,35 @@ jobs:
2424
build:
2525
runs-on: ubuntu-latest
2626
timeout-minutes: 5
27+
strategy:
28+
fail-fast: false
29+
matrix:
30+
node: [10, 12, 14, 15]
2731
steps:
2832
- name: Checkout
2933
uses: actions/[email protected]
3034
- name: Setup node
3135
uses: actions/[email protected]
3236
with:
33-
node-version: 14
37+
node-version: ${{ matrix.node }}
3438
- name: Install project
3539
run: npm ci --ignore-scripts
3640
- name: Build
3741
run: npm run build
3842
test:
3943
runs-on: ubuntu-latest
4044
timeout-minutes: 5
45+
strategy:
46+
fail-fast: false
47+
matrix:
48+
node: [10, 12, 14, 15]
4149
steps:
4250
- name: Checkout
4351
uses: actions/[email protected]
4452
- name: Setup node
4553
uses: actions/[email protected]
4654
with:
47-
node-version: 14
55+
node-version: ${{ matrix.node }}
4856
- name: Install project
4957
run: npm ci --ignore-scripts
5058
- name: Test

package.json

+3
Original file line numberDiff line numberDiff line change
@@ -41,6 +41,9 @@
4141
"url": "https://github.com/vidavidorra/commitlint-plugin-function-rules/issues"
4242
},
4343
"homepage": "https://github.com/vidavidorra/commitlint-plugin-function-rules#readme",
44+
"engines": {
45+
"node": ">=10.22.1"
46+
},
4447
"peerDependencies": {
4548
"@commitlint/lint": "9.x || 10.x || 11.x"
4649
},

tsconfig.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -5,7 +5,7 @@
55
"moduleResolution": "node",
66
"outDir": "dist",
77
"strict": true,
8-
"target": "ES2020"
8+
"target": "ES2018"
99
},
1010
"exclude": ["node_modules"],
1111
"include": ["src/**/*.ts", "test/**/*.ts"]

0 commit comments

Comments
 (0)