Import packages/plugin/src/acp/adapters/isolated-process.ts
This commit is contained in:
parent
cf348c888c
commit
46226ed08b
|
|
@ -20,7 +20,7 @@ export class IsolatedAcpClient implements CursorAcpLike {
|
|||
constructor(private readonly binary: string, private readonly logger?: SafeLogger,
|
||||
private readonly options: { args?: string[]; cwd?: string; backend?: 'pi' | 'cursor' } = {},
|
||||
private readonly factory: () => CursorAcpLike = () => new CursorAcpClient(binary, logger, undefined,
|
||||
{ ...options, args: options.args ?? (options.backend === 'cursor' ? ['acp'] : []), authenticationMethod: options.backend === 'cursor' ? 'cursor_login' : null })) {}
|
||||
{ ...options, backend: options.backend ?? 'pi', args: options.args ?? (options.backend === 'cursor' ? ['acp'] : []), authenticationMethod: options.backend === 'cursor' ? 'cursor_login' : null })) {}
|
||||
|
||||
private get backend(): 'pi' | 'cursor' { return this.options.backend ?? 'pi' }
|
||||
private get label(): string { return this.backend === 'cursor' ? 'Cursor' : 'Pi' }
|
||||
|
|
|
|||
Loading…
Reference in New Issue