Skip to content

Commit 4785b1a

Browse files
authored
Update tsconfig and workflow (JaylyDev#158)
1 parent ff82e8f commit 4785b1a

4 files changed

Lines changed: 25 additions & 10 deletions

File tree

.github/workflows/cl.yml

Lines changed: 11 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -24,6 +24,12 @@ jobs:
2424
- name: Build tsc
2525
run: tsc --build --verbose
2626

27+
- name: Commit changes
28+
if: ${{ github.event_name == 'push' }}
29+
uses: EndBug/add-and-commit@v9
30+
with:
31+
add: ./scripts
32+
2733
format-check:
2834
name: 'Format Check'
2935
runs-on: ubuntu-latest
@@ -43,8 +49,9 @@ jobs:
4349

4450
- name: Format Check
4551
run: node ./tools/index.js
46-
47-
- uses: actions/upload-artifact@v3
52+
53+
- name: Commit changes
54+
if: ${{ github.event_name == 'push' }}
55+
uses: EndBug/add-and-commit@v9
4856
with:
49-
name: README files
50-
path: node_modules/.cache
57+
add: ./scripts

scripts/jsconfig.json

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,8 @@
1+
{
2+
"compilerOptions": {
3+
"allowJs": true,
4+
"checkJs": true,
5+
"noEmit": true,
6+
},
7+
"extends": "./tsconfig.json"
8+
}

scripts/tsconfig.json

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,6 @@
11
{
22
"compilerOptions": {
3-
"allowJs": true,
4-
"checkJs": true,
3+
// script environment
54
"module": "es2020",
65
"target": "es2021",
76
"moduleResolution": "classic",
@@ -18,8 +17,8 @@
1817
},
1918
"types": [],
2019
"typeRoots": [],
21-
// debug purpsoses
22-
"noEmit": true,
20+
"declaration": true,
21+
// repository config
2322
"diagnostics": true,
24-
},
23+
}
2524
}

tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,7 @@
33
"exclude": [ "docs", "node_modules" ],
44
"references": [
55
{ "path": "tools" },
6-
{ "path": "scripts" }
6+
{ "path": "scripts/tsconfig.json" },
7+
{ "path": "scripts/jsconfig.json" }
78
]
89
}

0 commit comments

Comments
 (0)