Merge branch 'claude-detection-fix'

This commit is contained in:
Chris Wanstrath 2026-02-19 20:08:46 -08:00
commit 1c31d3ed6f

View File

@ -67,9 +67,10 @@ export async function create(log?: (msg: string) => void): Promise<void> {
log?.("Warning: ANTHROPIC_API_KEY not found in ~/.env — claude will require manual login")
}
const activityBin = `/home/${USER}/.local/bin/sandlot-activity`
const hooks = {
UserPromptSubmit: [{ hooks: [{ type: "command", command: "sandlot-activity active" }] }],
Stop: [{ hooks: [{ type: "command", command: "sandlot-activity idle" }] }],
UserPromptSubmit: [{ hooks: [{ type: "command", command: `${activityBin} active` }] }],
Stop: [{ hooks: [{ type: "command", command: `${activityBin} idle` }] }],
}
const settingsJson = JSON.stringify(apiKey
? { apiKeyHelper: "~/.claude/api-key-helper.sh", skipDangerousModePermissionPrompt: true, hooks }