fix(review): keep the reviewed checkout off the reviewer's PATH

Commit

peyton-alt1w ago

sanitizeReviewEnv dropped relative PATH entries but then prepended the running binary's directory unconditionally. When entire is built into the repo root (this repo's own build tasks do that), that put the reviewed checkout at the front of PATH, so every hook resolved git/sh/node from branch content first. Skip the prepend, and drop any absolute PATH entry, when it lies inside the reviewed worktree. Symlinks are resolved through the nearest existing ancestor so a not-yet-created dir cannot slip past.

Co-Authored-By: Claude Opus 5.5 noreply@anthropic.com Entire-Checkpoint: 01M3N82VEJZ9YPEMFMEZ31GQ6K

Checkpoints

Fix Claude Code Hook Installation and Review Launch

Claude CodeOpus 5.5
View session
Checkpoint 1