Repository navigation
v0.3.0
Records the working directory of the process that invoked the permcop
hook in every audit entry (text: cwd: field; JSON: "cwd" key). Omitted
when empty for backward compatibility with existing log consumers.
Motivated by a class of silent misses where implementer agents running
inside git worktrees loaded a skeleton .permcop.toml (0 rules) instead
of the parent repos .permcop.local.toml, causing all commands to fall
through as PASS. The CWD in the log makes worktree-sourced entries
immediately identifiable without manual investigation.
Both the text and JSON readers (used by suggest) parse the new field;
existing logs without a cwd: line simply leave the field empty.
Co-Authored-By: Claude Sonnet 4.6 noreply@anthropic.com
Changelog
- 442ac0e feat(audit): add CWD to log entries for worktree diagnostics