{
  "hooks": {
    "PostToolUse": [
      {
        "matcher": "Write|Edit",
        "hooks": [
          {
            "type": "command",
            "command": "node -e 'let d=\"\";process.stdin.on(\"data\",c=>d+=c);process.stdin.on(\"end\",()=>{try{const j=JSON.parse(d);const fp=(j.tool_input&&j.tool_input.file_path)||(j.tool_response&&j.tool_response.filePath)||\"\";const path=require(\"path\");const b=path.win32.basename(fp);let o=null;if(b===\"CLAUDE.md\")o=\"AGENTS.md\";else if(b===\"AGENTS.md\")o=\"CLAUDE.md\";if(o){console.log(JSON.stringify({systemMessage:b+\" changed — remember to mirror the update into \"+o+\" so both stay in sync.\",hookSpecificOutput:{hookEventName:\"PostToolUse\",additionalContext:b+\" was just modified. Check whether the same change should be mirrored into \"+o+\" (using its own phrasing) so the two files stay consistent.\"}}));}}catch(e){}});' 2>/dev/null || true",
            "timeout": 15
          }
        ]
      }
    ]
  }
}
