From 18328ce615fb7a2e1defd1bce911f50f68ec1c61 Mon Sep 17 00:00:00 2001 From: Turtle Date: Mon, 10 Aug 2026 19:59:24 +0800 Subject: [PATCH] refactor(cli): remove the unused profile preparation hook --- apps/cli/src/profile-boot.ts | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/apps/cli/src/profile-boot.ts b/apps/cli/src/profile-boot.ts index a3159d4f49..4d7b525d07 100644 --- a/apps/cli/src/profile-boot.ts +++ b/apps/cli/src/profile-boot.ts @@ -191,8 +191,6 @@ export interface RunProfileOptions { patchFiles: readonly string[] /** The invocation's inner arguments, handed to the tree through `ctx.cmdlineArgs`. */ args: readonly string[] - /** Host setup registered after Loader installation and before any config-tree entry mounts. */ - prepare?: (ctx: Context) => Promise | void } /** Re-throw setup failures unless this invocation's signal already owns shutdown. */ @@ -271,7 +269,7 @@ export async function runProfile(options: RunProfileOptions): Promise<{ ctx: Con const watchProfilePatch = !oneShot // Cloned for the same insert-aliasing reason as composeLive: the boot // application must not mutate the objects later reloads recompose from. - const ctx = await boot(NAME, rootConfig, structuredClone(allPatches(composed)), async (hostCtx) => { + const ctx = await boot(NAME, rootConfig, structuredClone(allPatches(composed)), (hostCtx) => { app.current = hostCtx // Before any config-tree entry mounts, so plugins resolve all launch-time // environment values from the same immutable provenance snapshot. @@ -292,7 +290,6 @@ export async function runProfile(options: RunProfileOptions): Promise<{ ctx: Con } hostCtx.provide('headlessIo', io) } - await options.prepare?.(hostCtx) }).catch((cause: unknown) => { bootFailed(cause) throw cause