mirror of
https://github.com/vitorpamplona/amethyst.git
synced 2026-10-05 19:28:25 +00:00
Wires compose_escaping_check.py into the two layers that already police the identical orphan-strings desync, mirroring pre-push-orphan-strings.sh: - the fast `lint` job in build.yml, next to the orphan check - a PreToolUse hook, so a push or PR from an agent session is gated too CI is the layer that matters here. As amethyst/src/main/res/CLAUDE.md records for the orphan desync, these arrive through bot-authored PRs -- the Crowdin sync reintroduced 2,068 escaped apostrophes across 40 locales twice in two days, with no local session anywhere in the path. Verified end to end: a payload with no push exits 0 without spawning python; a push against a clean tree exits 0; a push with values-tr-rTR restored to its pre-repair state exits 1 and names the file with a per-escape breakdown. Co-Authored-By: Claude Opus 5 (1M context) <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_01V1CzYQvWyHfipSW7x3j4Yo
49 lines
1.1 KiB
JSON
49 lines
1.1 KiB
JSON
{
|
|
"hooks": {
|
|
"PreToolUse": [
|
|
{
|
|
"matcher": "Bash|mcp__github__create_pull_request",
|
|
"hooks": [
|
|
{
|
|
"type": "command",
|
|
"command": "$CLAUDE_PROJECT_DIR/.claude/hooks/pre-push-spotless.sh",
|
|
"timeout": 180
|
|
},
|
|
{
|
|
"type": "command",
|
|
"command": "$CLAUDE_PROJECT_DIR/.claude/hooks/pre-push-orphan-strings.sh",
|
|
"timeout": 30
|
|
},
|
|
{
|
|
"type": "command",
|
|
"command": "$CLAUDE_PROJECT_DIR/.claude/hooks/pre-push-compose-escaping.sh",
|
|
"timeout": 30
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"SessionStart": [
|
|
{
|
|
"hooks": [
|
|
{
|
|
"type": "command",
|
|
"command": "$CLAUDE_PROJECT_DIR/.claude/hooks/session-start.sh"
|
|
}
|
|
]
|
|
}
|
|
],
|
|
"Stop": [
|
|
{
|
|
"matcher": "",
|
|
"hooks": [
|
|
{
|
|
"type": "command",
|
|
"command": "$CLAUDE_PROJECT_DIR/.claude/hooks/stop-spotless.sh",
|
|
"timeout": 120
|
|
}
|
|
]
|
|
}
|
|
]
|
|
}
|
|
}
|