-
-
Notifications
You must be signed in to change notification settings - Fork 613
/
turbo.json
103 lines (96 loc) · 2.52 KB
/
turbo.json
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
{
"$schema": "https://turborepo.org/schema.json",
"tasks": {
"clean": {
"cache": false
},
"bootstrap": {
// Dummy task to enable running all bootstrap tasks
"cache": false // TypeScript does the caching
},
"codegen": {
// Dummy task to enable running all codegen tasks
},
"@zwave-js/cc#codegen": {
"outputs": [
"src/cc/index.ts",
"src/lib/API.ts",
"src/lib/Values.ts"
]
},
"@zwave-js/config#codegen": {
"outputs": ["src/LogicParser.ts"]
},
// We just define a single build script, as it turns out that
// TypeScript is just better at caching TS builds than Turbo
"//#build:turbo": {
"inputs": [
// Pick up changes to the build script
"maintenance/build.ts",
// ...and configuration
"packages/*/package.json",
"packages/*/tsconfig.json",
"packages/*/tsconfig.build.json",
// All source files are input
"packages/*/src/**",
// Exclude test files from inputs
"!*/**/*.test.ts"
],
"outputs": ["packages/*/build/**", "packages/*/*.tsbuildinfo"]
},
// Specific linting tasks: ESLint
"lint:ts": {
"dependsOn": ["bootstrap"],
"inputs": [
// https://github.com/vercel/turborepo/issues/1407
":!:build/",
"**/*.{ts,cts,mts,json}",
// The style based linting tasks depend on the corresponding configuration in the repo root
"../../eslint.config.mjs",
"../../tsconfig.all.json"
]
},
"lint:ts:fix": {
"dependsOn": ["bootstrap"],
"inputs": [
// https://github.com/vercel/turborepo/issues/1407
":!:build/",
"**/*.{ts,cts,mts,json}",
// The style based linting tasks depend on the corresponding configuration in the repo root
"../../eslint.config.mjs",
"../../tsconfig.all.json"
],
"outputs": ["**/*.{ts,cts,mts,json}"]
},
"lint:zwave": {
"dependsOn": ["bootstrap"]
// Dummy task to enable running all lint:zwave tasks
},
"@zwave-js/config#lint:zwave": {
"inputs": [
"**/*.{ts,cts,mts}",
"config/**/*.json",
"config/eslint.config.mjs"
]
},
"extract-api": {
"dependsOn": ["//#build:turbo"],
"inputs": ["src/**/*.{ts,cts,mts}", "build/**"],
"cache": false
// "outputs": [".tmp/api.md", "api.md"]
},
"test:ts": {
// "dependsOn": ["//#build:turbo"],
"inputs": ["src/**/*.{ts,cts,mts}", "vitest.config.mjs"]
// TODO: consider snapshot files
}
},
"globalDependencies": [
// Build fresh when dependencies change
"yarn.lock",
// Build fresh when TS related stuff changes
"tsconfig.json",
"tsconfig.base.json",
"tsconfig.build.json"
]
}