feat: Claude Code Monitor — lanes, pipelines and a merged workspace
Internal SmartGift build of a Claude Code monitoring dashboard. Lanes: a durable unit of parallel agent work, one per working directory, tracked across session restarts. Managed lanes are git worktrees the dashboard provisions and can reset or remove behind a three-check destroy guard and a counted preflight; adopted lanes are directories you already own and are never destroyable. Pipelines: a lane moves through pipeline stages. A stage the agent declares with evidence renders green; a stage inferred from the tool-event stream renders dashed amber and never counts as done. Detection is forward-only within a 30-minute window, and never writes the declared stage. Workspace: one page at /run with a lane grid, the selected lane's pipeline, and a full Claude console behind a disclosure.
This commit is contained in:
Executable
+41
@@ -0,0 +1,41 @@
|
||||
#!/usr/bin/env bash
|
||||
# Dev-container bootstrap. Installs all workspace dependencies and builds the
|
||||
# MCP server. Runs once, after the container is created.
|
||||
#
|
||||
# Deliberately does NOT install Claude Code hooks: hooks are a host-side concern
|
||||
# (issue #193) and `scripts/install-hooks.js` refuses to run inside a container.
|
||||
# @author Nguyễn Ngọc Trí Vĩ <vinnt@smartgift.vn>
|
||||
set -euo pipefail
|
||||
|
||||
echo "▶ Installing server + client + vscode-extension dependencies (npm run setup)…"
|
||||
npm run setup
|
||||
|
||||
echo "▶ Installing and building the MCP server…"
|
||||
npm run mcp:install
|
||||
npm run mcp:build
|
||||
|
||||
cat <<'EOF'
|
||||
|
||||
✅ Dev environment ready.
|
||||
|
||||
Develop:
|
||||
npm run dev # server on :4820 + Vite client on :5173
|
||||
npm start # production-style server (serves client/dist)
|
||||
|
||||
Test:
|
||||
npm run test:server # node --test
|
||||
npm run test:client # vitest
|
||||
npm run test:mcp # MCP server tests
|
||||
npm run mcp:typecheck # MCP type check
|
||||
|
||||
Docs:
|
||||
npm run openapi:yaml # regenerate openapi.yaml from the live spec
|
||||
|
||||
⚠ Claude Code hooks are HOST-side. Do NOT run `npm run install-hooks` in this
|
||||
container — it is refused on purpose (issue #193). Run it on your HOST so the
|
||||
hook handler path exists there and POSTs to http://localhost:4820 (forwarded
|
||||
from this container).
|
||||
|
||||
Electron desktop builds (npm run desktop:*) also need a host with a display
|
||||
and are not supported inside this container.
|
||||
EOF
|
||||
Reference in New Issue
Block a user