File tree Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Expand file tree Collapse file tree 2 files changed +10
-2
lines changed Original file line number Diff line number Diff line change 1+ ---
2+ " open-next " : patch
3+ ---
4+
5+ add support for bun lockfile
Original file line number Diff line number Diff line change @@ -170,6 +170,7 @@ function findMonorepoRoot(appPath: string) {
170170 { file : "package-lock.json" , packager : "npm" as const } ,
171171 { file : "yarn.lock" , packager : "yarn" as const } ,
172172 { file : "pnpm-lock.yaml" , packager : "pnpm" as const } ,
173+ { file : "bun.lockb" , packager : "bun" as const } ,
173174 ] . find ( ( f ) => fs . existsSync ( path . join ( currentPath , f . file ) ) ) ;
174175
175176 if ( found ) {
@@ -201,11 +202,13 @@ function setStandaloneBuildMode(monorepoRoot: string) {
201202 process . env . NEXT_PRIVATE_OUTPUT_TRACE_ROOT = monorepoRoot ;
202203}
203204
204- function buildNextjsApp ( packager : "npm" | "yarn" | "pnpm" ) {
205+ function buildNextjsApp ( packager : "npm" | "yarn" | "pnpm" | "bun" ) {
205206 const { nextPackageJsonPath } = options ;
206207 const command =
207208 options . buildCommand ??
208- ( packager === "npm" ? "npm run build" : `${ packager } build` ) ;
209+ ( [ "bun" , "npm" ] . includes ( packager )
210+ ? `${ packager } run build`
211+ : `${ packager } build` ) ;
209212 cp . execSync ( command , {
210213 stdio : "inherit" ,
211214 cwd : path . dirname ( nextPackageJsonPath ) ,
You can’t perform that action at this time.
0 commit comments