Verify Run

Path: loom-builder-sol/scripts/verify-run.shRelative: scripts/verify-run.shSubproject: loom-builder-solCategory: dispatch-scripts-sol
Lines: 80Bytes: 2,593Imports: 0Exports: 0

Content Preview

  1. #!/usr/bin/env bash
  2. # verify-run.sh — verify a loom-builder run directory.
  3. # Usage: scripts/verify-run.sh <runDir>
  4. # Exit 0 = verified, non-zero = one-line reason to stderr.
  5. set -euo pipefail
  6. RUN_DIR="${1:-}"
  7. if [[ -z "$RUN_DIR" ]]; then
  8. echo "usage: scripts/verify-run.sh <runDir>" >&2
  9. exit 1
  10. fi
  11. if [[ ! -d "$RUN_DIR" ]]; then
  12. echo "FAIL: run dir not found: $RUN_DIR" >&2
  13. exit 1
  14. fi
  15. # 1. MANIFEST.json must parse and have verdict=COMPLETE
  16. MANIFEST="$RUN_DIR/MANIFEST.json"
  17. if [[ ! -f "$MAN