add support for EXPERIMENTAL_TURBOPACK in next build (#53535)

### What?

EXPERIMENTAL_TURBOPACK env var puts next build into turbopack mode

### Why?

the test cases set this flag
This commit is contained in:
Tobias Koppers 2023-08-04 07:27:06 +02:00 committed by GitHub
parent 57ce466502
commit 82280ea82b
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -69,7 +69,7 @@ const nextBuild: CliCommand = (argv) => {
printAndExit(`> No such directory exists as the project root: ${dir}`)
}
if (args['--experimental-turbo']) {
if (args['--experimental-turbo'] || process.env.EXPERIMENTAL_TURBOPACK) {
process.env.TURBOPACK = '1'
}