pub fn run()Expand description
apm path-guard — PreToolUse hook called by Claude Code before every
Edit, Write, and Bash tool invocation.
Reads a JSON payload from stdin:
{"tool_name": "Edit", "tool_input": {"file_path": "/some/path"}}Exit codes:
- 0: tool call allowed
- 2: tool call blocked; rejection message printed to stdout