mirror of
https://github.com/google-gemini/gemini-cli.git
synced 2026-08-09 00:16:57 -07:00
feat(agents): use inject completion behavior for remote agent backgrounding
Set completionBehavior: 'inject' on remote agent executions so their full output is reinjected into the conversation when they complete in the background, and the task auto-dismisses from the Ctrl+B panel.
This commit is contained in:
@@ -850,6 +850,7 @@ describe('RemoteAgentInvocation', () => {
|
||||
const info = bgListener.mock.calls[0][0];
|
||||
expect(info.executionId).toBe(capturedExecutionId);
|
||||
expect(info.executionMethod).toBe('remote_agent');
|
||||
expect(info.completionBehavior).toBe('inject');
|
||||
expect(info.injectionText).toContain(
|
||||
"Remote agent 'Test Agent' completed successfully",
|
||||
);
|
||||
|
||||
@@ -149,6 +149,7 @@ export class RemoteAgentInvocation extends BaseToolInvocation<
|
||||
return output ? `${header}\nOutput:\n${output}` : header;
|
||||
},
|
||||
agentLabel,
|
||||
'inject',
|
||||
);
|
||||
// createExecution always produces a valid numeric ID
|
||||
const executionId = handle.pid!;
|
||||
|
||||
Reference in New Issue
Block a user