#!/usr/bin/env bash
# Run in each checkout after vp i, with EVIDENCE_DIR pointing to the directory containing fixture.html.
# Start a loopback server once: python3 -m http.server 19388 --bind 127.0.0.1 --directory "$EVIDENCE_DIR"
# Start each desktop with a separate config profile and CDP port:
# XDG_CONFIG_HOME="$EVIDENCE_DIR/profile-$SIDE" T3CODE_DEV_SEED=0 T3CODE_DESKTOP_REMOTE_DEBUGGING_PORT="$PORT" headless-desktop vp run dev:desktop
node apps/server/src/bin.ts project add "$EVIDENCE_DIR" --title 'Top-layer demo' --base-dir .t3
# In each app: Toggle right panel, Browser, enter http://127.0.0.1:19388/fixture.html.
# Use xwininfo to identify the app window and the launch process environment for DISPLAY/XAUTHORITY.
# T3_CHECKOUT="$PWD" CAPTURE_DISPLAY="$DISPLAY" CAPTURE_AUTH="$XAUTHORITY" node "$EVIDENCE_DIR/proof-driver.cjs" "$PORT" "$SIDE"
# The driver writes recording.mp4 in real time and four stable PNG captures.
