feat(coding-agent): support AGENTS.override.md (#7681)

This commit is contained in:
m3 2026-08-05 15:24:31 -04:00 • committed by GitHub
parent 3852cb2b81
commit 8ecf8a9883
No known key found for this signature in database
GPG key ID: B5690EEEBB952194
8 changed files with 41 additions and 5 deletions

View file

@ -24,7 +24,7 @@ Trusting a project allows pi to load project resources that require trust, inclu
- missing project packages configured through project settings
- project-local extensions and project package-managed extensions
Declining trust skips protected resources. `AGENTS.md` and `CLAUDE.md` context files are loaded regardless of project trust unless context loading is disabled. Before trust is resolved, pi only loads context files, user/global extensions, and CLI `-e` extensions. User/global and CLI extensions can handle the `project_trust` event; the first extension that returns a yes/no decision owns the decision.
Declining trust skips protected resources. Context files such as `AGENTS.override.md`, `AGENTS.md`, and `CLAUDE.md` are loaded regardless of project trust unless context loading is disabled. Before trust is resolved, pi only loads context files, user/global extensions, and CLI `-e` extensions. User/global and CLI extensions can handle the `project_trust` event; the first extension that returns a yes/no decision owns the decision.
Non-interactive modes (`-p`, `--mode json`, and `--mode rpc`) do not show a trust prompt. Without an applicable saved trust decision, `defaultProjectTrust: "ask"` and `"never"` ignore such resources, while `"always"` trusts them. Use `--approve`/`-a` or `--no-approve`/`-na` to override project trust for one run.