diff options
| author | Brendan Allan <[email protected]> | 2026-03-23 16:44:23 +0800 |
|---|---|---|
| committer | GitHub <[email protected]> | 2026-03-23 08:44:23 +0000 |
| commit | 4c27e7fc6499dee385e718d523c4f0612bd8a063 (patch) | |
| tree | 2a48fd9ae771c083653a9d68a1d239df42d91aab /packages/desktop-electron/src/main/cli.ts | |
| parent | 0f5626d2e46f9f8abfe616a33a4fd4f4d989e396 (diff) | |
| download | opencode-4c27e7fc6499dee385e718d523c4f0612bd8a063.tar.gz opencode-4c27e7fc6499dee385e718d523c4f0612bd8a063.zip | |
electron: more robust sidecar kill handling (#18742)
Diffstat (limited to 'packages/desktop-electron/src/main/cli.ts')
| -rw-r--r-- | packages/desktop-electron/src/main/cli.ts | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/packages/desktop-electron/src/main/cli.ts b/packages/desktop-electron/src/main/cli.ts index fba301f36..f2d918bd2 100644 --- a/packages/desktop-electron/src/main/cli.ts +++ b/packages/desktop-electron/src/main/cli.ts @@ -35,6 +35,7 @@ export type CommandEvent = export type SqliteMigrationProgress = { type: "InProgress"; value: number } | { type: "Done" } export type CommandChild = { + pid: number | undefined kill: () => void } @@ -191,7 +192,7 @@ export function spawnCommand(args: string, extraEnv: Record<string, string>) { treeKill(child.pid) } - return { events, child: { kill }, exit } + return { events, child: { pid: child.pid, kill }, exit } } function handleSqliteProgress(events: EventEmitter, line: string) { |
