Skip to content

The ultimate harness for coding agents and beyond. All your agents. All your machines. One command center. Start with code, then follow your curiosity and build across disciplines: CAD, circuits, robots, games and music.

416 KB
Raw Blame
{
 "texts": {
  "f46cc82e93ac3dd3": "{\n  \"hooks\": {\n    \"sessionStart\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"beforeSubmitPrompt\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"preToolUse\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"stop\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"sessionEnd\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ]\n  },\n  \"version\": 1\n}\n",
  "e3b0c44298fc1c14": "",
  "8855c6119660c614": "  \n",
  "f1dec6e9ee608550": "{not-json",
  "aa25e978046d680e": "{}",
  "74234e98afe7498f": "null",
  "37517e5f3dc66819": "[]\n",
  "1e1d0f251d3a76fa": "\"text\"",
  "73475cb40a568e8d": "42",
  "1c2aeaac473dca87": "{\n  \"hooks\": {\n    \"sessionStart\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"beforeSubmitPrompt\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"preToolUse\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"stop\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"sessionEnd\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ]\n  },\n  \"keep\": 1,\n  \"version\": 1\n}\n",
  "d05ad8cb738b0c1f": "{\n  \"hooks\": [],\n  \"version\": 1\n}\n",
  "8f5114f5734c2d24": "{\n  \"version\": 1,\n  \"note\": \"café ✓\",\n  \"hooks\": {\n    \"sessionStart\": [\n      {\n        \"command\": \"foreign-start\"\n      },\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"afterFileEdit\": [\n      {\n        \"command\": \"foreign-edit\"\n      }\n    ],\n    \"beforeSubmitPrompt\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"preToolUse\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"stop\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ],\n    \"sessionEnd\": [\n      {\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\n        \"failClosed\": false\n      }\n    ]\n  }\n}\n",
  "e161f02becaa47e8": "{\"hooks\":{\"sessionStart\":[{\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\"failClosed\":false}],\"beforeSubmitPrompt\":[{\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\"failClosed\":false}],\"preToolUse\":[{\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\"failClosed\":false}],\"stop\":[{\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\"failClosed\":false}],\"sessionEnd\":[{\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine cursor\",\"failClosed\":false}]},\"version\":1}",
  "d979437596e2baaf": "{\n  \"version\": 1,\n  \"note\": \"café ✓\",\n  \"hooks\": {\n    \"sessionStart\": [\n      {\n        \"command\": \"foreign-start\"\n      }\n    ],\n    \"afterFileEdit\": [\n      {\n        \"command\": \"foreign-edit\"\n      }\n    ]\n  }\n}\n",
  "3cd1ae59e87ad8ec": "// someone else's plugin\nexport default {}\n",
  "2351a62515202212": "// someone else's extension\nexport default function () {}\n",
  "f2535bcde1fe8de5": "// someone else's plugin\nexport default function () {}\n",
  "988dbdec0e4eb48d": "\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "1b00ee446739f819": "{\n  \"approvals\": [\n    {\n      \"event\": \"on_session_start\",\n      \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n    },\n    {\n      \"event\": \"pre_llm_call\",\n      \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n    }\n  ]\n}\n",
  "a55a637998fe4b15": "{not-json\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "c51e46f6c146b98d": "{}\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "194131200b79cf44": "null\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "2415375113d9c3b5": "[]\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "9d989f72a32a29d0": "\"text\"\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "e02d1147e6ef16f8": "42\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "ec7d064fd8392cd4": "{\"hooks\":\"nope\",\"keep\":1}\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "962dfe8b12a6ae73": "{\"hooks\":[]}\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "c1a3d9684ed05172": "{\"hooks\":null}\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "3ddcb721806eb9ef": "model: anthropic/claude\ntoolsets:\n  - web\n  - terminal\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "f8dc5cc189f51bc0": "model: x\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "7e98aa9bd960a936": "model: anthropic/claude\ntoolsets:\n  - web\n  - terminal\n",
  "ef875a1705a5fdac": "junk",
  "7f0a907cf4b87d22": "model: x\nhooks:\n  on_session_start:\n    - command: \"foreign-hook\"\n",
  "4632a48e3e660bef": "model: y\n\n# machine-adapter: session discovery (managed block — safe to delete)\nhooks:\n  on_session_start:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes/profiles/work' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n  pre_llm_call:\n    - command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes/profiles/work' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n      timeout: 10\n# machine-adapter: end\n",
  "cbf0d4d9801fa8ab": "{\n  \"approvals\": [\n    {\n      \"event\": \"on_session_start\",\n      \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes/profiles/work' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n    },\n    {\n      \"event\": \"pre_llm_call\",\n      \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes/profiles/work' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\"\n    }\n  ]\n}\n",
  "139af7531520d198": "{\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"UserPromptSubmit\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"SessionEnd\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "39001c2ca3ede641": "{\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"UserPromptSubmit\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"SessionEnd\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  },\n  \"keep\": 1\n}\n",
  "527e053b72e46170": "{\n  \"hooks\": []\n}\n",
  "0dfbbe04f73adf3d": "{\n  \"devin\": {\n    \"org_id\": \"org-1\"\n  },\n  \"theme_mode\": \"dark\",\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-start\"\n          }\n        ]\n      },\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"PreToolUse\": [\n      {\n        \"matcher\": \"Bash\",\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-tool\"\n          }\n        ]\n      }\n    ],\n    \"UserPromptSubmit\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"SessionEnd\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "5a8f51f91dde0a5b": "{\"hooks\":{\"SessionStart\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\"timeout\":5}]}],\"UserPromptSubmit\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\"timeout\":5}]}],\"Stop\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\"timeout\":5}]}],\"SessionEnd\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine devin\",\"timeout\":5}]}]}}",
  "6d5b174c2e259967": "{\n  \"devin\": {\n    \"org_id\": \"org-1\"\n  },\n  \"theme_mode\": \"dark\",\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-start\"\n          }\n        ]\n      }\n    ],\n    \"PreToolUse\": [\n      {\n        \"matcher\": \"Bash\",\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-tool\"\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "e6ba49d50df273e3": "{\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"PreToolUse\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "49b2b24292764fcd": "{\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"PreToolUse\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  },\n  \"keep\": 1\n}\n",
  "32816609de0e4204": "{\n  \"model\": \"x\",\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"matcher\": \"resume\",\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-start\",\n            \"timeout\": 9\n          }\n        ]\n      },\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"PostToolUse\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-post\"\n          }\n        ]\n      }\n    ],\n    \"PreToolUse\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "af11bf73d6bcc670": "{\"hooks\":{\"SessionStart\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\"timeout\":5}]}],\"PreToolUse\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\"timeout\":5}]}],\"Stop\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine commandcode\",\"timeout\":5}]}]}}",
  "d22cca3856723e32": "{\n  \"model\": \"x\",\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"matcher\": \"resume\",\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-start\",\n            \"timeout\": 9\n          }\n        ]\n      }\n    ],\n    \"PostToolUse\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-post\"\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "fdf01705b60e85fe": "{\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"SessionEnd\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"UserPromptSubmit\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"StopFailure\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "a96e546fddafe1ca": "{\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"SessionEnd\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"UserPromptSubmit\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"StopFailure\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  },\n  \"keep\": 1\n}\n",
  "78cc36f86512ef3a": "{\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-start\"\n          }\n        ]\n      },\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-stop\"\n          }\n        ]\n      }\n    ],\n    \"SessionEnd\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"UserPromptSubmit\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ],\n    \"StopFailure\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\n            \"timeout\": 5\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "70e69a09d8231b2e": "{\"hooks\":{\"SessionStart\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\"timeout\":5}]}],\"SessionEnd\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\"timeout\":5}]}],\"UserPromptSubmit\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\"timeout\":5}]}],\"StopFailure\":[{\"hooks\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine grok\",\"timeout\":5}]}]}}",
  "2a9811d493ce83b8": "{\n  \"hooks\": {\n    \"SessionStart\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-start\"\n          }\n        ]\n      }\n    ],\n    \"Stop\": [\n      {\n        \"hooks\": [\n          {\n            \"type\": \"command\",\n            \"command\": \"foreign-stop\"\n          }\n        ]\n      }\n    ]\n  }\n}\n",
  "49e01513b7aa4e4b": "{\n  \"harness\": {\n    \"PreInvocation\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event PreInvocation\",\n        \"timeout\": 10\n      }\n    ],\n    \"Stop\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event Stop\",\n        \"timeout\": 10\n      }\n    ]\n  }\n}\n",
  "a9f7351b00036d4d": "{\n  \"hooks\": \"nope\",\n  \"keep\": 1,\n  \"harness\": {\n    \"PreInvocation\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event PreInvocation\",\n        \"timeout\": 10\n      }\n    ],\n    \"Stop\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event Stop\",\n        \"timeout\": 10\n      }\n    ]\n  }\n}\n",
  "16151c74ec74cbf0": "{\n  \"hooks\": [],\n  \"harness\": {\n    \"PreInvocation\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event PreInvocation\",\n        \"timeout\": 10\n      }\n    ],\n    \"Stop\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event Stop\",\n        \"timeout\": 10\n      }\n    ]\n  }\n}\n",
  "fccdf49d2cc702e9": "{\n  \"hooks\": null,\n  \"harness\": {\n    \"PreInvocation\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event PreInvocation\",\n        \"timeout\": 10\n      }\n    ],\n    \"Stop\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event Stop\",\n        \"timeout\": 10\n      }\n    ]\n  }\n}\n",
  "36167d06eb75fd75": "{\n  \"theirs\": {\n    \"enabled\": true,\n    \"Stop\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"foreign-stop\"\n      }\n    ]\n  },\n  \"harness\": {\n    \"PreInvocation\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event PreInvocation\",\n        \"timeout\": 10\n      }\n    ],\n    \"Stop\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event Stop\",\n        \"timeout\": 10\n      }\n    ]\n  }\n}\n",
  "aa2b391f4878627a": "{\"harness\":{\"PreInvocation\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event PreInvocation\",\"timeout\":10}],\"Stop\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine agy --agy-event Stop\",\"timeout\":10}]}}",
  "ea6df51da052bef4": "{\n  \"theirs\": {\n    \"enabled\": true,\n    \"Stop\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"foreign-stop\"\n      }\n    ]\n  }\n}\n",
  "f1d871558bc6b03b": "{\n  \"version\": 1,\n  \"hooks\": {\n    \"sessionStart\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine copilot --copilot-event sessionStart\"\n      }\n    ],\n    \"userPromptSubmitted\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine copilot --copilot-event userPromptSubmitted\"\n      }\n    ],\n    \"agentStop\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine copilot --copilot-event agentStop\"\n      }\n    ],\n    \"sessionEnd\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine copilot --copilot-event sessionEnd\"\n      }\n    ]\n  }\n}\n",
  "df185b4913284039": "{\"version\":1,\"hooks\":{\"sessionStart\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine copilot --copilot-event sessionStart\"}],\"userPromptSubmitted\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine copilot --copilot-event userPromptSubmitted\"}],\"agentStop\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine copilot --copilot-event agentStop\"}],\"sessionEnd\":[{\"type\":\"command\",\"command\":\"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine copilot --copilot-event sessionEnd\"}]}}",
  "3d5035418d5226f3": "{\n  \"version\": 1,\n  \"hooks\": {\n    \"sessionStart\": [\n      {\n        \"type\": \"command\",\n        \"command\": \"foreign-start\"\n      }\n    ]\n  }\n}\n",
  "ee4db07d82574649": "// session-register — auto-installed by the machine adapter. Binds this Pi session to the local\n// machine daemon (127.0.0.1:19474) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { existsSync, readFileSync } from \"node:fs\";\nimport type { ExtensionAPI } from \"@earendil-works/pi-coding-agent\";\n\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default function (pi: ExtensionAPI) {\n  let announced = false;   // posted at least once (the transcript may not exist yet)\n  let registered = false;  // posted with a real, on-disk transcript — nothing left to do\n\n  const register = async (ctx: any) => {\n    const pane = process.env.TMUX_PANE;\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\");\n    let token = \"\";\n    try { token = readFileSync(\"<root>/data/hook-token\", \"utf8\").trim(); } catch {}\n    if ((!pane && !ptyPane) || !token) return;\n    // Pi knows the session file path immediately but only WRITES it once the first assistant message\n    // lands. Sending a path that isn't on disk yet is rejected by the daemon (it validates the file),\n    // so announce without one first and attach the real path on a later turn.\n    const file = ctx?.sessionManager?.getSessionFile?.() ?? null;\n    const ready = !!file && existsSync(file);\n    if (registered || (announced && !ready)) return;\n    const sessionId = ctx?.sessionManager?.getSessionId?.();\n    if (!sessionId) return;\n    try {\n      const res = await harnessFetch(\"http://127.0.0.1:19474/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"pi\",\n          pluginVersion: \"<version>\",\n          sessionId,\n          transcriptPath: ready ? file : undefined,\n          cwd: ctx?.cwd ?? undefined,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      });\n      if (!res.ok) return; // daemon refused (e.g. transcript not readable yet) — retry on the next turn\n      announced = true;\n      if (ready) registered = true;\n    } catch {}\n  };\n\n  // session_start fires before the transcript exists; the turn hooks catch it once it does.\n  pi.on(\"session_start\", async (_event, ctx) => { await register(ctx); });\n  pi.on(\"turn_start\", async (_event, ctx) => { await register(ctx); });\n  pi.on(\"turn_end\", async (_event, ctx) => { await register(ctx); });\n}\n",
  "fe5dc71d557d28f9": "// session-register — auto-installed by the machine adapter. Binds this Amp thread to the local\n// machine daemon (127.0.0.1:19473) and writes the transcript the daemon tails, because Amp keeps none\n// on disk. No-op outside tmux.\nimport { appendFileSync, existsSync, mkdirSync, readFileSync } from 'node:fs'\nimport { join } from 'node:path'\n\nexport const description = 'Mirrors this Amp thread to the machine adapter (web + device)'\n\nconst SESSIONS_DIR = \"<root>/home/.harness/cli/data/amp-sessions\"\n\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default function (amp: any) {\n  const pane = process.env.TMUX_PANE\n  if (!pane) return\n\n  // NOT `process.cwd()`: Bun runs a plugin with the PLUGIN's directory as its cwd, so that reports\n  // `<project>/.amp/plugins` (measured). `PWD` is inherited from the shell that launched plain Amp.\n  const workdir = process.env.PWD || process.cwd()\n\n  const emitted = new Set()\n  // Turn ids already opened/closed. Amp re-dispatches a message it could not deliver, firing agent.start\n  // a SECOND time for the same message id (measured: two identical turn_start records 61s apart, then a\n  // turn_end 'done' and a turn_end 'error' for the one turn). Written straight through, that is two turns\n  // on web and device and two user bubbles in history.\n  const turnsStarted = new Set()\n  const turnsEnded = new Set()\n  // Tool ids already written, so a tool seen BOTH as an event and as a message block is written once.\n  const toolCalls = new Set()\n  const toolResults = new Set()\n  let registered = false\n  let file = ''\n  let seeded = false\n\n  const line = (record: any) => {\n    try {\n      mkdirSync(SESSIONS_DIR, { recursive: true, mode: 0o700 })\n      appendFileSync(file, JSON.stringify(record) + '\\n')\n    } catch {}\n  }\n\n  const open = (threadId: string) => {\n    if (file) return\n    file = join(SESSIONS_DIR, threadId + '.jsonl')\n    // `cwd` on the first line is what lets the daemon re-find this session by directory after a restart,\n    // the same way it reads claude's and pi's transcripts. It must be a top-level string field.\n    line({ t: 'session', threadId, cwd: workdir, at: Date.now() })\n  }\n\n  const register = async (threadId: string) => {\n    open(threadId)\n    if (registered || !existsSync(file)) return\n    try {\n      const token = readFileSync(\"<root>/data/hook-token\", 'utf8').trim()\n      if (!token) return\n      const res = await harnessFetch('http://127.0.0.1:19473/api/hook/session-start', {\n        method: 'POST',\n        headers: { 'content-type': 'application/json', 'x-harness-hook-token': token },\n        body: JSON.stringify({\n          engine: 'amp',\n          pluginVersion: \"<version>\",\n          sessionId: threadId,\n          transcriptPath: file,\n          cwd: workdir,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: 'tmux', paneId: pane }] : []),\n          ],\n        }),\n      })\n      if (res.ok) registered = true\n    } catch {}\n  }\n\n  const resultId = (block: any) => String(block.toolUseID || block.tool_use_id || '')\n\n  /**\n   * Write everything in the thread that has not been written yet.\n   *\n   * This reads message BLOCKS rather than events, because the events do not cover the thread:\n   *\n   *   - no event carries assistant text at all, and\n   *   - `tool.call`/`tool.result` only fire for tools the CLIENT executes. MEASURED: a `web_search`\n   *     turn produced no tool event and no tool lease in Amp's own log, yet the message plainly held a\n   *     `tool_use` block — Amp runs that tool on its server. Skipping blocks meant a search rendered as\n   *     nothing at all on web and device while the pane showed \"Explored 1 search\".\n   *\n   * `seed` marks what already exists WITHOUT writing it, for a thread that is being resumed: those\n   * messages belong to earlier turns, and replaying them made a fresh turn open with an old answer in it.\n   */\n  const drain = async (ctx: any) => {\n    let messages: any[] = []\n    try { messages = await ctx.thread.messages({ from: 'end', limit: 20 }) } catch { return }\n    // The FIRST drain of this plugin instance only claims what it finds; it writes nothing. That covers\n    // both ways a plugin meets a thread that already has messages: a resumed thread, and a plugin reload\n    // (Amp loads a plugin ONCE per process, so reload is how a running pane picks up a new build). Without\n    // it, the next prompt replayed the whole recent history as if it had just happened.\n    const seed = !seeded\n    seeded = true\n    // The seed pass would swallow the very prompt the turn needs to open on. Measured: `session.start`\n    // does NOT fire when Amp launches — it fires on the first submit, and by then the thread already\n    // holds one `user` message. So the seed has to tell history from the live prompt, and the test is\n    // whether anything answered it: the LAST user text block with no assistant message after it is\n    // waiting, not past. On a resumed thread the last message is an assistant one, so nothing opens.\n    let liveUserId = ''\n    for (const message of messages) {\n      if (message.role === 'assistant') { liveUserId = ''; continue }\n      const parts = Array.isArray(message.content) ? message.content : []\n      const hasText = parts.some((b: any) => b && b.type === 'text' && typeof b.text === 'string' && b.text)\n      if (hasText) liveUserId = String(message.id)\n    }\n    for (const message of messages) {\n      const blocks = Array.isArray(message.content) ? message.content : []\n      for (let i = 0; i < blocks.length; i++) {\n        const block = blocks[i]\n        if (!block) continue\n        if (block.type === 'text' || block.type === 'thinking') {\n          const key = String(message.id) + '#' + i\n          if (emitted.has(key)) continue\n          const text = typeof block.text === 'string' ? block.text : block.thinking\n          if (typeof text !== 'string' || !text) continue\n          emitted.add(key)\n          // A user TEXT block opens the turn.\n          //\n          // Amp used to announce that with an `agent.start` event, and the handler below wrote\n          // `turn_start` from it. That event no longer fires — probed with a plugin that registered for\n          // sixteen candidate names on amp 0.0.1786681855 and saw only `session.start`, `tool.call`,\n          // `tool.result` and `agent.end`. The prompt now reaches a plugin no earlier than\n          // `agent.end`, which is the END of the turn, far too late to open one.\n          //\n          // So it is taken from the thread instead, where drain was already reading it and dropping it:\n          // measured at the first `tool.call` of a turn, `messages()` already returns the prompt, oldest\n          // first. Without this the turn opens with an empty question on web and device, and the recap\n          // loses what was asked.\n          //\n          // Only a TEXT block qualifies: a tool_result is also carried on a `user` message, so matching\n          // the role alone would open a turn on every tool that returned.\n          if (message.role !== 'assistant') {\n            const turnId = String(message.id)\n            if (turnsStarted.has(turnId)) continue\n            turnsStarted.add(turnId)\n            if (!seed || turnId === liveUserId) line({ t: 'turn_start', id: turnId, message: text, at: Date.now() })\n            continue\n          }\n          if (!seed) line({ t: block.type, id: message.id, i, text })\n        } else if (block.type === 'tool_use') {\n          const id = String(block.id || '')\n          if (!id || toolCalls.has(id)) continue\n          toolCalls.add(id)\n          if (!seed) line({ t: 'tool_call', id, tool: block.name, input: block.input })\n        } else if (block.type === 'tool_result') {\n          const id = resultId(block)\n          if (!id || toolResults.has(id)) continue\n          toolResults.add(id)\n          // A server-run tool puts its payload under `run`; a client-run one under `content`/`output`.\n          if (!seed) line({ t: 'tool_result', id, status: 'done', output: block.run ?? block.content ?? block.output })\n        }\n      }\n    }\n  }\n\n  amp.on('session.start', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    await drain(ctx)\n  })\n\n  amp.on('agent.start', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    const id = String(event.id)\n    if (!turnsStarted.has(id)) {\n      turnsStarted.add(id)\n      line({ t: 'turn_start', id: event.id, message: event.message, at: Date.now() })\n    }\n    await drain(ctx)\n  })\n\n  amp.on('tool.call', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    // CLAIM THE ID FIRST. `drain` runs before this card so a message's prose lands ahead of the tool it\n    // called — but by then the tool_use block for THIS tool is already in the thread, so draining without\n    // claiming wrote the card twice (measured: one Task turn produced two identical `skill` cards).\n    toolCalls.add(String(event.toolUseID))\n    await drain(ctx)\n    line({ t: 'tool_call', id: event.toolUseID, tool: event.tool, input: event.input })\n  })\n\n  amp.on('tool.result', async (event: any, ctx: any) => {\n    // Same rule as tool.call: claim before draining.\n    toolResults.add(String(event.toolUseID))\n    line({\n      t: 'tool_result',\n      id: event.toolUseID,\n      tool: event.tool,\n      status: event.status,\n      output: event.output,\n    })\n    await drain(ctx)\n  })\n\n  amp.on('agent.end', async (event: any, ctx: any) => {\n    await drain(ctx)\n    // `message` is the prompt that STARTED this turn, and agent.end carries it even when\n    // agent.start never fired (a prompt queued while Amp was connecting). Recording it here is what\n    // lets history still show what was asked — see the replay branch in the normalizer.\n    const id = String(event.id)\n    if (turnsEnded.has(id)) return\n    turnsEnded.add(id)\n    line({ t: 'turn_end', id: event.id, status: event.status, message: event.message, at: Date.now() })\n  })\n}\n",
  "148abe7c5b7b3a8d": "// session-register — auto-installed by the machine adapter. Binds this OpenCode session to the\n// local machine daemon (127.0.0.1:19473) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"<root>/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport const MachineRegister = async ({ directory, worktree, project, client }) => {\n  const seen = new Set()\n  const post = async (sessionID) => {\n    const pane = process.env.TMUX_PANE\n    // A Harness pty host pane (Windows) names itself HARNESS_PANE=<instance>:%N, and has no TMUX_PANE.\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const token = hookToken()\n    if ((!pane && !ptyPane) || !token || !sessionID || seen.has(sessionID)) return\n    seen.add(sessionID)\n    try {\n      await harnessFetch(\"http://127.0.0.1:19473/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"opencode\",\n          pluginVersion: \"<version>\",\n          sessionId: sessionID,\n          cwd: directory || worktree || (project && project.worktree) || null,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      })\n    } catch {}\n  }\n  return {\n    event: async ({ event }) => {\n      if (!event) return\n      if (event.type === \"session.created\" || event.type === \"session.updated\") {\n        const p = event.properties || {}\n        const info = p.info || {}\n        if (info.parentID) return // sub-agent child session — shown under its parent's Task card, not a top-level agent\n        await post(info.id || p.sessionID || p.sessionId)\n      }\n    },\n  }\n}\n",
  "c9014cb63a914d05": "// session-register (OpenCode 2 TUI) — auto-installed by the machine adapter. Tells the local machine\n// daemon (127.0.0.1:19474) which session this pane shows, as the 1.x plugin does. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"/opt/old/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"/opt/old/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default {\n  id: \"harness-session-register\",\n  setup(ctx) {\n    const pane = process.env.TMUX_PANE\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const router = ctx && ctx.ui && ctx.ui.router\n    if ((!pane && !ptyPane) || !router || typeof router.current !== \"function\") return\n    const posted = new Set()\n    let busy = false\n    const post = async (sessionID) => {\n      const token = hookToken()\n      if (!token || !sessionID || posted.has(sessionID) || busy) return\n      busy = true\n      try {\n        let info\n        try { info = await (ctx.data && ctx.data.session && ctx.data.session.get ? ctx.data.session.get(sessionID) : undefined) } catch {}\n        if (info && info.parentID) { posted.add(sessionID); return } // a sub-agent's — shown under its parent's Task card\n        const cwd = (info && info.location && info.location.directory) || (ctx.location && ctx.location.directory) || process.cwd()\n        const res = await harnessFetch(\"http://127.0.0.1:19474/api/hook/session-start\", {\n          method: \"POST\",\n          headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n          body: JSON.stringify({\n            engine: \"opencode\",\n            pluginVersion: \"<version>\",\n            sessionId: sessionID,\n            cwd,\n            tmuxPane: pane,\n            callerPid: process.pid,\n            runtimeHints: pane ? [{ backend: \"tmux\", paneId: pane }] : [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }],\n          }),\n        })\n        if (res && res.ok) posted.add(sessionID)\n      } catch {} finally { busy = false }\n    }\n    const check = () => {\n      try { const at = router.current(); if (at && at.type === \"session\" && at.sessionID) post(at.sessionID) } catch {}\n    }\n    check()\n    const timer = setInterval(check, 1000)\n    if (timer && typeof timer.unref === \"function\") timer.unref()\n    return () => clearInterval(timer)\n  },\n}\n",
  "e36fbe8da025a902": "// session-register — auto-installed by the machine adapter. Binds this Kilo session to the\n// local machine daemon (127.0.0.1:19473) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"<root>/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport const MachineRegister = async ({ directory, worktree, project, client }) => {\n  const seen = new Set()\n  const post = async (sessionID) => {\n    const pane = process.env.TMUX_PANE\n    // A Harness pty host pane (Windows) names itself HARNESS_PANE=<instance>:%N, and has no TMUX_PANE.\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const token = hookToken()\n    if ((!pane && !ptyPane) || !token || !sessionID || seen.has(sessionID)) return\n    seen.add(sessionID)\n    try {\n      await harnessFetch(\"http://127.0.0.1:19473/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"kilo\",\n          pluginVersion: \"<version>\",\n          sessionId: sessionID,\n          cwd: directory || worktree || (project && project.worktree) || null,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      })\n    } catch {}\n  }\n  return {\n    event: async ({ event }) => {\n      if (!event) return\n      if (event.type === \"session.created\" || event.type === \"session.updated\") {\n        const p = event.properties || {}\n        const info = p.info || {}\n        if (info.parentID) return // sub-agent child session — shown under its parent's Task card, not a top-level agent\n        await post(info.id || p.sessionID || p.sessionId)\n      }\n    },\n  }\n}\n",
  "f2a0ee32c639505c": "// session-register — auto-installed by the machine adapter. Binds this Pi session to the local\n// machine daemon (127.0.0.1:19473) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { existsSync, readFileSync } from \"node:fs\";\nimport type { ExtensionAPI } from \"@earendil-works/pi-coding-agent\";\n\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default function (pi: ExtensionAPI) {\n  let announced = false;   // posted at least once (the transcript may not exist yet)\n  let registered = false;  // posted with a real, on-disk transcript — nothing left to do\n\n  const register = async (ctx: any) => {\n    const pane = process.env.TMUX_PANE;\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\");\n    let token = \"\";\n    try { token = readFileSync(\"<root>/data/hook-token\", \"utf8\").trim(); } catch {}\n    if ((!pane && !ptyPane) || !token) return;\n    // Pi knows the session file path immediately but only WRITES it once the first assistant message\n    // lands. Sending a path that isn't on disk yet is rejected by the daemon (it validates the file),\n    // so announce without one first and attach the real path on a later turn.\n    const file = ctx?.sessionManager?.getSessionFile?.() ?? null;\n    const ready = !!file && existsSync(file);\n    if (registered || (announced && !ready)) return;\n    const sessionId = ctx?.sessionManager?.getSessionId?.();\n    if (!sessionId) return;\n    try {\n      const res = await harnessFetch(\"http://127.0.0.1:19473/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"pi\",\n          pluginVersion: \"<version>\",\n          sessionId,\n          transcriptPath: ready ? file : undefined,\n          cwd: ctx?.cwd ?? undefined,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      });\n      if (!res.ok) return; // daemon refused (e.g. transcript not readable yet) — retry on the next turn\n      announced = true;\n      if (ready) registered = true;\n    } catch {}\n  };\n\n  // session_start fires before the transcript exists; the turn hooks catch it once it does.\n  pi.on(\"session_start\", async (_event, ctx) => { await register(ctx); });\n  pi.on(\"turn_start\", async (_event, ctx) => { await register(ctx); });\n  pi.on(\"turn_end\", async (_event, ctx) => { await register(ctx); });\n}",
  "a89625233da4b636": "// session-register — auto-installed by the machine adapter. Binds this Amp thread to the local\n// machine daemon (127.0.0.1:19474) and writes the transcript the daemon tails, because Amp keeps none\n// on disk. No-op outside tmux.\nimport { appendFileSync, existsSync, mkdirSync, readFileSync } from 'node:fs'\nimport { join } from 'node:path'\n\nexport const description = 'Mirrors this Amp thread to the machine adapter (web + device)'\n\nconst SESSIONS_DIR = \"<root>/home/.harness/cli/data/amp-sessions\"\n\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default function (amp: any) {\n  const pane = process.env.TMUX_PANE\n  if (!pane) return\n\n  // NOT `process.cwd()`: Bun runs a plugin with the PLUGIN's directory as its cwd, so that reports\n  // `<project>/.amp/plugins` (measured). `PWD` is inherited from the shell that launched plain Amp.\n  const workdir = process.env.PWD || process.cwd()\n\n  const emitted = new Set()\n  // Turn ids already opened/closed. Amp re-dispatches a message it could not deliver, firing agent.start\n  // a SECOND time for the same message id (measured: two identical turn_start records 61s apart, then a\n  // turn_end 'done' and a turn_end 'error' for the one turn). Written straight through, that is two turns\n  // on web and device and two user bubbles in history.\n  const turnsStarted = new Set()\n  const turnsEnded = new Set()\n  // Tool ids already written, so a tool seen BOTH as an event and as a message block is written once.\n  const toolCalls = new Set()\n  const toolResults = new Set()\n  let registered = false\n  let file = ''\n  let seeded = false\n\n  const line = (record: any) => {\n    try {\n      mkdirSync(SESSIONS_DIR, { recursive: true, mode: 0o700 })\n      appendFileSync(file, JSON.stringify(record) + '\\n')\n    } catch {}\n  }\n\n  const open = (threadId: string) => {\n    if (file) return\n    file = join(SESSIONS_DIR, threadId + '.jsonl')\n    // `cwd` on the first line is what lets the daemon re-find this session by directory after a restart,\n    // the same way it reads claude's and pi's transcripts. It must be a top-level string field.\n    line({ t: 'session', threadId, cwd: workdir, at: Date.now() })\n  }\n\n  const register = async (threadId: string) => {\n    open(threadId)\n    if (registered || !existsSync(file)) return\n    try {\n      const token = readFileSync(\"<root>/data/hook-token\", 'utf8').trim()\n      if (!token) return\n      const res = await harnessFetch('http://127.0.0.1:19474/api/hook/session-start', {\n        method: 'POST',\n        headers: { 'content-type': 'application/json', 'x-harness-hook-token': token },\n        body: JSON.stringify({\n          engine: 'amp',\n          pluginVersion: \"<version>\",\n          sessionId: threadId,\n          transcriptPath: file,\n          cwd: workdir,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: 'tmux', paneId: pane }] : []),\n          ],\n        }),\n      })\n      if (res.ok) registered = true\n    } catch {}\n  }\n\n  const resultId = (block: any) => String(block.toolUseID || block.tool_use_id || '')\n\n  /**\n   * Write everything in the thread that has not been written yet.\n   *\n   * This reads message BLOCKS rather than events, because the events do not cover the thread:\n   *\n   *   - no event carries assistant text at all, and\n   *   - `tool.call`/`tool.result` only fire for tools the CLIENT executes. MEASURED: a `web_search`\n   *     turn produced no tool event and no tool lease in Amp's own log, yet the message plainly held a\n   *     `tool_use` block — Amp runs that tool on its server. Skipping blocks meant a search rendered as\n   *     nothing at all on web and device while the pane showed \"Explored 1 search\".\n   *\n   * `seed` marks what already exists WITHOUT writing it, for a thread that is being resumed: those\n   * messages belong to earlier turns, and replaying them made a fresh turn open with an old answer in it.\n   */\n  const drain = async (ctx: any) => {\n    let messages: any[] = []\n    try { messages = await ctx.thread.messages({ from: 'end', limit: 20 }) } catch { return }\n    // The FIRST drain of this plugin instance only claims what it finds; it writes nothing. That covers\n    // both ways a plugin meets a thread that already has messages: a resumed thread, and a plugin reload\n    // (Amp loads a plugin ONCE per process, so reload is how a running pane picks up a new build). Without\n    // it, the next prompt replayed the whole recent history as if it had just happened.\n    const seed = !seeded\n    seeded = true\n    // The seed pass would swallow the very prompt the turn needs to open on. Measured: `session.start`\n    // does NOT fire when Amp launches — it fires on the first submit, and by then the thread already\n    // holds one `user` message. So the seed has to tell history from the live prompt, and the test is\n    // whether anything answered it: the LAST user text block with no assistant message after it is\n    // waiting, not past. On a resumed thread the last message is an assistant one, so nothing opens.\n    let liveUserId = ''\n    for (const message of messages) {\n      if (message.role === 'assistant') { liveUserId = ''; continue }\n      const parts = Array.isArray(message.content) ? message.content : []\n      const hasText = parts.some((b: any) => b && b.type === 'text' && typeof b.text === 'string' && b.text)\n      if (hasText) liveUserId = String(message.id)\n    }\n    for (const message of messages) {\n      const blocks = Array.isArray(message.content) ? message.content : []\n      for (let i = 0; i < blocks.length; i++) {\n        const block = blocks[i]\n        if (!block) continue\n        if (block.type === 'text' || block.type === 'thinking') {\n          const key = String(message.id) + '#' + i\n          if (emitted.has(key)) continue\n          const text = typeof block.text === 'string' ? block.text : block.thinking\n          if (typeof text !== 'string' || !text) continue\n          emitted.add(key)\n          // A user TEXT block opens the turn.\n          //\n          // Amp used to announce that with an `agent.start` event, and the handler below wrote\n          // `turn_start` from it. That event no longer fires — probed with a plugin that registered for\n          // sixteen candidate names on amp 0.0.1786681855 and saw only `session.start`, `tool.call`,\n          // `tool.result` and `agent.end`. The prompt now reaches a plugin no earlier than\n          // `agent.end`, which is the END of the turn, far too late to open one.\n          //\n          // So it is taken from the thread instead, where drain was already reading it and dropping it:\n          // measured at the first `tool.call` of a turn, `messages()` already returns the prompt, oldest\n          // first. Without this the turn opens with an empty question on web and device, and the recap\n          // loses what was asked.\n          //\n          // Only a TEXT block qualifies: a tool_result is also carried on a `user` message, so matching\n          // the role alone would open a turn on every tool that returned.\n          if (message.role !== 'assistant') {\n            const turnId = String(message.id)\n            if (turnsStarted.has(turnId)) continue\n            turnsStarted.add(turnId)\n            if (!seed || turnId === liveUserId) line({ t: 'turn_start', id: turnId, message: text, at: Date.now() })\n            continue\n          }\n          if (!seed) line({ t: block.type, id: message.id, i, text })\n        } else if (block.type === 'tool_use') {\n          const id = String(block.id || '')\n          if (!id || toolCalls.has(id)) continue\n          toolCalls.add(id)\n          if (!seed) line({ t: 'tool_call', id, tool: block.name, input: block.input })\n        } else if (block.type === 'tool_result') {\n          const id = resultId(block)\n          if (!id || toolResults.has(id)) continue\n          toolResults.add(id)\n          // A server-run tool puts its payload under `run`; a client-run one under `content`/`output`.\n          if (!seed) line({ t: 'tool_result', id, status: 'done', output: block.run ?? block.content ?? block.output })\n        }\n      }\n    }\n  }\n\n  amp.on('session.start', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    await drain(ctx)\n  })\n\n  amp.on('agent.start', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    const id = String(event.id)\n    if (!turnsStarted.has(id)) {\n      turnsStarted.add(id)\n      line({ t: 'turn_start', id: event.id, message: event.message, at: Date.now() })\n    }\n    await drain(ctx)\n  })\n\n  amp.on('tool.call', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    // CLAIM THE ID FIRST. `drain` runs before this card so a message's prose lands ahead of the tool it\n    // called — but by then the tool_use block for THIS tool is already in the thread, so draining without\n    // claiming wrote the card twice (measured: one Task turn produced two identical `skill` cards).\n    toolCalls.add(String(event.toolUseID))\n    await drain(ctx)\n    line({ t: 'tool_call', id: event.toolUseID, tool: event.tool, input: event.input })\n  })\n\n  amp.on('tool.result', async (event: any, ctx: any) => {\n    // Same rule as tool.call: claim before draining.\n    toolResults.add(String(event.toolUseID))\n    line({\n      t: 'tool_result',\n      id: event.toolUseID,\n      tool: event.tool,\n      status: event.status,\n      output: event.output,\n    })\n    await drain(ctx)\n  })\n\n  amp.on('agent.end', async (event: any, ctx: any) => {\n    await drain(ctx)\n    // `message` is the prompt that STARTED this turn, and agent.end carries it even when\n    // agent.start never fired (a prompt queued while Amp was connecting). Recording it here is what\n    // lets history still show what was asked — see the replay branch in the normalizer.\n    const id = String(event.id)\n    if (turnsEnded.has(id)) return\n    turnsEnded.add(id)\n    line({ t: 'turn_end', id: event.id, status: event.status, message: event.message, at: Date.now() })\n  })\n}\n",
  "f9bdf2bb7e210715": "// session-register — auto-installed by the machine adapter. Binds this Pi session to the local\n// machine daemon (127.0.0.1:19474) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { existsSync, readFileSync } from \"node:fs\";\nimport type { ExtensionAPI } from \"@earendil-works/pi-coding-agent\";\n\nconst harnessSocket = \"/opt/old/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default function (pi: ExtensionAPI) {\n  let announced = false;   // posted at least once (the transcript may not exist yet)\n  let registered = false;  // posted with a real, on-disk transcript — nothing left to do\n\n  const register = async (ctx: any) => {\n    const pane = process.env.TMUX_PANE;\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\");\n    let token = \"\";\n    try { token = readFileSync(\"/opt/old/data/hook-token\", \"utf8\").trim(); } catch {}\n    if ((!pane && !ptyPane) || !token) return;\n    // Pi knows the session file path immediately but only WRITES it once the first assistant message\n    // lands. Sending a path that isn't on disk yet is rejected by the daemon (it validates the file),\n    // so announce without one first and attach the real path on a later turn.\n    const file = ctx?.sessionManager?.getSessionFile?.() ?? null;\n    const ready = !!file && existsSync(file);\n    if (registered || (announced && !ready)) return;\n    const sessionId = ctx?.sessionManager?.getSessionId?.();\n    if (!sessionId) return;\n    try {\n      const res = await harnessFetch(\"http://127.0.0.1:19474/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"pi\",\n          pluginVersion: \"<version>\",\n          sessionId,\n          transcriptPath: ready ? file : undefined,\n          cwd: ctx?.cwd ?? undefined,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      });\n      if (!res.ok) return; // daemon refused (e.g. transcript not readable yet) — retry on the next turn\n      announced = true;\n      if (ready) registered = true;\n    } catch {}\n  };\n\n  // session_start fires before the transcript exists; the turn hooks catch it once it does.\n  pi.on(\"session_start\", async (_event, ctx) => { await register(ctx); });\n  pi.on(\"turn_start\", async (_event, ctx) => { await register(ctx); });\n  pi.on(\"turn_end\", async (_event, ctx) => { await register(ctx); });\n}\n",
  "4882239f7d22747c": "// session-register — auto-installed by the machine adapter. Binds this Amp thread to the local\n// machine daemon (127.0.0.1:19473) and writes the transcript the daemon tails, because Amp keeps none\n// on disk. No-op outside tmux.\nimport { appendFileSync, existsSync, mkdirSync, readFileSync } from 'node:fs'\nimport { join } from 'node:path'\n\nexport const description = 'Mirrors this Amp thread to the machine adapter (web + device)'\n\nconst SESSIONS_DIR = \"<root>/home/.harness/cli/data/amp-sessions\"\n\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default function (amp: any) {\n  const pane = process.env.TMUX_PANE\n  if (!pane) return\n\n  // NOT `process.cwd()`: Bun runs a plugin with the PLUGIN's directory as its cwd, so that reports\n  // `<project>/.amp/plugins` (measured). `PWD` is inherited from the shell that launched plain Amp.\n  const workdir = process.env.PWD || process.cwd()\n\n  const emitted = new Set()\n  // Turn ids already opened/closed. Amp re-dispatches a message it could not deliver, firing agent.start\n  // a SECOND time for the same message id (measured: two identical turn_start records 61s apart, then a\n  // turn_end 'done' and a turn_end 'error' for the one turn). Written straight through, that is two turns\n  // on web and device and two user bubbles in history.\n  const turnsStarted = new Set()\n  const turnsEnded = new Set()\n  // Tool ids already written, so a tool seen BOTH as an event and as a message block is written once.\n  const toolCalls = new Set()\n  const toolResults = new Set()\n  let registered = false\n  let file = ''\n  let seeded = false\n\n  const line = (record: any) => {\n    try {\n      mkdirSync(SESSIONS_DIR, { recursive: true, mode: 0o700 })\n      appendFileSync(file, JSON.stringify(record) + '\\n')\n    } catch {}\n  }\n\n  const open = (threadId: string) => {\n    if (file) return\n    file = join(SESSIONS_DIR, threadId + '.jsonl')\n    // `cwd` on the first line is what lets the daemon re-find this session by directory after a restart,\n    // the same way it reads claude's and pi's transcripts. It must be a top-level string field.\n    line({ t: 'session', threadId, cwd: workdir, at: Date.now() })\n  }\n\n  const register = async (threadId: string) => {\n    open(threadId)\n    if (registered || !existsSync(file)) return\n    try {\n      const token = readFileSync(\"<root>/data/hook-token\", 'utf8').trim()\n      if (!token) return\n      const res = await harnessFetch('http://127.0.0.1:19473/api/hook/session-start', {\n        method: 'POST',\n        headers: { 'content-type': 'application/json', 'x-harness-hook-token': token },\n        body: JSON.stringify({\n          engine: 'amp',\n          pluginVersion: \"<version>\",\n          sessionId: threadId,\n          transcriptPath: file,\n          cwd: workdir,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: 'tmux', paneId: pane }] : []),\n          ],\n        }),\n      })\n      if (res.ok) registered = true\n    } catch {}\n  }\n\n  const resultId = (block: any) => String(block.toolUseID || block.tool_use_id || '')\n\n  /**\n   * Write everything in the thread that has not been written yet.\n   *\n   * This reads message BLOCKS rather than events, because the events do not cover the thread:\n   *\n   *   - no event carries assistant text at all, and\n   *   - `tool.call`/`tool.result` only fire for tools the CLIENT executes. MEASURED: a `web_search`\n   *     turn produced no tool event and no tool lease in Amp's own log, yet the message plainly held a\n   *     `tool_use` block — Amp runs that tool on its server. Skipping blocks meant a search rendered as\n   *     nothing at all on web and device while the pane showed \"Explored 1 search\".\n   *\n   * `seed` marks what already exists WITHOUT writing it, for a thread that is being resumed: those\n   * messages belong to earlier turns, and replaying them made a fresh turn open with an old answer in it.\n   */\n  const drain = async (ctx: any) => {\n    let messages: any[] = []\n    try { messages = await ctx.thread.messages({ from: 'end', limit: 20 }) } catch { return }\n    // The FIRST drain of this plugin instance only claims what it finds; it writes nothing. That covers\n    // both ways a plugin meets a thread that already has messages: a resumed thread, and a plugin reload\n    // (Amp loads a plugin ONCE per process, so reload is how a running pane picks up a new build). Without\n    // it, the next prompt replayed the whole recent history as if it had just happened.\n    const seed = !seeded\n    seeded = true\n    // The seed pass would swallow the very prompt the turn needs to open on. Measured: `session.start`\n    // does NOT fire when Amp launches — it fires on the first submit, and by then the thread already\n    // holds one `user` message. So the seed has to tell history from the live prompt, and the test is\n    // whether anything answered it: the LAST user text block with no assistant message after it is\n    // waiting, not past. On a resumed thread the last message is an assistant one, so nothing opens.\n    let liveUserId = ''\n    for (const message of messages) {\n      if (message.role === 'assistant') { liveUserId = ''; continue }\n      const parts = Array.isArray(message.content) ? message.content : []\n      const hasText = parts.some((b: any) => b && b.type === 'text' && typeof b.text === 'string' && b.text)\n      if (hasText) liveUserId = String(message.id)\n    }\n    for (const message of messages) {\n      const blocks = Array.isArray(message.content) ? message.content : []\n      for (let i = 0; i < blocks.length; i++) {\n        const block = blocks[i]\n        if (!block) continue\n        if (block.type === 'text' || block.type === 'thinking') {\n          const key = String(message.id) + '#' + i\n          if (emitted.has(key)) continue\n          const text = typeof block.text === 'string' ? block.text : block.thinking\n          if (typeof text !== 'string' || !text) continue\n          emitted.add(key)\n          // A user TEXT block opens the turn.\n          //\n          // Amp used to announce that with an `agent.start` event, and the handler below wrote\n          // `turn_start` from it. That event no longer fires — probed with a plugin that registered for\n          // sixteen candidate names on amp 0.0.1786681855 and saw only `session.start`, `tool.call`,\n          // `tool.result` and `agent.end`. The prompt now reaches a plugin no earlier than\n          // `agent.end`, which is the END of the turn, far too late to open one.\n          //\n          // So it is taken from the thread instead, where drain was already reading it and dropping it:\n          // measured at the first `tool.call` of a turn, `messages()` already returns the prompt, oldest\n          // first. Without this the turn opens with an empty question on web and device, and the recap\n          // loses what was asked.\n          //\n          // Only a TEXT block qualifies: a tool_result is also carried on a `user` message, so matching\n          // the role alone would open a turn on every tool that returned.\n          if (message.role !== 'assistant') {\n            const turnId = String(message.id)\n            if (turnsStarted.has(turnId)) continue\n            turnsStarted.add(turnId)\n            if (!seed || turnId === liveUserId) line({ t: 'turn_start', id: turnId, message: text, at: Date.now() })\n            continue\n          }\n          if (!seed) line({ t: block.type, id: message.id, i, text })\n        } else if (block.type === 'tool_use') {\n          const id = String(block.id || '')\n          if (!id || toolCalls.has(id)) continue\n          toolCalls.add(id)\n          if (!seed) line({ t: 'tool_call', id, tool: block.name, input: block.input })\n        } else if (block.type === 'tool_result') {\n          const id = resultId(block)\n          if (!id || toolResults.has(id)) continue\n          toolResults.add(id)\n          // A server-run tool puts its payload under `run`; a client-run one under `content`/`output`.\n          if (!seed) line({ t: 'tool_result', id, status: 'done', output: block.run ?? block.content ?? block.output })\n        }\n      }\n    }\n  }\n\n  amp.on('session.start', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    await drain(ctx)\n  })\n\n  amp.on('agent.start', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    const id = String(event.id)\n    if (!turnsStarted.has(id)) {\n      turnsStarted.add(id)\n      line({ t: 'turn_start', id: event.id, message: event.message, at: Date.now() })\n    }\n    await drain(ctx)\n  })\n\n  amp.on('tool.call', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    // CLAIM THE ID FIRST. `drain` runs before this card so a message's prose lands ahead of the tool it\n    // called — but by then the tool_use block for THIS tool is already in the thread, so draining without\n    // claiming wrote the card twice (measured: one Task turn produced two identical `skill` cards).\n    toolCalls.add(String(event.toolUseID))\n    await drain(ctx)\n    line({ t: 'tool_call', id: event.toolUseID, tool: event.tool, input: event.input })\n  })\n\n  amp.on('tool.result', async (event: any, ctx: any) => {\n    // Same rule as tool.call: claim before draining.\n    toolResults.add(String(event.toolUseID))\n    line({\n      t: 'tool_result',\n      id: event.toolUseID,\n      tool: event.tool,\n      status: event.status,\n      output: event.output,\n    })\n    await drain(ctx)\n  })\n\n  amp.on('agent.end', async (event: any, ctx: any) => {\n    await drain(ctx)\n    // `message` is the prompt that STARTED this turn, and agent.end carries it even when\n    // agent.start never fired (a prompt queued while Amp was connecting). Recording it here is what\n    // lets history still show what was asked — see the replay branch in the normalizer.\n    const id = String(event.id)\n    if (turnsEnded.has(id)) return\n    turnsEnded.add(id)\n    line({ t: 'turn_end', id: event.id, status: event.status, message: event.message, at: Date.now() })\n  })\n}",
  "4a70bbe32af8193d": "// session-register — auto-installed by the machine adapter. Binds this Amp thread to the local\n// machine daemon (127.0.0.1:19474) and writes the transcript the daemon tails, because Amp keeps none\n// on disk. No-op outside tmux.\nimport { appendFileSync, existsSync, mkdirSync, readFileSync } from 'node:fs'\nimport { join } from 'node:path'\n\nexport const description = 'Mirrors this Amp thread to the machine adapter (web + device)'\n\nconst SESSIONS_DIR = \"<root>/home/.harness/cli/data/amp-sessions\"\n\nconst harnessSocket = \"/opt/old/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default function (amp: any) {\n  const pane = process.env.TMUX_PANE\n  if (!pane) return\n\n  // NOT `process.cwd()`: Bun runs a plugin with the PLUGIN's directory as its cwd, so that reports\n  // `<project>/.amp/plugins` (measured). `PWD` is inherited from the shell that launched plain Amp.\n  const workdir = process.env.PWD || process.cwd()\n\n  const emitted = new Set()\n  // Turn ids already opened/closed. Amp re-dispatches a message it could not deliver, firing agent.start\n  // a SECOND time for the same message id (measured: two identical turn_start records 61s apart, then a\n  // turn_end 'done' and a turn_end 'error' for the one turn). Written straight through, that is two turns\n  // on web and device and two user bubbles in history.\n  const turnsStarted = new Set()\n  const turnsEnded = new Set()\n  // Tool ids already written, so a tool seen BOTH as an event and as a message block is written once.\n  const toolCalls = new Set()\n  const toolResults = new Set()\n  let registered = false\n  let file = ''\n  let seeded = false\n\n  const line = (record: any) => {\n    try {\n      mkdirSync(SESSIONS_DIR, { recursive: true, mode: 0o700 })\n      appendFileSync(file, JSON.stringify(record) + '\\n')\n    } catch {}\n  }\n\n  const open = (threadId: string) => {\n    if (file) return\n    file = join(SESSIONS_DIR, threadId + '.jsonl')\n    // `cwd` on the first line is what lets the daemon re-find this session by directory after a restart,\n    // the same way it reads claude's and pi's transcripts. It must be a top-level string field.\n    line({ t: 'session', threadId, cwd: workdir, at: Date.now() })\n  }\n\n  const register = async (threadId: string) => {\n    open(threadId)\n    if (registered || !existsSync(file)) return\n    try {\n      const token = readFileSync(\"/opt/old/data/hook-token\", 'utf8').trim()\n      if (!token) return\n      const res = await harnessFetch('http://127.0.0.1:19474/api/hook/session-start', {\n        method: 'POST',\n        headers: { 'content-type': 'application/json', 'x-harness-hook-token': token },\n        body: JSON.stringify({\n          engine: 'amp',\n          pluginVersion: \"<version>\",\n          sessionId: threadId,\n          transcriptPath: file,\n          cwd: workdir,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: 'tmux', paneId: pane }] : []),\n          ],\n        }),\n      })\n      if (res.ok) registered = true\n    } catch {}\n  }\n\n  const resultId = (block: any) => String(block.toolUseID || block.tool_use_id || '')\n\n  /**\n   * Write everything in the thread that has not been written yet.\n   *\n   * This reads message BLOCKS rather than events, because the events do not cover the thread:\n   *\n   *   - no event carries assistant text at all, and\n   *   - `tool.call`/`tool.result` only fire for tools the CLIENT executes. MEASURED: a `web_search`\n   *     turn produced no tool event and no tool lease in Amp's own log, yet the message plainly held a\n   *     `tool_use` block — Amp runs that tool on its server. Skipping blocks meant a search rendered as\n   *     nothing at all on web and device while the pane showed \"Explored 1 search\".\n   *\n   * `seed` marks what already exists WITHOUT writing it, for a thread that is being resumed: those\n   * messages belong to earlier turns, and replaying them made a fresh turn open with an old answer in it.\n   */\n  const drain = async (ctx: any) => {\n    let messages: any[] = []\n    try { messages = await ctx.thread.messages({ from: 'end', limit: 20 }) } catch { return }\n    // The FIRST drain of this plugin instance only claims what it finds; it writes nothing. That covers\n    // both ways a plugin meets a thread that already has messages: a resumed thread, and a plugin reload\n    // (Amp loads a plugin ONCE per process, so reload is how a running pane picks up a new build). Without\n    // it, the next prompt replayed the whole recent history as if it had just happened.\n    const seed = !seeded\n    seeded = true\n    // The seed pass would swallow the very prompt the turn needs to open on. Measured: `session.start`\n    // does NOT fire when Amp launches — it fires on the first submit, and by then the thread already\n    // holds one `user` message. So the seed has to tell history from the live prompt, and the test is\n    // whether anything answered it: the LAST user text block with no assistant message after it is\n    // waiting, not past. On a resumed thread the last message is an assistant one, so nothing opens.\n    let liveUserId = ''\n    for (const message of messages) {\n      if (message.role === 'assistant') { liveUserId = ''; continue }\n      const parts = Array.isArray(message.content) ? message.content : []\n      const hasText = parts.some((b: any) => b && b.type === 'text' && typeof b.text === 'string' && b.text)\n      if (hasText) liveUserId = String(message.id)\n    }\n    for (const message of messages) {\n      const blocks = Array.isArray(message.content) ? message.content : []\n      for (let i = 0; i < blocks.length; i++) {\n        const block = blocks[i]\n        if (!block) continue\n        if (block.type === 'text' || block.type === 'thinking') {\n          const key = String(message.id) + '#' + i\n          if (emitted.has(key)) continue\n          const text = typeof block.text === 'string' ? block.text : block.thinking\n          if (typeof text !== 'string' || !text) continue\n          emitted.add(key)\n          // A user TEXT block opens the turn.\n          //\n          // Amp used to announce that with an `agent.start` event, and the handler below wrote\n          // `turn_start` from it. That event no longer fires — probed with a plugin that registered for\n          // sixteen candidate names on amp 0.0.1786681855 and saw only `session.start`, `tool.call`,\n          // `tool.result` and `agent.end`. The prompt now reaches a plugin no earlier than\n          // `agent.end`, which is the END of the turn, far too late to open one.\n          //\n          // So it is taken from the thread instead, where drain was already reading it and dropping it:\n          // measured at the first `tool.call` of a turn, `messages()` already returns the prompt, oldest\n          // first. Without this the turn opens with an empty question on web and device, and the recap\n          // loses what was asked.\n          //\n          // Only a TEXT block qualifies: a tool_result is also carried on a `user` message, so matching\n          // the role alone would open a turn on every tool that returned.\n          if (message.role !== 'assistant') {\n            const turnId = String(message.id)\n            if (turnsStarted.has(turnId)) continue\n            turnsStarted.add(turnId)\n            if (!seed || turnId === liveUserId) line({ t: 'turn_start', id: turnId, message: text, at: Date.now() })\n            continue\n          }\n          if (!seed) line({ t: block.type, id: message.id, i, text })\n        } else if (block.type === 'tool_use') {\n          const id = String(block.id || '')\n          if (!id || toolCalls.has(id)) continue\n          toolCalls.add(id)\n          if (!seed) line({ t: 'tool_call', id, tool: block.name, input: block.input })\n        } else if (block.type === 'tool_result') {\n          const id = resultId(block)\n          if (!id || toolResults.has(id)) continue\n          toolResults.add(id)\n          // A server-run tool puts its payload under `run`; a client-run one under `content`/`output`.\n          if (!seed) line({ t: 'tool_result', id, status: 'done', output: block.run ?? block.content ?? block.output })\n        }\n      }\n    }\n  }\n\n  amp.on('session.start', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    await drain(ctx)\n  })\n\n  amp.on('agent.start', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    const id = String(event.id)\n    if (!turnsStarted.has(id)) {\n      turnsStarted.add(id)\n      line({ t: 'turn_start', id: event.id, message: event.message, at: Date.now() })\n    }\n    await drain(ctx)\n  })\n\n  amp.on('tool.call', async (event: any, ctx: any) => {\n    await register(event.thread.id)\n    // CLAIM THE ID FIRST. `drain` runs before this card so a message's prose lands ahead of the tool it\n    // called — but by then the tool_use block for THIS tool is already in the thread, so draining without\n    // claiming wrote the card twice (measured: one Task turn produced two identical `skill` cards).\n    toolCalls.add(String(event.toolUseID))\n    await drain(ctx)\n    line({ t: 'tool_call', id: event.toolUseID, tool: event.tool, input: event.input })\n  })\n\n  amp.on('tool.result', async (event: any, ctx: any) => {\n    // Same rule as tool.call: claim before draining.\n    toolResults.add(String(event.toolUseID))\n    line({\n      t: 'tool_result',\n      id: event.toolUseID,\n      tool: event.tool,\n      status: event.status,\n      output: event.output,\n    })\n    await drain(ctx)\n  })\n\n  amp.on('agent.end', async (event: any, ctx: any) => {\n    await drain(ctx)\n    // `message` is the prompt that STARTED this turn, and agent.end carries it even when\n    // agent.start never fired (a prompt queued while Amp was connecting). Recording it here is what\n    // lets history still show what was asked — see the replay branch in the normalizer.\n    const id = String(event.id)\n    if (turnsEnded.has(id)) return\n    turnsEnded.add(id)\n    line({ t: 'turn_end', id: event.id, status: event.status, message: event.message, at: Date.now() })\n  })\n}\n",
  "b2d6dd4165be50af": "// session-register — auto-installed by the machine adapter. Binds this Kilo session to the\n// local machine daemon (127.0.0.1:19474) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"/opt/old/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"/opt/old/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport const MachineRegister = async ({ directory, worktree, project, client }) => {\n  const seen = new Set()\n  const post = async (sessionID) => {\n    const pane = process.env.TMUX_PANE\n    // A Harness pty host pane (Windows) names itself HARNESS_PANE=<instance>:%N, and has no TMUX_PANE.\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const token = hookToken()\n    if ((!pane && !ptyPane) || !token || !sessionID || seen.has(sessionID)) return\n    seen.add(sessionID)\n    try {\n      await harnessFetch(\"http://127.0.0.1:19474/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"kilo\",\n          pluginVersion: \"<version>\",\n          sessionId: sessionID,\n          cwd: directory || worktree || (project && project.worktree) || null,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      })\n    } catch {}\n  }\n  return {\n    event: async ({ event }) => {\n      if (!event) return\n      if (event.type === \"session.created\" || event.type === \"session.updated\") {\n        const p = event.properties || {}\n        const info = p.info || {}\n        if (info.parentID) return // sub-agent child session — shown under its parent's Task card, not a top-level agent\n        await post(info.id || p.sessionID || p.sessionId)\n      }\n    },\n  }\n}\n",
  "f9d10aad86a45fce": "// session-register (OpenCode 2 TUI) — auto-installed by the machine adapter. Tells the local machine\n// daemon (127.0.0.1:19473) which session this pane shows, as the 1.x plugin does. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"<root>/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default {\n  id: \"harness-session-register\",\n  setup(ctx) {\n    const pane = process.env.TMUX_PANE\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const router = ctx && ctx.ui && ctx.ui.router\n    if ((!pane && !ptyPane) || !router || typeof router.current !== \"function\") return\n    const posted = new Set()\n    let busy = false\n    const post = async (sessionID) => {\n      const token = hookToken()\n      if (!token || !sessionID || posted.has(sessionID) || busy) return\n      busy = true\n      try {\n        let info\n        try { info = await (ctx.data && ctx.data.session && ctx.data.session.get ? ctx.data.session.get(sessionID) : undefined) } catch {}\n        if (info && info.parentID) { posted.add(sessionID); return } // a sub-agent's — shown under its parent's Task card\n        const cwd = (info && info.location && info.location.directory) || (ctx.location && ctx.location.directory) || process.cwd()\n        const res = await harnessFetch(\"http://127.0.0.1:19473/api/hook/session-start\", {\n          method: \"POST\",\n          headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n          body: JSON.stringify({\n            engine: \"opencode\",\n            pluginVersion: \"<version>\",\n            sessionId: sessionID,\n            cwd,\n            tmuxPane: pane,\n            callerPid: process.pid,\n            runtimeHints: pane ? [{ backend: \"tmux\", paneId: pane }] : [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }],\n          }),\n        })\n        if (res && res.ok) posted.add(sessionID)\n      } catch {} finally { busy = false }\n    }\n    const check = () => {\n      try { const at = router.current(); if (at && at.type === \"session\" && at.sessionID) post(at.sessionID) } catch {}\n    }\n    check()\n    const timer = setInterval(check, 1000)\n    if (timer && typeof timer.unref === \"function\") timer.unref()\n    return () => clearInterval(timer)\n  },\n}\n",
  "180a82db1b501779": "// session-register — auto-installed by the machine adapter. Binds this Kilo session to the\n// local machine daemon (127.0.0.1:19473) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"<root>/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport const MachineRegister = async ({ directory, worktree, project, client }) => {\n  const seen = new Set()\n  const post = async (sessionID) => {\n    const pane = process.env.TMUX_PANE\n    // A Harness pty host pane (Windows) names itself HARNESS_PANE=<instance>:%N, and has no TMUX_PANE.\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const token = hookToken()\n    if ((!pane && !ptyPane) || !token || !sessionID || seen.has(sessionID)) return\n    seen.add(sessionID)\n    try {\n      await harnessFetch(\"http://127.0.0.1:19473/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"kilo\",\n          pluginVersion: \"<version>\",\n          sessionId: sessionID,\n          cwd: directory || worktree || (project && project.worktree) || null,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      })\n    } catch {}\n  }\n  return {\n    event: async ({ event }) => {\n      if (!event) return\n      if (event.type === \"session.created\" || event.type === \"session.updated\") {\n        const p = event.properties || {}\n        const info = p.info || {}\n        if (info.parentID) return // sub-agent child session — shown under its parent's Task card, not a top-level agent\n        await post(info.id || p.sessionID || p.sessionId)\n      }\n    },\n  }\n}",
  "a1d771dcda304b56": "// session-register — auto-installed by the machine adapter. Binds this Pi session to the local\n// machine daemon (127.0.0.1:19473) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { existsSync, readFileSync } from \"node:fs\";\nimport type { ExtensionAPI } from \"@earendil-works/pi-coding-agent\";\n\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default function (pi: ExtensionAPI) {\n  let announced = false;   // posted at least once (the transcript may not exist yet)\n  let registered = false;  // posted with a real, on-disk transcript — nothing left to do\n\n  const register = async (ctx: any) => {\n    const pane = process.env.TMUX_PANE;\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\");\n    let token = \"\";\n    try { token = readFileSync(\"<root>/data/hook-token\", \"utf8\").trim(); } catch {}\n    if ((!pane && !ptyPane) || !token) return;\n    // Pi knows the session file path immediately but only WRITES it once the first assistant message\n    // lands. Sending a path that isn't on disk yet is rejected by the daemon (it validates the file),\n    // so announce without one first and attach the real path on a later turn.\n    const file = ctx?.sessionManager?.getSessionFile?.() ?? null;\n    const ready = !!file && existsSync(file);\n    if (registered || (announced && !ready)) return;\n    const sessionId = ctx?.sessionManager?.getSessionId?.();\n    if (!sessionId) return;\n    try {\n      const res = await harnessFetch(\"http://127.0.0.1:19473/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"pi\",\n          pluginVersion: \"<version>\",\n          sessionId,\n          transcriptPath: ready ? file : undefined,\n          cwd: ctx?.cwd ?? undefined,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      });\n      if (!res.ok) return; // daemon refused (e.g. transcript not readable yet) — retry on the next turn\n      announced = true;\n      if (ready) registered = true;\n    } catch {}\n  };\n\n  // session_start fires before the transcript exists; the turn hooks catch it once it does.\n  pi.on(\"session_start\", async (_event, ctx) => { await register(ctx); });\n  pi.on(\"turn_start\", async (_event, ctx) => { await register(ctx); });\n  pi.on(\"turn_end\", async (_event, ctx) => { await register(ctx); });\n}\n",
  "ae28f4646a6e33eb": "// session-register (OpenCode 2 TUI) — auto-installed by the machine adapter. Tells the local machine\n// daemon (127.0.0.1:19473) which session this pane shows, as the 1.x plugin does. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"<root>/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default {\n  id: \"harness-session-register\",\n  setup(ctx) {\n    const pane = process.env.TMUX_PANE\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const router = ctx && ctx.ui && ctx.ui.router\n    if ((!pane && !ptyPane) || !router || typeof router.current !== \"function\") return\n    const posted = new Set()\n    let busy = false\n    const post = async (sessionID) => {\n      const token = hookToken()\n      if (!token || !sessionID || posted.has(sessionID) || busy) return\n      busy = true\n      try {\n        let info\n        try { info = await (ctx.data && ctx.data.session && ctx.data.session.get ? ctx.data.session.get(sessionID) : undefined) } catch {}\n        if (info && info.parentID) { posted.add(sessionID); return } // a sub-agent's — shown under its parent's Task card\n        const cwd = (info && info.location && info.location.directory) || (ctx.location && ctx.location.directory) || process.cwd()\n        const res = await harnessFetch(\"http://127.0.0.1:19473/api/hook/session-start\", {\n          method: \"POST\",\n          headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n          body: JSON.stringify({\n            engine: \"opencode\",\n            pluginVersion: \"<version>\",\n            sessionId: sessionID,\n            cwd,\n            tmuxPane: pane,\n            callerPid: process.pid,\n            runtimeHints: pane ? [{ backend: \"tmux\", paneId: pane }] : [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }],\n          }),\n        })\n        if (res && res.ok) posted.add(sessionID)\n      } catch {} finally { busy = false }\n    }\n    const check = () => {\n      try { const at = router.current(); if (at && at.type === \"session\" && at.sessionID) post(at.sessionID) } catch {}\n    }\n    check()\n    const timer = setInterval(check, 1000)\n    if (timer && typeof timer.unref === \"function\") timer.unref()\n    return () => clearInterval(timer)\n  },\n}",
  "d7b9e284664f72ec": "// session-register (OpenCode 2 TUI) — auto-installed by the machine adapter. Tells the local machine\n// daemon (127.0.0.1:19474) which session this pane shows, as the 1.x plugin does. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"<root>/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport default {\n  id: \"harness-session-register\",\n  setup(ctx) {\n    const pane = process.env.TMUX_PANE\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const router = ctx && ctx.ui && ctx.ui.router\n    if ((!pane && !ptyPane) || !router || typeof router.current !== \"function\") return\n    const posted = new Set()\n    let busy = false\n    const post = async (sessionID) => {\n      const token = hookToken()\n      if (!token || !sessionID || posted.has(sessionID) || busy) return\n      busy = true\n      try {\n        let info\n        try { info = await (ctx.data && ctx.data.session && ctx.data.session.get ? ctx.data.session.get(sessionID) : undefined) } catch {}\n        if (info && info.parentID) { posted.add(sessionID); return } // a sub-agent's — shown under its parent's Task card\n        const cwd = (info && info.location && info.location.directory) || (ctx.location && ctx.location.directory) || process.cwd()\n        const res = await harnessFetch(\"http://127.0.0.1:19474/api/hook/session-start\", {\n          method: \"POST\",\n          headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n          body: JSON.stringify({\n            engine: \"opencode\",\n            pluginVersion: \"<version>\",\n            sessionId: sessionID,\n            cwd,\n            tmuxPane: pane,\n            callerPid: process.pid,\n            runtimeHints: pane ? [{ backend: \"tmux\", paneId: pane }] : [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }],\n          }),\n        })\n        if (res && res.ok) posted.add(sessionID)\n      } catch {} finally { busy = false }\n    }\n    const check = () => {\n      try { const at = router.current(); if (at && at.type === \"session\" && at.sessionID) post(at.sessionID) } catch {}\n    }\n    check()\n    const timer = setInterval(check, 1000)\n    if (timer && typeof timer.unref === \"function\") timer.unref()\n    return () => clearInterval(timer)\n  },\n}\n",
  "6a284957b3f02006": "// session-register — auto-installed by the machine adapter. Binds this Kilo session to the\n// local machine daemon (127.0.0.1:19474) so it can be mirrored to web/device. No-op if machine isn't running.\nimport { readFileSync } from \"node:fs\"\nconst hookToken = () => { try { return readFileSync(\"<root>/data/hook-token\", \"utf8\").trim() } catch { return \"\" } }\nconst harnessSocket = \"<root>/data/daemon-18473.sock\"\nconst harnessFetch = async (url, init) => {\n  if (!harnessSocket) return fetch(url, init)\n  const { lstatSync } = await import(\"node:fs\")\n  const { dirname } = await import(\"node:path\")\n  const { request } = await import(\"node:http\")\n  const uid = process.getuid?.()\n  const file = lstatSync(harnessSocket), folder = lstatSync(dirname(harnessSocket))\n  if (!file.isSocket() || (file.mode & 0o077) !== 0 || !folder.isDirectory() || (folder.mode & 0o022) !== 0\n    || (uid !== undefined && (file.uid !== uid || folder.uid !== uid))) throw new Error(\"The Harness socket is not private.\")\n  return new Promise((resolve, reject) => {\n    const asked = request({ socketPath: harnessSocket, method: init.method, path: new URL(url).pathname,\n      headers: { ...init.headers, \"content-length\": String(Buffer.byteLength(init.body)) } }, (answer) => {\n      answer.resume()\n      answer.on(\"end\", () => resolve({ ok: answer.statusCode >= 200 && answer.statusCode < 300, status: answer.statusCode }))\n      answer.on(\"error\", reject)\n    })\n    asked.on(\"error\", reject)\n    asked.end(init.body)\n  })\n}\nexport const MachineRegister = async ({ directory, worktree, project, client }) => {\n  const seen = new Set()\n  const post = async (sessionID) => {\n    const pane = process.env.TMUX_PANE\n    // A Harness pty host pane (Windows) names itself HARNESS_PANE=<instance>:%N, and has no TMUX_PANE.\n    const ptyPane = pane ? null : /^(p\\d{1,4}(?:-(?:[0-9A-Za-z.-]{1,32}|h[0-9a-f]{12}))?):(%\\d{1,9})$/.exec(process.env.HARNESS_PANE || \"\")\n    const token = hookToken()\n    if ((!pane && !ptyPane) || !token || !sessionID || seen.has(sessionID)) return\n    seen.add(sessionID)\n    try {\n      await harnessFetch(\"http://127.0.0.1:19474/api/hook/session-start\", {\n        method: \"POST\",\n        headers: { \"content-type\": \"application/json\", \"x-harness-hook-token\": token },\n        body: JSON.stringify({\n          engine: \"kilo\",\n          pluginVersion: \"<version>\",\n          sessionId: sessionID,\n          cwd: directory || worktree || (project && project.worktree) || null,\n          tmuxPane: pane,\n          callerPid: process.pid,\n          runtimeHints: [\n            ...(pane ? [{ backend: \"tmux\", paneId: pane }] : []),\n            ...(ptyPane ? [{ backend: \"ptyhost\", instance: ptyPane[1], paneId: ptyPane[2] }] : []),\n          ],\n        }),\n      })\n    } catch {}\n  }\n  return {\n    event: async ({ event }) => {\n      if (!event) return\n      if (event.type === \"session.created\" || event.type === \"session.updated\") {\n        const p = event.properties || {}\n        const info = p.info || {}\n        if (info.parentID) return // sub-agent child session — shown under its parent's Task card, not a top-level agent\n        await post(info.id || p.sessionID || p.sessionId)\n      }\n    },\n  }\n}\n"
 },
 "outcomes": {
  "cursor: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: empty file": {
   "runs": [
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "e3b0c44298fc1c14"
    }
   }
  },
  "cursor: whitespace only": {
   "runs": [
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "8855c6119660c614"
    }
   }
  },
  "cursor: malformed JSON": {
   "runs": [
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f1dec6e9ee608550"
    }
   }
  },
  "cursor: byte order mark": {
   "runs": [
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "aa25e978046d680e"
    }
   }
  },
  "cursor: JSON null": {
   "runs": [
    {
     "logs": [
      "warn [hooks] cursor install skipped · Cannot read properties of null (reading 'hooks')"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] cursor install skipped · Cannot read properties of null (reading 'hooks')"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "74234e98afe7498f"
    }
   }
  },
  "cursor: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "37517e5f3dc66819"
    }
   }
  },
  "cursor: JSON string": {
   "runs": [
    {
     "logs": [
      "warn [hooks] cursor install skipped · Cannot create property 'hooks' on string 'text'"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] cursor install skipped · Cannot create property 'hooks' on string 'text'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "1e1d0f251d3a76fa"
    }
   }
  },
  "cursor: JSON number": {
   "runs": [
    {
     "logs": [
      "warn [hooks] cursor install skipped · Cannot create property 'hooks' on number '42'"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] cursor install skipped · Cannot create property 'hooks' on number '42'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "73475cb40a568e8d"
    }
   }
  },
  "cursor: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "1c2aeaac473dca87"
    }
   }
  },
  "cursor: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "d05ad8cb738b0c1f"
    }
   }
  },
  "cursor: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "8f5114f5734c2d24"
    }
   }
  },
  "cursor: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "e161f02becaa47e8"
    }
   }
  },
  "cursor: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "8f5114f5734c2d24"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "d979437596e2baaf"
    }
   }
  },
  "cursor: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "8f5114f5734c2d24"
    }
   }
  },
  "cursor: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "444",
     "text": "f46cc82e93ac3dd3"
    }
   }
  },
  "cursor: an unreadable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "200",
     "text": "d979437596e2baaf"
    }
   }
  },
  "cursor: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Cursor hooks.json: Error EACCES open <root>/home/.config/cursor/hooks.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Cursor hooks.json: Error EACCES open <root>/home/.config/cursor/hooks.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "cursor: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Cursor hooks.json: Error EACCES open <root>/home/.config/cursor/hooks.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Cursor hooks.json: Error EACCES open <root>/home/.config/cursor/hooks.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "555"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "d979437596e2baaf"
    }
   }
  },
  "cursor: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "8f5114f5734c2d24"
    }
   }
  },
  "cursor: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Cursor hooks file is invalid JSON; leaving it unchanged: <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "dir",
     "mode": "755"
    }
   }
  },
  "cursor: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Cursor lifecycle/task hooks → <root>/home/.config/cursor/hooks.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Cursor lifecycle/task hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/cursor/hooks.json": {
     "type": "file",
     "mode": "600",
     "text": "8f5114f5734c2d24"
    }
   }
  },
  "opencode: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: empty file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: whitespace only": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: malformed JSON": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: byte order mark": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: JSON null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: JSON string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: JSON number": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "3cd1ae59e87ad8ec"
    }
   }
  },
  "opencode: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "444",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: an unreadable file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write OpenCode 2 TUI plugin: Error EACCES open <root>/home/.config/opencode/plugins/launcher-register/tui.js.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write OpenCode 2 TUI plugin: Error EACCES open <root>/home/.config/opencode/plugins/launcher-register/tui.js.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "opencode: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write OpenCode 2 TUI plugin: Error EACCES open <root>/home/.config/opencode/plugins/launcher-register/tui.js.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write OpenCode 2 TUI plugin: Error EACCES open <root>/home/.config/opencode/plugins/launcher-register/tui.js.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "555"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "3cd1ae59e87ad8ec"
    }
   }
  },
  "opencode: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write OpenCode 2 TUI plugin: Error EISDIR rename <root>/home/.config/opencode/plugins/launcher-register/tui.js.<pid>.tmp <root>/home/.config/opencode/plugins/launcher-register/tui.js"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write OpenCode 2 TUI plugin: Error EISDIR rename <root>/home/.config/opencode/plugins/launcher-register/tui.js.<pid>.tmp <root>/home/.config/opencode/plugins/launcher-register/tui.js"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js.<pid>.tmp": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "600",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: OpenCode 1": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode discovery plugin → <root>/home/.config/opencode/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next opencode session start)",
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode discovery plugin already installed",
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "148abe7c5b7b3a8d"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: OpenCode 1, ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode discovery plugin → <root>/home/.config/opencode/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next opencode session start)",
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode discovery plugin already installed",
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "148abe7c5b7b3a8d"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: no OpenCode installed": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: OpenCode 2 with our OpenCode 1 plugin left": {
   "runs": [
    {
     "logs": [
      "log [hooks] removed incompatible OpenCode 1 discovery plugin",
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "f9d10aad86a45fce"
    }
   }
  },
  "opencode: OpenCode 2 with a foreign plugin where OpenCode 1's goes": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "3cd1ae59e87ad8ec"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "opencode: OpenCode 2 with a folder where OpenCode 1's plugin goes": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to remove OpenCode 1 plugin: Error EISDIR read",
      "log [hooks] installed OpenCode 2 TUI discovery plugin → <root>/home/.config/opencode/plugins/launcher-register/tui.js",
      "log [hooks] (takes effect on the next opencode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to remove OpenCode 1 plugin: Error EISDIR read",
      "log [hooks] OpenCode 2 TUI discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugin/launcher-register.js": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/opencode/plugins/launcher-register/tui.js": {
     "type": "file",
     "mode": "644",
     "text": "b42eab635c185981"
    }
   }
  },
  "kilo: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "e36fbe8da025a902"
    }
   }
  },
  "kilo: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "e36fbe8da025a902"
    }
   }
  },
  "kilo: empty file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: whitespace only": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: malformed JSON": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: byte order mark": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: JSON null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: JSON string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: JSON number": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "e36fbe8da025a902"
    }
   }
  },
  "kilo: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "e36fbe8da025a902"
    }
   }
  },
  "kilo: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "e36fbe8da025a902"
    }
   }
  },
  "kilo: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "e36fbe8da025a902"
    }
   }
  },
  "kilo: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "3cd1ae59e87ad8ec"
    }
   }
  },
  "kilo: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "e36fbe8da025a902"
    }
   }
  },
  "kilo: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "444",
     "text": "e36fbe8da025a902"
    }
   }
  },
  "kilo: an unreadable file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Kilo plugin: Error EACCES open <root>/home/.config/kilo/plugin/launcher-register.js.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Kilo plugin: Error EACCES open <root>/home/.config/kilo/plugin/launcher-register.js.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "kilo: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Kilo plugin: Error EACCES open <root>/home/.config/kilo/plugin/launcher-register.js.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Kilo plugin: Error EACCES open <root>/home/.config/kilo/plugin/launcher-register.js.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "555"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "3cd1ae59e87ad8ec"
    }
   }
  },
  "kilo: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Kilo plugin: Error EISDIR rename <root>/home/.config/kilo/plugin/launcher-register.js.<pid>.tmp <root>/home/.config/kilo/plugin/launcher-register.js"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Kilo plugin: Error EISDIR rename <root>/home/.config/kilo/plugin/launcher-register.js.<pid>.tmp <root>/home/.config/kilo/plugin/launcher-register.js"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js.<pid>.tmp": {
     "type": "file",
     "mode": "644",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "kilo: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Kilo discovery plugin → <root>/home/.config/kilo/plugin/launcher-register.js",
      "log [hooks] (takes effect on the next kilo session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Kilo discovery plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/kilo/plugin/launcher-register.js": {
     "type": "file",
     "mode": "600",
     "text": "6f9caf1088585abe"
    }
   }
  },
  "pi: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "a1d771dcda304b56"
    }
   }
  },
  "pi: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "a1d771dcda304b56"
    }
   }
  },
  "pi: empty file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: whitespace only": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: malformed JSON": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: byte order mark": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: JSON null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: JSON string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: JSON number": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "a1d771dcda304b56"
    }
   }
  },
  "pi: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "a1d771dcda304b56"
    }
   }
  },
  "pi: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "a1d771dcda304b56"
    }
   }
  },
  "pi: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "a1d771dcda304b56"
    }
   }
  },
  "pi: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "2351a62515202212"
    }
   }
  },
  "pi: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "a1d771dcda304b56"
    }
   }
  },
  "pi: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "444",
     "text": "a1d771dcda304b56"
    }
   }
  },
  "pi: an unreadable file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Pi extension: Error EACCES open <root>/home/.pi/agent/extensions/launcher-register.ts.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Pi extension: Error EACCES open <root>/home/.pi/agent/extensions/launcher-register.ts.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "pi: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Pi extension: Error EACCES open <root>/home/.pi/agent/extensions/launcher-register.ts.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Pi extension: Error EACCES open <root>/home/.pi/agent/extensions/launcher-register.ts.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "555"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2351a62515202212"
    }
   }
  },
  "pi: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Pi extension: Error EISDIR rename <root>/home/.pi/agent/extensions/launcher-register.ts.<pid>.tmp <root>/home/.pi/agent/extensions/launcher-register.ts"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Pi extension: Error EISDIR rename <root>/home/.pi/agent/extensions/launcher-register.ts.<pid>.tmp <root>/home/.pi/agent/extensions/launcher-register.ts"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts.<pid>.tmp": {
     "type": "file",
     "mode": "644",
     "text": "2fdcafede309e332"
    }
   }
  },
  "pi: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Pi discovery extension → <root>/home/.pi/agent/extensions/launcher-register.ts",
      "log [hooks] (takes effect on the next pi session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Pi discovery extension already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.pi": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions": {
     "type": "dir",
     "mode": "755"
    },
    "home/.pi/agent/extensions/launcher-register.ts": {
     "type": "file",
     "mode": "600",
     "text": "2fdcafede309e332"
    }
   }
  },
  "amp: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "fe5dc71d557d28f9"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "fe5dc71d557d28f9"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: empty file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: whitespace only": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: malformed JSON": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: byte order mark": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: JSON null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: JSON string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: JSON number": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "fe5dc71d557d28f9"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "fe5dc71d557d28f9"
    }
   }
  },
  "amp: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "fe5dc71d557d28f9"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "fe5dc71d557d28f9"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "f2535bcde1fe8de5"
    }
   }
  },
  "amp: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "fe5dc71d557d28f9"
    }
   }
  },
  "amp: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "444",
     "text": "fe5dc71d557d28f9"
    }
   }
  },
  "amp: an unreadable file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Amp plugin: Error EACCES open <root>/home/.config/amp/plugins/launcher-register.ts.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Amp plugin: Error EACCES open <root>/home/.config/amp/plugins/launcher-register.ts.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "555"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Amp plugin: Error EACCES open <root>/home/.config/amp/plugins/launcher-register.ts.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Amp plugin: Error EACCES open <root>/home/.config/amp/plugins/launcher-register.ts.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "555"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "f2535bcde1fe8de5"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Amp plugin: Error EISDIR rename <root>/home/.config/amp/plugins/launcher-register.ts.<pid>.tmp <root>/home/.config/amp/plugins/launcher-register.ts"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Amp plugin: Error EISDIR rename <root>/home/.config/amp/plugins/launcher-register.ts.<pid>.tmp <root>/home/.config/amp/plugins/launcher-register.ts"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts.<pid>.tmp": {
     "type": "file",
     "mode": "644",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "amp: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Amp plugin → <root>/home/.config/amp/plugins/launcher-register.ts",
      "log [hooks] a NEW amp session picks this up automatically; for one already open, run",
      "log [hooks]   ctrl+o → 'plugins: reload'   (or restart that pane)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Amp plugin already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/amp/plugins/launcher-register.ts": {
     "type": "file",
     "mode": "600",
     "text": "2a463c0e77737a30"
    },
    "home/.harness": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data": {
     "type": "dir",
     "mode": "700"
    },
    "home/.harness/cli/data/amp-sessions": {
     "type": "dir",
     "mode": "700"
    }
   }
  },
  "hermes: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    }
   }
  },
  "hermes: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    }
   ],
   "files": {}
  },
  "hermes: empty file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "988dbdec0e4eb48d"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: whitespace only": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "988dbdec0e4eb48d"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: malformed JSON": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "a55a637998fe4b15"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: byte order mark": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "c51e46f6c146b98d"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: JSON null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "194131200b79cf44"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "2415375113d9c3b5"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: JSON string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "9d989f72a32a29d0"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: JSON number": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "e02d1147e6ef16f8"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "ec7d064fd8392cd4"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "962dfe8b12a6ae73"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "c1a3d9684ed05172"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "3ddcb721806eb9ef"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "f8dc5cc189f51bc0"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "f8dc5cc189f51bc0"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "f8dc5cc189f51bc0"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "f8dc5cc189f51bc0"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "3ddcb721806eb9ef"
    }
   }
  },
  "hermes: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "f8dc5cc189f51bc0"
    }
   }
  },
  "hermes: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "link",
     "target": "<root>/elsewhere/missing"
    }
   }
  },
  "hermes: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "link",
     "target": "<root>/elsewhere/gone/missing"
    }
   }
  },
  "hermes: a read-only file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Hermes config.yaml: Error EACCES open <root>/home/.hermes/config.yaml"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Hermes config.yaml: Error EACCES open <root>/home/.hermes/config.yaml"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "444",
     "text": "7e98aa9bd960a936"
    }
   }
  },
  "hermes: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "444",
     "text": "f8dc5cc189f51bc0"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: an unreadable file": {
   "runs": [
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "200",
     "text": "7e98aa9bd960a936"
    }
   }
  },
  "hermes: a read-only folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "hermes: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Hermes config.yaml: Error EACCES open <root>/home/.hermes/shell-hooks-allowlist.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] hermes install skipped · EACCES: permission denied, open '<root>/home/.hermes/shell-hooks-allowlist.json.<pid>.tmp'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "555"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "3ddcb721806eb9ef"
    }
   }
  },
  "hermes: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "600",
     "text": "3ddcb721806eb9ef"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: the file is a folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] no Hermes config at <root>/home/.hermes/config.yaml — skipping (run hermes once first)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "dir",
     "mode": "755"
    }
   }
  },
  "hermes: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "3ddcb721806eb9ef"
    },
    "home/.hermes/config.yaml.<pid>.tmp": {
     "type": "file",
     "mode": "600",
     "text": "ef875a1705a5fdac"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: a foreign hooks mapping": {
   "runs": [
    {
     "logs": [
      "error [hooks] <root>/home/.hermes/config.yaml has its own `hooks:` block — leaving it untouched.",
      "error [hooks] add these entries under it manually to mirror Hermes sessions:",
      "error [hooks]   on_session_start: [{ command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\", timeout: 10 }]",
      "error [hooks]   pre_llm_call: [{ command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\", timeout: 10 }]"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] <root>/home/.hermes/config.yaml has its own `hooks:` block — leaving it untouched.",
      "error [hooks] add these entries under it manually to mirror Hermes sessions:",
      "error [hooks]   on_session_start: [{ command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\", timeout: 10 }]",
      "error [hooks]   pre_llm_call: [{ command: \"'<node>' '<script>' --port 19473 --data-dir '<root>/data' --claude-projects-dir '<root>/home/.claude/projects' --codex-home '<root>/home/.codex' --grok-home '<root>/home/.grok' --cursor-home '<root>/home/.cursor' --hermes-home '<root>/home/.hermes' --commandcode-home '<root>/home/.commandcode' --devin-home '<root>/home/.local/share/devin/cli' --agy-home '<root>/home/.gemini/antigravity-cli' --copilot-home '<root>/home/.copilot' --engine hermes\", timeout: 10 }]"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "7f0a907cf4b87d22"
    }
   }
  },
  "hermes: our block twice, the first old": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks (collapsed 2 stale blocks) → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "f8dc5cc189f51bc0"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "hermes: a profile with a config": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)",
      "log [hooks] installed Hermes session hooks → <root>/home/.hermes/profiles/work/config.yaml",
      "log [hooks] (takes effect on the next hermes session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Hermes session hooks already installed",
      "log [hooks] Hermes session hooks already installed (work)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.hermes": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "f8dc5cc189f51bc0"
    },
    "home/.hermes/profiles": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/profiles/empty": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/profiles/work": {
     "type": "dir",
     "mode": "755"
    },
    "home/.hermes/profiles/work/config.yaml": {
     "type": "file",
     "mode": "644",
     "text": "4632a48e3e660bef"
    },
    "home/.hermes/profiles/work/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "cbf0d4d9801fa8ab"
    },
    "home/.hermes/shell-hooks-allowlist.json": {
     "type": "file",
     "mode": "644",
     "text": "1b00ee446739f819"
    }
   }
  },
  "devin: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: empty file": {
   "runs": [
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "e3b0c44298fc1c14"
    }
   }
  },
  "devin: whitespace only": {
   "runs": [
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "8855c6119660c614"
    }
   }
  },
  "devin: malformed JSON": {
   "runs": [
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "f1dec6e9ee608550"
    }
   }
  },
  "devin: byte order mark": {
   "runs": [
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "aa25e978046d680e"
    }
   }
  },
  "devin: JSON null": {
   "runs": [
    {
     "logs": [
      "warn [hooks] devin install skipped · Cannot read properties of null (reading 'hooks')"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] devin install skipped · Cannot read properties of null (reading 'hooks')"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "74234e98afe7498f"
    }
   }
  },
  "devin: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "37517e5f3dc66819"
    }
   }
  },
  "devin: JSON string": {
   "runs": [
    {
     "logs": [
      "warn [hooks] devin install skipped · Cannot create property 'hooks' on string 'text'"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] devin install skipped · Cannot create property 'hooks' on string 'text'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "1e1d0f251d3a76fa"
    }
   }
  },
  "devin: JSON number": {
   "runs": [
    {
     "logs": [
      "warn [hooks] devin install skipped · Cannot create property 'hooks' on number '42'"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] devin install skipped · Cannot create property 'hooks' on number '42'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "73475cb40a568e8d"
    }
   }
  },
  "devin: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "39001c2ca3ede641"
    }
   }
  },
  "devin: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "527e053b72e46170"
    }
   }
  },
  "devin: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "0dfbbe04f73adf3d"
    }
   }
  },
  "devin: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "5a8f51f91dde0a5b"
    }
   }
  },
  "devin: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "0dfbbe04f73adf3d"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "6d5b174c2e259967"
    }
   }
  },
  "devin: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "0dfbbe04f73adf3d"
    }
   }
  },
  "devin: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "444",
     "text": "139af7531520d198"
    }
   }
  },
  "devin: an unreadable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "200",
     "text": "6d5b174c2e259967"
    }
   }
  },
  "devin: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Devin config.json: Error EACCES open <root>/home/.config/devin/config.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Devin config.json: Error EACCES open <root>/home/.config/devin/config.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "devin: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Devin config.json: Error EACCES open <root>/home/.config/devin/config.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Devin config.json: Error EACCES open <root>/home/.config/devin/config.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "555"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "6d5b174c2e259967"
    }
   }
  },
  "devin: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "644",
     "text": "0dfbbe04f73adf3d"
    }
   }
  },
  "devin: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Devin config file is invalid JSON; leaving it unchanged: <root>/home/.config/devin/config.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "dir",
     "mode": "755"
    }
   }
  },
  "devin: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Devin SessionStart/UserPromptSubmit/Stop/SessionEnd hooks → <root>/home/.config/devin/config.json",
      "log [hooks] (takes effect on the next devin session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Devin session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin": {
     "type": "dir",
     "mode": "755"
    },
    "home/.config/devin/config.json": {
     "type": "file",
     "mode": "600",
     "text": "0dfbbe04f73adf3d"
    }
   }
  },
  "commandcode: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: empty file": {
   "runs": [
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e3b0c44298fc1c14"
    }
   }
  },
  "commandcode: whitespace only": {
   "runs": [
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "8855c6119660c614"
    }
   }
  },
  "commandcode: malformed JSON": {
   "runs": [
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "f1dec6e9ee608550"
    }
   }
  },
  "commandcode: byte order mark": {
   "runs": [
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "aa25e978046d680e"
    }
   }
  },
  "commandcode: JSON null": {
   "runs": [
    {
     "logs": [
      "warn [hooks] commandcode install skipped · Cannot read properties of null (reading 'hooks')"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] commandcode install skipped · Cannot read properties of null (reading 'hooks')"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "74234e98afe7498f"
    }
   }
  },
  "commandcode: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "37517e5f3dc66819"
    }
   }
  },
  "commandcode: JSON string": {
   "runs": [
    {
     "logs": [
      "warn [hooks] commandcode install skipped · Cannot create property 'hooks' on string 'text'"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] commandcode install skipped · Cannot create property 'hooks' on string 'text'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "1e1d0f251d3a76fa"
    }
   }
  },
  "commandcode: JSON number": {
   "runs": [
    {
     "logs": [
      "warn [hooks] commandcode install skipped · Cannot create property 'hooks' on number '42'"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] commandcode install skipped · Cannot create property 'hooks' on number '42'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "73475cb40a568e8d"
    }
   }
  },
  "commandcode: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "49b2b24292764fcd"
    }
   }
  },
  "commandcode: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "527e053b72e46170"
    }
   }
  },
  "commandcode: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "32816609de0e4204"
    }
   }
  },
  "commandcode: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "af11bf73d6bcc670"
    }
   }
  },
  "commandcode: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "32816609de0e4204"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "d22cca3856723e32"
    }
   }
  },
  "commandcode: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "32816609de0e4204"
    }
   }
  },
  "commandcode: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "444",
     "text": "e6ba49d50df273e3"
    }
   }
  },
  "commandcode: an unreadable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "200",
     "text": "d22cca3856723e32"
    }
   }
  },
  "commandcode: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Command Code settings.json: Error EACCES open <root>/home/.commandcode/settings.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Command Code settings.json: Error EACCES open <root>/home/.commandcode/settings.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "commandcode: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Command Code settings.json: Error EACCES open <root>/home/.commandcode/settings.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Command Code settings.json: Error EACCES open <root>/home/.commandcode/settings.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "555"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "d22cca3856723e32"
    }
   }
  },
  "commandcode: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "644",
     "text": "32816609de0e4204"
    }
   }
  },
  "commandcode: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Command Code settings file is invalid JSON; leaving it unchanged: <root>/home/.commandcode/settings.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "dir",
     "mode": "755"
    }
   }
  },
  "commandcode: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Command Code SessionStart/Stop hooks → <root>/home/.commandcode/settings.json",
      "log [hooks] (takes effect on the next commandcode session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Command Code session hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.commandcode": {
     "type": "dir",
     "mode": "755"
    },
    "home/.commandcode/settings.json": {
     "type": "file",
     "mode": "600",
     "text": "32816609de0e4204"
    }
   }
  },
  "grok: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: empty file": {
   "runs": [
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "e3b0c44298fc1c14"
    }
   }
  },
  "grok: whitespace only": {
   "runs": [
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "8855c6119660c614"
    }
   }
  },
  "grok: malformed JSON": {
   "runs": [
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1dec6e9ee608550"
    }
   }
  },
  "grok: byte order mark": {
   "runs": [
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "aa25e978046d680e"
    }
   }
  },
  "grok: JSON null": {
   "runs": [
    {
     "logs": [
      "warn [hooks] grok install skipped · Cannot read properties of null (reading 'hooks')"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] grok install skipped · Cannot read properties of null (reading 'hooks')"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "74234e98afe7498f"
    }
   }
  },
  "grok: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "37517e5f3dc66819"
    }
   }
  },
  "grok: JSON string": {
   "runs": [
    {
     "logs": [
      "warn [hooks] grok install skipped · Cannot create property 'hooks' on string 'text'"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] grok install skipped · Cannot create property 'hooks' on string 'text'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "1e1d0f251d3a76fa"
    }
   }
  },
  "grok: JSON number": {
   "runs": [
    {
     "logs": [
      "warn [hooks] grok install skipped · Cannot create property 'hooks' on number '42'"
     ],
     "threw": null
    },
    {
     "logs": [
      "warn [hooks] grok install skipped · Cannot create property 'hooks' on number '42'"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "73475cb40a568e8d"
    }
   }
  },
  "grok: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "a96e546fddafe1ca"
    }
   }
  },
  "grok: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "527e053b72e46170"
    }
   }
  },
  "grok: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "78cc36f86512ef3a"
    }
   }
  },
  "grok: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "70e69a09d8231b2e"
    }
   }
  },
  "grok: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "78cc36f86512ef3a"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "2a9811d493ce83b8"
    }
   }
  },
  "grok: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "78cc36f86512ef3a"
    }
   }
  },
  "grok: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "444",
     "text": "fdf01705b60e85fe"
    }
   }
  },
  "grok: an unreadable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "200",
     "text": "2a9811d493ce83b8"
    }
   }
  },
  "grok: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Grok hook file: Error EACCES open <root>/home/.grok/hooks/harness.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Grok hook file: Error EACCES open <root>/home/.grok/hooks/harness.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "grok: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Grok hook file: Error EACCES open <root>/home/.grok/hooks/harness.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Grok hook file: Error EACCES open <root>/home/.grok/hooks/harness.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "555"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "2a9811d493ce83b8"
    }
   }
  },
  "grok: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "78cc36f86512ef3a"
    }
   }
  },
  "grok: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] Grok hooks file is invalid JSON; leaving it unchanged: <root>/home/.grok/hooks/harness.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "dir",
     "mode": "755"
    }
   }
  },
  "grok: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Grok lifecycle/StopFailure hooks → <root>/home/.grok/hooks/harness.json",
      "log [hooks] (takes effect on the next Grok session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Grok lifecycle/StopFailure hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.grok": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.grok/hooks/harness.json": {
     "type": "file",
     "mode": "600",
     "text": "78cc36f86512ef3a"
    }
   }
  },
  "agy: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: empty file": {
   "runs": [
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "e3b0c44298fc1c14"
    }
   }
  },
  "agy: whitespace only": {
   "runs": [
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "8855c6119660c614"
    }
   }
  },
  "agy: malformed JSON": {
   "runs": [
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "f1dec6e9ee608550"
    }
   }
  },
  "agy: byte order mark": {
   "runs": [
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "aa25e978046d680e"
    }
   }
  },
  "agy: JSON null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: JSON string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: JSON number": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "a9f7351b00036d4d"
    }
   }
  },
  "agy: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "16151c74ec74cbf0"
    }
   }
  },
  "agy: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "fccdf49d2cc702e9"
    }
   }
  },
  "agy: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "36167d06eb75fd75"
    }
   }
  },
  "agy: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "aa2b391f4878627a"
    }
   }
  },
  "agy: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "36167d06eb75fd75"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "ea6df51da052bef4"
    }
   }
  },
  "agy: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "36167d06eb75fd75"
    }
   }
  },
  "agy: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "444",
     "text": "49e01513b7aa4e4b"
    }
   }
  },
  "agy: an unreadable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "200",
     "text": "ea6df51da052bef4"
    }
   }
  },
  "agy: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write agy hook file: Error EACCES open <root>/home/.gemini/config/hooks.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write agy hook file: Error EACCES open <root>/home/.gemini/config/hooks.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "agy: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write agy hook file: Error EACCES open <root>/home/.gemini/config/hooks.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write agy hook file: Error EACCES open <root>/home/.gemini/config/hooks.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "555"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "ea6df51da052bef4"
    }
   }
  },
  "agy: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "644",
     "text": "36167d06eb75fd75"
    }
   }
  },
  "agy: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] agy hooks file is invalid JSON; leaving it unchanged: <root>/home/.gemini/config/hooks.json",
      "error [hooks] fix the file, then restart harness login"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "dir",
     "mode": "755"
    }
   }
  },
  "agy: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed agy lifecycle hooks → <root>/home/.gemini/config/hooks.json",
      "log [hooks] (takes effect on the next agy session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] agy lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.gemini": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config": {
     "type": "dir",
     "mode": "755"
    },
    "home/.gemini/config/hooks.json": {
     "type": "file",
     "mode": "600",
     "text": "36167d06eb75fd75"
    }
   }
  },
  "copilot: no file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: no home folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: empty file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: whitespace only": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: malformed JSON": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: byte order mark": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: JSON null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: JSON array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: JSON string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: JSON number": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: hooks is a string": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: hooks is an array": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: hooks is null": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: ours from an older install": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: ours current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: ours current, minified": {
   "runs": [
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "df185b4913284039"
    }
   }
  },
  "copilot: ours current for another port": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: a symlink to foreign content": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "3d5035418d5226f3"
    }
   }
  },
  "copilot: a symlink to current content": {
   "runs": [
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "link",
     "target": "<root>/elsewhere/real"
    },
    "elsewhere/real": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: a dangling symlink": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: a symlink into a missing folder": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: a read-only file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: a read-only file, current": {
   "runs": [
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "444",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: an unreadable file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: a read-only folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Copilot hook file: Error EACCES open <root>/home/.copilot/hooks/harness.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Copilot hook file: Error EACCES open <root>/home/.copilot/hooks/harness.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "555"
    }
   }
  },
  "copilot: a read-only folder holding a writable file": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Copilot hook file: Error EACCES open <root>/home/.copilot/hooks/harness.json.<pid>.tmp"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Copilot hook file: Error EACCES open <root>/home/.copilot/hooks/harness.json.<pid>.tmp"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "555"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "3d5035418d5226f3"
    }
   }
  },
  "copilot: a private file": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: the file is a folder": {
   "runs": [
    {
     "logs": [
      "error [hooks] failed to write Copilot hook file: Error EISDIR rename <root>/home/.copilot/hooks/harness.json.<pid>.tmp <root>/home/.copilot/hooks/harness.json"
     ],
     "threw": null
    },
    {
     "logs": [
      "error [hooks] failed to write Copilot hook file: Error EISDIR rename <root>/home/.copilot/hooks/harness.json.<pid>.tmp <root>/home/.copilot/hooks/harness.json"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json.<pid>.tmp": {
     "type": "file",
     "mode": "644",
     "text": "f1d871558bc6b03b"
    }
   }
  },
  "copilot: a temporary file left by this process": {
   "runs": [
    {
     "logs": [
      "log [hooks] installed Copilot lifecycle hooks → <root>/home/.copilot/hooks/harness.json",
      "log [hooks] (takes effect on the next copilot session start)"
     ],
     "threw": null
    },
    {
     "logs": [
      "log [hooks] Copilot lifecycle hooks already installed"
     ],
     "threw": null
    }
   ],
   "files": {
    "home/.copilot": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks": {
     "type": "dir",
     "mode": "755"
    },
    "home/.copilot/hooks/harness.json": {
     "type": "file",
     "mode": "600",
     "text": "f1d871558bc6b03b"
    }
   }
  }
 }
}