| ... | @@ -427,17 +427,16 @@ const probeClaudeCapabilities = (binaryPath: string) => { | ... | @@ -427,17 +427,16 @@ const probeClaudeCapabilities = (binaryPath: string) => { |
| 427 | ); | 427 | ); |
| 428 | }; | 428 | }; |
| 429 | | 429 | |
| 430 | const runClaudeCommand = (args: ReadonlyArray<string>) => | 430 | const runClaudeCommand = Effect.fn("runClaudeCommand")(function* (args: ReadonlyArray<string>) { |
| 431 | Effect.gen(function* () { | 431 | const claudeSettings = yield* Effect.service(ServerSettingsService).pipe( |
| 432 | const claudeSettings = yield* Effect.service(ServerSettingsService).pipe( | 432 | Effect.flatMap((service) => service.getSettings), |
| 433 | Effect.flatMap((service) => service.getSettings), | 433 | Effect.map((settings) => settings.providers.claudeAgent), |
| 434 | Effect.map((settings) => settings.providers.claudeAgent), | 434 | ); |
| 435 | ); | 435 | const command = ChildProcess.make(claudeSettings.binaryPath, [...args], { |
| 436 | const command = ChildProcess.make(claudeSettings.binaryPath, [...args], { | 436 | shell: process.platform === "win32", |
| 437 | shell: process.platform === "win32", | | |
| 438 | }); | | |
| 439 | return yield* spawnAndCollect(claudeSettings.binaryPath, command); | | |
| 440 | }); | 437 | }); |
| | 438 | return yield* spawnAndCollect(claudeSettings.binaryPath, command); |
| | 439 | }); |
| 441 | | 440 | |
| 442 | export const checkClaudeProviderStatus = Effect.fn("checkClaudeProviderStatus")(function* ( | 441 | export const checkClaudeProviderStatus = Effect.fn("checkClaudeProviderStatus")(function* ( |
| 443 | resolveSubscriptionType?: (binaryPath: string) => Effect.Effect<string | undefined>, | 442 | resolveSubscriptionType?: (binaryPath: string) => Effect.Effect<string | undefined>, |