{"draft":null,"from":175,"to":318,"files":[{"path":"client/test/install.test.ts","added":28,"removed":3,"diff":"--- a/client/test/install.test.ts\n+++ b/client/test/install.test.ts\n@@ -26,6 +26,8 @@\n import { clientVersion, headCommit } from \"../src/client-version.ts\";\n import {\n \tAVCS_MOD,\n+\thookCommand,\n+\tinstallerCommand,\n \tinstallMod,\n \tkeptModCommit,\n \ttype ModSpec,\n@@ -113,6 +115,28 @@\n \t\t);\n \t});\n \n+\tit(\"stamps the command that runs this client's abso hook, where stamp.ts has a HOOK_COMMAND line\", () => {\n+\t\tconst spec = source({\n+\t\t\t\"hooks/stamp.ts\":\n+\t\t\t\t\"export const STAMP: string | undefined = undefined\\nexport const HOOK_COMMAND: readonly string[] | undefined = undefined\\n\",\n+\t\t});\n+\t\tconst target = join(temp(), \"avcs\");\n+\t\tinstallMod(spec, {\n+\t\t\ttarget,\n+\t\t\tcheck: pass,\n+\t\t\tcommit: \"702c616\",\n+\t\t\thookCommand: [\"C:\\\\node.exe\", \"C:\\\\abso\\\\client\\\\abso.ts\", \"hook\"],\n+\t\t});\n+\t\tassert.equal(\n+\t\t\tread(target, \"hooks/stamp.ts\"),\n+\t\t\t\"export const STAMP: string | undefined = '0.1.0+702c616'\\n\" +\n+\t\t\t\t'export const HOOK_COMMAND: readonly string[] | undefined = [\"C:\\\\\\\\node.exe\",\"C:\\\\\\\\abso\\\\\\\\client\\\\\\\\abso.ts\",\"hook\"]\\n',\n+\t\t);\n+\t\t// By default, this checkout's own: the node running it and client/abso.ts.\n+\t\tassert.deepEqual(hookCommand().slice(0, 1), [process.execPath]);\n+\t\tassert.match(hookCommand()[1]!, /client[\\\\/]abso\\.ts$/);\n+\t});\n+\n \tit(\"moves the files in by rename, what the hook imports first and plugin.json last\", () => {\n \t\tconst spec = source();\n \t\tconst target = join(temp(), \"avcs\");\n@@ -427,9 +451,10 @@\n \t\tassert.equal(client, `abso ${clientVersion()} (${dirname(import.meta.dirname)})`);\n \t\tassert.match(\n \t\t\tmod!,\n-\t\t\t/^the abso-hooks mod: 0\\.1\\.0\\+aaaaaaa in .*skills[\\\\/]abso-hooks, installed 2026-10-05 04:30 UTC; this client has 0.2.0(\\+[0-9a-f]{7}(\\.dirty)?)?: node client\\/install-mod\\.ts installs it$/,\n+\t\t\t/^the abso-hooks mod: 0\\.1\\.0\\+aaaaaaa in .*skills[\\\\/]abso-hooks, installed 2026-10-05 04:30 UTC; this client has 0.2.0(\\+[0-9a-f]{7}(\\.dirty)?)?: /,\n \t\t);\n-\t\tassert.equal(view, \"the abso-view mod: not installed (node client/install-view.ts)\");\n+\t\tassert.ok(mod!.endsWith(`: ${installerCommand(\"install-mod.ts\")} installs it`), mod);\n+\t\tassert.equal(view, `the abso-view mod: not installed (${installerCommand(\"install-view.ts\")})`);\n \t\tconst json = JSON.parse(\n \t\t\t(await main([\"--version\", \"--json\"], { cwd: config, env: { CLAUDE_CONFIG_DIR: config }, write: () => {} }))\n \t\t\t\t.stdout,\n@@ -474,7 +499,7 @@\n \t\tconst current = (versionReport(env).json.mods as { current: string }[])[0]!.current;\n \t\tif (/\\+[0-9a-f]{7}$/.test(current))\n \t\t\tassert.deepEqual(modsBehindText(env), [\n-\t\t\t\t`The avcs mod installed on this machine is 0.1.0+aaaaaaa, and this client has ${current}: node client/install-mod.ts installs it (new chats load it).`,\n+\t\t\t\t`The ${AVCS_MOD.name} mod installed on this machine is 0.1.0+aaaaaaa, and this client has ${current}: ${installerCommand(\"install-mod.ts\")} installs it (new chats load it).`,\n \t\t\t]);\n \t\t// A client outside git (an abso folder, a box) can't tell, so it says nothing.\n \t\telse assert.deepEqual(modsBehindText(env), []);"}],"unmatched":[]}