Skip to content

Commit

Permalink
WIP: don't clean output directory
Browse files Browse the repository at this point in the history
  • Loading branch information
sokra committed Aug 17, 2024
1 parent 5d8a7f3 commit d4c1f72
Showing 1 changed file with 4 additions and 4 deletions.
8 changes: 4 additions & 4 deletions packages/next/src/build/index.ts
Original file line number Diff line number Diff line change
Expand Up @@ -43,7 +43,7 @@ import type {
RouteHas,
} from '../lib/load-custom-routes'
import { nonNullable } from '../lib/non-nullable'
import { recursiveDelete } from '../lib/recursive-delete'
// import { recursiveDelete } from '../lib/recursive-delete'
import { verifyPartytownSetup } from '../lib/verify-partytown-setup'
import { validateTurboNextConfig } from '../lib/turbopack-warning'
import {
Expand Down Expand Up @@ -1211,9 +1211,9 @@ export default async function build(
)
}

if (config.cleanDistDir && !isGenerateMode) {
await recursiveDelete(distDir, /^cache/)
}
// if (config.cleanDistDir && !isGenerateMode) {
// await recursiveDelete(distDir, /^cache/)
// }

// Ensure commonjs handling is used for files in the distDir (generally .next)
// Files outside of the distDir can be "type": "module"
Expand Down

0 comments on commit d4c1f72

Please sign in to comment.