logoalt Hacker News

bmurphy1976today at 2:51 AM0 repliesview on HN

Good thinking. That seems to have worked. I'll have to use it in anger to see how well it holds up but so far it's working!

First Edit: it works for the CLI but may not be working for the VS Code plugin.

Second Edit: I asked Claude to look at the VS Code extension and this is what it thinks:

>Bottom line: This is a bug in the VS Code extension. The extension defines its own programmatic PreToolUse/PostToolUse hooks for diagnostics tracking and file autosaving, but these override (rather than merge with) user-defined hooks from ~/.claude/settings.json. Your ExitPlanMode hook works in the CLI because the CLI reads settings.json directly, but in VS Code the extension's hooks take precedence and yours never fire.