Skip to content

Commit 1338696

Browse files
committed
chore: fix tsconfig setup
1 parent 858bef6 commit 1338696

File tree

20 files changed

+95
-161
lines changed

20 files changed

+95
-161
lines changed

.meta-updater/src/index.ts

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -33,6 +33,7 @@ export default async (
3333
return { tagFormat: `${manifest.name}@v\${version}`, ...releaseRc }
3434
},
3535
'package.json': updatePackageJson(workspaceDir, lockfile),
36+
'tsconfig.build.json': updateTsConfig(workspaceDir, lockfile),
3637
'tsconfig.json': updateTsConfig(workspaceDir, lockfile),
3738
}
3839
}
@@ -71,6 +72,7 @@ function updateTsConfig(workspaceDir: string, lockfile: LockfileFile) {
7172

7273
const references = Object.values(deps)
7374
.filter((dep) => dep.startsWith('link:'))
75+
.filter((dep) => !dep.endsWith('tsconfig'))
7476
.map((dep) => dep.slice('link:'.length))
7577
.filter((relativePath) =>
7678
existsSync(path.join(dir, relativePath, 'tsconfig.json')),
@@ -81,6 +83,7 @@ function updateTsConfig(workspaceDir: string, lockfile: LockfileFile) {
8183

8284
return {
8385
...tsConfig,
86+
exclude: ['node_modules', 'dist'],
8487
...(references && {
8588
references: references.sort((r1, r2) => r1.path.localeCompare(r2.path)),
8689
}),

.meta-updater/tsconfig.json

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -6,5 +6,6 @@
66
"module": "ES2020"
77
},
88
"include": ["src/**/*"],
9-
"references": []
9+
"references": [],
10+
"exclude": ["node_modules", "dist"]
1011
}
Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
11
{
22
"extends": "./tsconfig.json",
3-
"exclude": [
4-
"node_modules",
5-
"**/*.test.ts",
6-
"**/vendors/**",
7-
"**/__mocks__/**",
8-
"**/test/**",
9-
"**/__tests__/**",
10-
"example/**"
3+
"exclude": ["node_modules", "dist"],
4+
"references": [
5+
{
6+
"path": "../../core"
7+
}
118
]
129
}

libs/adapters/fs-adapter/tsconfig.json

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,15 +4,11 @@
44
"outDir": "./dist",
55
"rootDir": "src"
66
},
7-
"include": [
8-
"src/**/*"
9-
],
7+
"include": ["src/**/*"],
108
"references": [
11-
{
12-
"path": "../../../tools/tsconfig"
13-
},
149
{
1510
"path": "../../core"
1611
}
17-
]
12+
],
13+
"exclude": ["node_modules", "dist"]
1814
}
Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
{
22
"extends": "./tsconfig.json",
3-
"exclude": [
4-
"node_modules",
5-
"**/*.test.ts",
6-
"**/vendors/**",
7-
"**/__mocks__/**",
8-
"**/test/**",
9-
"**/__tests__/**",
10-
"example/**"
3+
"exclude": ["node_modules", "dist"],
4+
"references": [
5+
{
6+
"path": "../../core"
7+
},
8+
{
9+
"path": "../../testing"
10+
}
1111
]
1212
}

libs/adapters/http-adapter/tsconfig.json

Lines changed: 3 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,14 @@
44
"outDir": "./dist",
55
"rootDir": "src"
66
},
7-
"include": [
8-
"src/**/*"
9-
],
7+
"include": ["src/**/*"],
108
"references": [
11-
{
12-
"path": "../../../tools/tsconfig"
13-
},
149
{
1510
"path": "../../core"
1611
},
1712
{
1813
"path": "../../testing"
1914
}
20-
]
15+
],
16+
"exclude": ["node_modules", "dist"]
2117
}
Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,9 @@
11
{
22
"extends": "./tsconfig.json",
3-
"exclude": [
4-
"node_modules",
5-
"**/*.test.ts",
6-
"**/vendors/**",
7-
"**/__mocks__/**",
8-
"**/test/**",
9-
"**/__tests__/**",
10-
"example/**"
3+
"exclude": ["node_modules", "dist"],
4+
"references": [
5+
{
6+
"path": "../../core"
7+
}
118
]
129
}

libs/adapters/s3-adapter/tsconfig.json

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,18 +4,11 @@
44
"outDir": "dist",
55
"rootDir": "src"
66
},
7-
"include": [
8-
"src/**/*",
9-
"__tests__/**/*",
10-
"example/**/*",
11-
"__mocks__/**/*"
12-
],
7+
"include": ["src/**/*", "__tests__/**/*", "example/**/*", "__mocks__/**/*"],
138
"references": [
14-
{
15-
"path": "../../../tools/tsconfig"
16-
},
179
{
1810
"path": "../../core"
1911
}
20-
]
12+
],
13+
"exclude": ["node_modules", "dist"]
2114
}

libs/client/tsconfig.build.json

Lines changed: 8 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -1,12 +1,12 @@
11
{
22
"extends": "./tsconfig.json",
3-
"exclude": [
4-
"node_modules",
5-
"**/*.test.ts",
6-
"**/vendors/**",
7-
"**/__mocks__/**",
8-
"**/test/**",
9-
"**/__tests__/**",
10-
"example/**"
3+
"exclude": ["node_modules", "dist"],
4+
"references": [
5+
{
6+
"path": "../common"
7+
},
8+
{
9+
"path": "../config"
10+
}
1111
]
1212
}

libs/client/tsconfig.json

Lines changed: 3 additions & 10 deletions
Original file line numberDiff line numberDiff line change
@@ -4,21 +4,14 @@
44
"outDir": "./dist",
55
"rootDir": "src"
66
},
7-
"include": [
8-
"src/**/*",
9-
"__tests__/**/*",
10-
"example/**/*",
11-
"__mocks__/**/*"
12-
],
7+
"include": ["src/**/*", "__tests__/**/*", "example/**/*", "__mocks__/**/*"],
138
"references": [
14-
{
15-
"path": "../../tools/tsconfig"
16-
},
179
{
1810
"path": "../common"
1911
},
2012
{
2113
"path": "../config"
2214
}
23-
]
15+
],
16+
"exclude": ["node_modules", "dist"]
2417
}

0 commit comments

Comments
 (0)