Make --yolo include hook trust bypass

Open 💬 0 comments Opened May 13, 2026 by gndk

What variant of Codex are you using?

CLI

What feature would you like to see?

Please make --yolo also enable the existing runtime-only hook trust bypass.

Today --yolo is the short form for --dangerously-bypass-approvals-and-sandbox. It sets approval_policy=never and sandbox_mode=danger-full-access, but untrusted enabled hooks still require passing --dangerously-bypass-hook-trust separately.

For the shortcut mode, it would be more ergonomic if --yolo meant "run without interactive safety prompts for this invocation", including hook trust prompts. Users who need finer-grained behavior can still use the explicit --dangerously-* flags.

Additional information

PR #21768 added --dangerously-bypass-hook-trust as an invocation-scoped escape hatch.

Expected behavior for --yolo:

  • sets the existing runtime-only bypass_hook_trust override
  • does not add a durable config.toml setting
  • does not persist hooks.state changes
  • explicitly disabled hooks remain disabled
  • startup warning mentions hook trust bypass

Use cases: ephemeral or repeated trusted dev environments where stable repo-owned hooks are already vetted by the caller, or simply living dangerously.

Related: #21768 added the separate flag

View original on GitHub ↗