From ad971db92bb785290ab0d60fefb240298e9d6f12 Mon Sep 17 00:00:00 2001 From: "Pablo T. de Vargas" Date: Tue, 21 Jul 2026 13:14:56 -0300 Subject: [PATCH] fix(hooks): add matcher to UserPromptSubmit to skip no-op invocations Without a matcher the hook fires on every prompt, spawning a PowerShell process + Node.js startup on Windows even when the prompt has nothing to do with ponytail. On slower machines or under antivirus load this easily exceeds the 5 s timeout and the hook output is silently discarded. The mode-tracker only acts on prompts that contain "ponytail" (commands like /ponytail, @ponytail, $ponytail, "stop ponytail") or the exact deactivation phrase "normal mode". Adding that as the matcher means the hook is skipped entirely for all other prompts. --- hooks/claude-codex-hooks.json | 1 + 1 file changed, 1 insertion(+) diff --git a/hooks/claude-codex-hooks.json b/hooks/claude-codex-hooks.json index b685fd53..8bcf1cfe 100644 --- a/hooks/claude-codex-hooks.json +++ b/hooks/claude-codex-hooks.json @@ -29,6 +29,7 @@ ], "UserPromptSubmit": [ { + "matcher": "ponytail|normal mode", "hooks": [ { "type": "command",