From 2fa26f83cd59765c27cb0db174a39d9f1f1bdba1 Mon Sep 17 00:00:00 2001 From: Konstantin Wohlwend Date: Mon, 25 Aug 2025 12:42:13 -0700 Subject: [PATCH] Create new Claude hook that ensure pnpm run dev is running --- .claude/settings.json | 10 ++++++++++ 1 file changed, 10 insertions(+) diff --git a/.claude/settings.json b/.claude/settings.json index 4923235d0..024e72f94 100644 --- a/.claude/settings.json +++ b/.claude/settings.json @@ -16,6 +16,16 @@ }, "includeCoAuthoredBy": false, "hooks": { + "UserPromptSubmit": [ + { + "hooks": [ + { + "type": "command", + "command": "if ! curl -s --connect-timeout 1 http://localhost:8102 >/dev/null 2>&1; then echo -e '\\n\\n\\033[1;31mCannot reach backend on port 8102! Please run `pnpm run dev` before querying Claude Code\\033[0m\\n\\n' >&2; exit 2; fi" + } + ] + } + ], "PostToolUse": [ { "matcher": "Edit|MultiEdit|Write",