diff --git a/hooks/ponytail-activate.js b/hooks/ponytail-activate.js index 25f4e48..3087c7c 100644 --- a/hooks/ponytail-activate.js +++ b/hooks/ponytail-activate.js @@ -66,7 +66,7 @@ if (!isCodex && !isCopilot) try { output += "\n\n" + "STATUSLINE SETUP NEEDED: The ponytail plugin includes a statusline badge showing active mode " + "(e.g. [PONYTAIL], [PONYTAIL:ULTRA]). It is not configured yet. " + - "To enable, add this to ~/.claude/settings.json: " + + "To enable, add this to " + settingsPath + ": " + statusLineSnippet + " " + "Proactively offer to set this up for the user on first interaction."; } else { @@ -76,7 +76,7 @@ if (!isCodex && !isCopilot) try { "STATUSLINE SETUP NEEDED: The ponytail plugin includes a statusline badge showing active mode. " + "Its install path contains characters unsafe to embed in a shell command, so configure it manually: " + "add a statusLine command of type \"command\" that runs " + scriptName + - " from the plugin's hooks directory to ~/.claude/settings.json, quoting/escaping the path for your shell. " + + " from the plugin's hooks directory to " + settingsPath + ", quoting/escaping the path for your shell. " + "Proactively offer to set this up for the user on first interaction."; } } diff --git a/tests/hooks.test.js b/tests/hooks.test.js index a4b1cb3..4c3687c 100644 --- a/tests/hooks.test.js +++ b/tests/hooks.test.js @@ -133,6 +133,12 @@ assert.equal( false, 'flag must not land in ~/.claude when CLAUDE_CONFIG_DIR is set', ); +// The statusline setup nudge must point at the configured settings.json, not a +// hardcoded ~/.claude (issue #250). +assert.ok( + result.stdout.includes(path.join(customConfigDir, 'settings.json')), + 'statusline nudge must reference the CLAUDE_CONFIG_DIR settings.json', +); const copilotData = path.join(temp, 'copilot-data'); const codexData = path.join(temp, 'codex-data-shadow');