Move brainstorm server metadata to .meta/ subdirectory

Metadata files (.server-info, .events, .server.pid, .server.log,
.server-stopped) were stored in the same directory served over HTTP,
making them accessible via the /files/ route. They now live in a .meta/
subdirectory that is not web-accessible.

Also fixes a stale test assertion ("Waiting for Claude" → "Waiting for
the agent").

Reported-By: 吉田仁
This commit is contained in:
Jesse Vincent
2026-03-24 10:56:12 -07:00
parent a22122d57f
commit ab500dade6
6 changed files with 34 additions and 29 deletions

View File

@@ -83,11 +83,12 @@ else
SCREEN_DIR="/tmp/brainstorm-${SESSION_ID}"
fi
PID_FILE="${SCREEN_DIR}/.server.pid"
LOG_FILE="${SCREEN_DIR}/.server.log"
META_DIR="${SCREEN_DIR}/.meta"
PID_FILE="${META_DIR}/.server.pid"
LOG_FILE="${META_DIR}/.server.log"
# Create fresh session directory
mkdir -p "$SCREEN_DIR"
# Create fresh session directory and metadata subdirectory
mkdir -p "$SCREEN_DIR" "$META_DIR"
# Kill any existing server
if [[ -f "$PID_FILE" ]]; then