Skip to content

Commit 3aaf878

Browse files
authored
refactor!: drops support for 10 (#421)
1 parent 54c0d2c commit 3aaf878

File tree

5 files changed

+7
-7
lines changed

5 files changed

+7
-7
lines changed

.github/workflows/ci.yaml

+2-2
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@ jobs:
1010
runs-on: ubuntu-latest
1111
strategy:
1212
matrix:
13-
node: [10, 12, 14]
13+
node: [12, 14, 16]
1414
steps:
1515
- uses: actions/checkout@v1
1616
- uses: actions/setup-node@v1
@@ -86,6 +86,6 @@ jobs:
8686
- uses: actions/checkout@v2
8787
- uses: actions/setup-node@v1
8888
with:
89-
node-version: 14
89+
node-version: 16
9090
- run: cd test/tscc && npm install && npx @tscc/tscc
9191
- run: cd test/tscc && node out.js

lib/index.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ import { YargsParser } from './yargs-parser.js'
1818
// version support policy. The YARGS_MIN_NODE_VERSION is used for testing only.
1919
const minNodeVersion = (process && process.env && process.env.YARGS_MIN_NODE_VERSION)
2020
? Number(process.env.YARGS_MIN_NODE_VERSION)
21-
: 10
21+
: 12
2222
if (process && process.version) {
2323
const major = Number(process.version.match(/v([^.]+)/)![1])
2424
if (major < minNodeVersion) {

lib/yargs-parser.ts

+2-2
Original file line numberDiff line numberDiff line change
@@ -681,7 +681,7 @@ export class YargsParser {
681681
}
682682

683683
setConfigObject(config)
684-
} catch (ex) {
684+
} catch (ex: any) {
685685
// Deno will receive a PermissionDenied error if an attempt is
686686
// made to load config without the --allow-read flag:
687687
if (ex.name === 'PermissionDenied') error = ex
@@ -759,7 +759,7 @@ export class YargsParser {
759759
argv[ali] = value
760760
})
761761
} catch (err) {
762-
error = err
762+
error = err as Error
763763
}
764764
}
765765
}

package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -77,7 +77,7 @@
7777
"!*.d.ts"
7878
],
7979
"engines": {
80-
"node": ">=10"
80+
"node": ">=12"
8181
},
8282
"standardx": {
8383
"ignore": [

test/tscc/package.json

+1-1
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
"name": "optimized-test",
33
"version": "0.0.0",
44
"dependencies": {
5-
"@tscc/tscc": "^0.6.4",
5+
"@tscc/tscc": "^0.7.4",
66
"@types/node": "^10.0.3"
77
}
88
}

0 commit comments

Comments
 (0)