add trust hooks CLI flag

This commit is contained in:
Abhinav Vedmala
2026-05-08 11:53:06 -04:00
parent 163eac9306
commit 9f82e113cd
13 changed files with 166 additions and 10 deletions

View File

@@ -155,6 +155,7 @@ fn mark_exec_global_args(cmd: clap::Command) -> clap::Command {
.mut_arg("dangerously_bypass_approvals_and_sandbox", |arg| {
arg.global(true)
})
.mut_arg("trust_hooks", |arg| arg.global(true))
}
#[derive(Debug, clap::Subcommand)]

View File

@@ -265,6 +265,7 @@ pub async fn run_main(cli: Cli, arg0_paths: Arg0DispatchPaths) -> anyhow::Result
config_profile,
sandbox_mode: sandbox_mode_cli_arg,
dangerously_bypass_approvals_and_sandbox,
trust_hooks,
cwd,
add_dir,
} = shared;
@@ -423,6 +424,7 @@ pub async fn run_main(cli: Cli, arg0_paths: Arg0DispatchPaths) -> anyhow::Result
show_raw_agent_reasoning: oss.then_some(true),
tools_web_search_request: None,
ephemeral: ephemeral.then_some(true),
trust_hooks: trust_hooks.then_some(true),
additional_writable_roots: add_dir,
};