Skip to content

Commit 5c3bfe0

Browse files
chore: upgrade deps & ESLint, drop older Node.js support
BREAKING CHANGE: Minimum supported Node.js version is now v18 and v20.
1 parent 4e3b67b commit 5c3bfe0

10 files changed

+10977
-15672
lines changed

.eslintrc.js

+16-17
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,12 @@ const os = require('os')
44

55
const lbstyle = os.platform() === 'win32' ? 'windows' : 'unix'
66

7+
/** @type {import("eslint").Linter.Config} */
78
module.exports = {
89
reportUnusedDisableDirectives: true,
910

10-
parserOptions: {
11-
ecmaVersion: 2022,
12-
},
13-
1411
extends: [
15-
'@strv/node/v16',
12+
'@strv/node/v20',
1613
'@strv/node/optional',
1714
'@strv/node/style',
1815
],
@@ -37,24 +34,30 @@ module.exports = {
3734

3835
overrides: [{
3936
files: [
40-
'src/**/*.ts',
41-
'test/**/*.ts',
42-
'test/**/*.test.ts',
37+
'**/*.ts',
4338
],
4439

4540
extends: [
46-
'@strv/node/v16',
41+
'@strv/node/v20',
4742
'@strv/node/optional',
48-
'@strv/eslint-config-typescript',
49-
'@strv/eslint-config-typescript/style',
50-
'@strv/mocha',
43+
'@strv/typescript',
44+
'@strv/typescript/style',
5145
],
5246

5347
parserOptions: {
54-
ecmaVersion: 2022,
5548
project: 'tsconfig.json',
5649
},
5750

51+
rules: {
52+
'linebreak-style': ['error', lbstyle],
53+
},
54+
}, {
55+
files: [
56+
'**/*.test.ts',
57+
],
58+
extends: [
59+
'@strv/mocha',
60+
],
5861
env: {
5962
// Disable Mocha globals which are enabled in @strv/mocha. We will import the necessary
6063
// functions directly from 'mocha' package in this project.
@@ -63,9 +66,5 @@ module.exports = {
6366
// available in test files - they are either fully available or not available at all.
6467
mocha: false,
6568
},
66-
67-
rules: {
68-
'linebreak-style': ['error', lbstyle],
69-
},
7069
}],
7170
}

.github/workflows/commitlint.yaml

+4-4
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,18 @@ on:
88

99
jobs:
1010
commitlint:
11-
runs-on: ubuntu-20.04
11+
runs-on: ubuntu-22.04
1212
timeout-minutes: 5
1313
env:
1414
CI: 'true'
1515

1616
steps:
17-
- uses: actions/checkout@v2
17+
- uses: actions/checkout@v3
1818
with:
19-
fetch-depth: 50
19+
fetch-depth: 0
2020
- uses: actions/setup-node@v3
2121
with:
22-
node-version: 18
22+
node-version: 20
2323
cache: npm
2424

2525
- run: make install

.github/workflows/deployment.yaml

+3-3
Original file line numberDiff line numberDiff line change
@@ -8,18 +8,18 @@ on:
88

99
jobs:
1010
release:
11-
runs-on: ubuntu-20.04
11+
runs-on: ubuntu-22.04
1212
timeout-minutes: 10
1313
env:
1414
CI: 'true'
1515

1616
steps:
17-
- uses: actions/checkout@v2
17+
- uses: actions/checkout@v3
1818
with:
1919
fetch-depth: 0
2020
- uses: actions/setup-node@v3
2121
with:
22-
node-version: 18
22+
node-version: 20
2323
cache: npm
2424

2525
- run: make install

.github/workflows/integration.yaml

+7-9
Original file line numberDiff line numberDiff line change
@@ -10,22 +10,20 @@ jobs:
1010
strategy:
1111
matrix:
1212
os:
13-
- ubuntu-20.04
14-
- macos-11
13+
- ubuntu-22.04
14+
- macos-13
1515
- windows-2022
1616
node:
17-
- 12
18-
- 14
19-
- 16
2017
- 18
18+
- 20
2119

2220
runs-on: ${{ matrix.os }}
2321
timeout-minutes: 10
2422
env:
2523
CI: 'true'
2624

2725
steps:
28-
- uses: actions/checkout@v2
26+
- uses: actions/checkout@v3
2927
with:
3028
fetch-depth: 0
3129
- uses: actions/setup-node@v3
@@ -42,18 +40,18 @@ jobs:
4240
run: make test
4341

4442
coverage:
45-
runs-on: ubuntu-20.04
43+
runs-on: ubuntu-22.04
4644
timeout-minutes: 10
4745
env:
4846
CI: 'true'
4947

5048
steps:
51-
- uses: actions/checkout@v2
49+
- uses: actions/checkout@v3
5250
with:
5351
fetch-depth: 0
5452
- uses: actions/setup-node@v3
5553
with:
56-
node-version: 18
54+
node-version: 20
5755

5856
- run: make install
5957
- run: make compile

0 commit comments

Comments
 (0)