kaizen-agent 1.7.6 → 1.7.7
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/cli/install.ts +950 -947
- package/cli/web.ts +6 -2
- package/package.json +1 -1
package/cli/web.ts
CHANGED
|
@@ -326,7 +326,7 @@ export async function web(repoDir: string, opts: Opts = {}) {
|
|
|
326
326
|
|
|
327
327
|
// A Chromium-family browser in --app mode is a window with no tabs or address bar,
|
|
328
328
|
// which is as close to a desktop app as a web page gets. Anything else gets a tab.
|
|
329
|
-
async function openApp(url: string) {
|
|
329
|
+
export async function openApp(url: string) {
|
|
330
330
|
const chromes = process.platform === "darwin"
|
|
331
331
|
? ["Google Chrome", "Chromium", "Microsoft Edge", "Brave Browser"]
|
|
332
332
|
: process.platform === "win32"
|
|
@@ -347,7 +347,11 @@ async function openApp(url: string) {
|
|
|
347
347
|
}
|
|
348
348
|
}
|
|
349
349
|
} catch { /* fall through to a plain tab */ }
|
|
350
|
-
|
|
350
|
+
// `start` is a cmd builtin, not a program, so it has to go through cmd.
|
|
351
|
+
if (process.platform === "win32") {
|
|
352
|
+
try { await Bun.$`cmd /c start "" ${url}`.quiet(); return true; } catch { return false; }
|
|
353
|
+
}
|
|
354
|
+
const opener = process.platform === "darwin" ? "open" : "xdg-open";
|
|
351
355
|
if (!Bun.which(opener)) return false;
|
|
352
356
|
try { await Bun.$`${opener} ${url}`.quiet(); return true; } catch { return false; }
|
|
353
357
|
}
|
package/package.json
CHANGED