#!/usr/bin/env bash
# Run from either isolated checkout after starting T3CODE_DEV_SEED=0 vp run dev.
# Supply the same fresh demo repository to each side; each server owns a fresh database.
set -eu
: "${DEMO_REPO:?Set DEMO_REPO to a fresh demo git repository}"
node apps/server/src/bin.ts project add "$DEMO_REPO" --title 'Fork history demo' --base-dir .t3
node apps/server/src/bin.ts thread start "$DEMO_REPO" 'Remember this fact for later: the project codename is PINEAPPLE-7421. Reply with just OK.' --title 'Parent conversation' --provider codex --model gpt-6-luna --wait --json --base-dir .t3
