Description
The three hooks in .claude/settings.json grep $CLAUDE_TOOL_INPUT for .po". Claude Code doesn't set that variable; it sends the tool call as JSON on stdin (hooks reference: https://code.claude.com/docs/en/hooks). So the grep never matches and none of the reminders print.
Fixing the variable alone isn't enough: for PreToolUse and PostToolUse, plain stdout on exit 0 goes to the debug log, not to Claude. To reach Claude, the hook returns the text as additionalContext. For the PreToolUse one (needs jq):
"command": "case \"$(jq -r '.tool_input.file_path // empty')\" in *.po) echo '{\"hookSpecificOutput\":{\"hookEventName\":\"PreToolUse\",\"additionalContext\":\"[Translation Context] Remember: Use skills translate-po, terminology-check, validate-translation. Check doc-translate/references/terminology.md for terms.\"}}' ;; esac"The two PostToolUse hooks are the same with "hookEventName":"PostToolUse" and their own text. Tested with the JSON Claude Code sends for an Edit to library/os.po: before, no output; after, the JSON above, and an edit to a .py file prints nothing.
Found this while testing Claude Code hooks for Paveo; uvx paveo doctor flags all three. Happy to open a PR with the fix.
Activity