perf(deploy): keep .next/cache while clearing stale generated types
Nuclear src replace already guarantees clean sources; restoring the build cache speeds deploys without reintroducing sticky typecheck ghosts. Co-authored-by: Cursor <[email protected]>
This commit is contained in:
1 parent
b7fd19b6d9
commit
224ccd654b
2 files changed
+7
-4
No files matched your search
@@ -8,8 +8,10 @@ describe("production deploy workflow", () => {
|
||||
"utf8",
|
||||
);
|
||||
|
||||
it("wipes .next before build to avoid stale Next typecheck caches", () => {
|
||||
expect(workflow).toContain("rm -rf .output dist .next");
|
||||
it("preserves the Next.js incremental build cache", () => {
|
||||
// May clear .next/types or .next/dev, but must not wipe the whole .next tree.
|
||||
expect(workflow).not.toMatch(/rm\s+-rf\s+\.next(?:\s|$)/);
|
||||
expect(workflow).toContain("rm -rf .output dist .next/types .next/dev");
|
||||
expect(workflow).toContain("pnpm install --frozen-lockfile");
|
||||
expect(workflow).toContain("SKIP_ENV_VALIDATION=1");
|
||||
});
|
||||
|
||||
Reference in new issue
Block a user