Skip to content

updateAgentAcp

View as Markdown
function updateAgentAcp(home, fn): Promise<{
agents: object[];
autoDetect: boolean;
consented: Record<string, {
args: string[];
cmd?: string;
env: Record<string, string>;
package?: string;
runner: "local" | "npx" | "uvx";
}>;
disable: string[];
enable: string[];
presets: "auto" | "off";
}>;

Defined in: agent/src/config.ts:291

Applies fn to runtimes.acp (e.g. uncage runtimes enable|disable: enable, consented, disable) and writes it back like updateAgentSites. Only the changed keys are rewritten, so comments elsewhere survive; agents is hand-edited and never rewritten.

Parameter Type
home string
fn (acp) => object

Promise<{ agents: object[]; autoDetect: boolean; consented: Record<string, { args: string[]; cmd?: string; env: Record<string, string>; package?: string; runner: "local" | "npx" | "uvx"; }>; disable: string[]; enable: string[]; presets: "auto" | "off"; }>