create-healix 1.1.5 → 1.1.6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/templates.js +14 -15
package/package.json
CHANGED
package/src/templates.js
CHANGED
|
@@ -144,32 +144,31 @@ export function mcpJson(port = 4000) {
|
|
|
144
144
|
// The re-hydration reminder text — single source, shared by the hook script and
|
|
145
145
|
// kept short so it re-anchors without becoming noise.
|
|
146
146
|
const REHYDRATE_REMINDER =
|
|
147
|
-
'HEALIX
|
|
148
|
-
'
|
|
149
|
-
'
|
|
150
|
-
'
|
|
147
|
+
'HEALIX PROJECT: drive the live browser ONLY through the healix_* MCP tools — ' +
|
|
148
|
+
'every selector is observed live, never guessed, and specs/POMs are authored via ' +
|
|
149
|
+
'the scaffold tools. If the Healix guide is not currently in your context, run ' +
|
|
150
|
+
'healix_guide before any scaffold/heal/run step — do not operate from memory of it.';
|
|
151
151
|
|
|
152
|
-
// Tiny script the
|
|
153
|
-
//
|
|
152
|
+
// Tiny script the hook runs. Living in a FILE (not an inline `node -e`) avoids
|
|
153
|
+
// cross-shell quoting hell — the hook command is just `node <path>`.
|
|
154
154
|
export function claudeRehydrateScript() {
|
|
155
|
-
return `// Printed into the agent's context by the SessionStart(
|
|
155
|
+
return `// Printed into the agent's context by the SessionStart hook (startup + after compaction).\n` +
|
|
156
156
|
`console.log(${JSON.stringify(REHYDRATE_REMINDER)});\n`;
|
|
157
157
|
}
|
|
158
158
|
|
|
159
|
-
// Claude Code SessionStart hook
|
|
160
|
-
//
|
|
161
|
-
//
|
|
162
|
-
//
|
|
163
|
-
//
|
|
164
|
-
//
|
|
165
|
-
// a bare `node <relative path>`
|
|
159
|
+
// Claude Code-format SessionStart hook (host-agnostic: read by any host that
|
|
160
|
+
// supports the .claude/settings.json convention — Claude Code, Spryv, …). No
|
|
161
|
+
// matcher = fires on every SessionStart: it SEEDS the workflow at startup and
|
|
162
|
+
// RE-HYDRATES after a context compaction (when tool results, where the full
|
|
163
|
+
// healix_guide lives, get dropped). The hook's stdout is injected into the
|
|
164
|
+
// agent's context — deterministic, no reliance on the model noticing the guide is
|
|
165
|
+
// gone. The command is a bare `node <relative path>` so it works in cmd/PowerShell/sh.
|
|
166
166
|
export function claudeSettings() {
|
|
167
167
|
return JSON.stringify(
|
|
168
168
|
{
|
|
169
169
|
hooks: {
|
|
170
170
|
SessionStart: [
|
|
171
171
|
{
|
|
172
|
-
matcher: 'compact',
|
|
173
172
|
hooks: [
|
|
174
173
|
{ type: 'command', command: 'node .claude/healix-rehydrate.mjs' },
|
|
175
174
|
],
|