forked from multica-ai/multica
-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathturbo.json
More file actions
71 lines (71 loc) · 2.87 KB
/
Copy pathturbo.json
File metadata and controls
71 lines (71 loc) · 2.87 KB
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
{
"$schema": "https://turbo.build/schema.json",
// The CI workflow pins the toolchain these tasks run under (Node 22 today).
// Without it in the global hash, bumping that version would replay cached
// typecheck/test results produced by the old runtime and hide an
// incompatibility behind a green check.
"globalDependencies": [".github/workflows/ci.yml"],
"globalEnv": [
"DATABASE_URL",
"PORT",
"FRONTEND_PORT",
"FRONTEND_ORIGIN",
"NEXT_PUBLIC_API_URL",
"NEXT_PUBLIC_WS_URL",
"MULTICA_SERVER_URL",
"DOCS_URL",
"COMPOSE_PROJECT_NAME",
"POSTGRES_DB",
"POSTGRES_PORT",
"DESKTOP_RENDERER_PORT",
"DESKTOP_APP_SUFFIX"
],
"tasks": {
"build": {
"dependsOn": ["^build"],
// No explicit `inputs`: turbo's default (every git-tracked file in the
// package) is the only safe hash source now that the cache is actually
// restored in CI. The previous narrow glob list matched neither
// `content/**/*.mdx` (compiled by fumadocs-mdx during the build),
// `public/**` assets, nor `package.json` / `tsconfig.json`, so the task
// hash was unchanged by edits to any of them -- harmless while nothing
// was ever cached, a stale-build bug the moment it is.
"outputs": [".next/**", "!.next/cache/**", "dist/**", "out/**"]
},
"dev": {
"cache": false,
"persistent": true
},
"dev:staging": {
"cache": false,
"persistent": true
},
"typecheck": {
"dependsOn": ["^typecheck"]
},
// Hash-only transit task. No package implements a `cache-inputs` script,
// so every node resolves to <NONEXISTENT> and nothing is ever executed --
// but the edges still pull each dependency's file hashes into whatever
// depends on it. `dependsOn: ["^cache-inputs"]` makes that recursive, so
// the chain stays complete if a package ever gains a purely transitive
// dependency. This exists because a turbo task hash covers a workspace
// dependency's sources only when a task edge reaches them.
"cache-inputs": {
"dependsOn": ["^cache-inputs"]
},
// Without a dependency edge, editing packages/views or packages/ui left
// `@multica/web#test` and `@multica/desktop#test` byte-identical in hash,
// so a cached pass would be replayed over changed code. `^cache-inputs`
// closes that without side effects: `^typecheck` would also work but drags
// three real `tsc --noEmit` runs (~223 CPU-seconds) into the test job, and
// `^test` would serialise the suites behind each other.
"test": {
"dependsOn": ["^cache-inputs"]
},
// `lint` keeps no dependency edge: eslint here is not type-aware (no
// `projectService` / `parserOptions.project` anywhere in
// packages/eslint-config), so it only ever reads its own package's files
// and a dependency's source cannot change its result.
"lint": {}
}
}