From 11529394aa969d629a605e64e27aac942aafe850 Mon Sep 17 00:00:00 2001 From: YeonGyu-Kim Date: Tue, 12 May 2026 12:46:31 +0900 Subject: [PATCH] refactor(cli): use Response(stream).text() instead of Bun.readableStreamToText bun-install.ts streamToText() was reachable from the plugin bundle via the cli/config-manager barrel re-export. Replace with the WHATWG standard `new Response(stream).text()` pattern which works identically in Bun and Node and avoids the last raw Bun.* runtime call in dist/index.js. --- src/cli/config-manager/bun-install.ts | 6 +----- 1 file changed, 1 insertion(+), 5 deletions(-) diff --git a/src/cli/config-manager/bun-install.ts b/src/cli/config-manager/bun-install.ts index b744902f1..a2851d5fd 100644 --- a/src/cli/config-manager/bun-install.ts +++ b/src/cli/config-manager/bun-install.ts @@ -26,10 +26,6 @@ declare function clearTimeout(timeout: number): void type ProcessOutputStream = ReturnType["stdout"] -declare const Bun: { - readableStreamToText(stream: NonNullable): Promise -} - export interface BunInstallResult { success: boolean timedOut?: boolean @@ -50,7 +46,7 @@ function readProcessOutput(stream: ProcessOutputStream): Promise { return Promise.resolve("") } - return Bun.readableStreamToText(stream) + return new Response(stream).text() } function logCapturedOutputOnFailure(outputMode: BunInstallOutputMode, output: BunInstallOutput): void {