#!/usr/bin/env bash
# Widened-panel build driver. Every verdict goes to its own .exit file —
# a harness exit and a leg exit are different numbers (IR-60).
set -u
R=/c/Users/decid/Documents/projects/spt-core
P="$R/.spt"
cd "$R" || exit 99

date -u +%Y-%m-%dT%H:%M:%SZ > "$P/panel_START.ts"

cargo run -q -p xtask -- pool-claim --pool "$R/target" --label panel-b5eeab0a \
  > "$P/panel_claim.raw" 2>&1
echo $? > "$P/panel_claim.exit"

cargo build -p spt --bins > "$P/panel_build.raw" 2>&1
echo $? > "$P/panel_build.exit"

date -u +%Y-%m-%dT%H:%M:%SZ > "$P/panel_END.ts"
