#!/bin/bash set -e if [ -z "$1" ]; then echo "Usage: $0 " exit 1 fi for ((i=1; i<=$1; i++)); do result=$(docker sandbox run claude --permission-mode acceptEdits -p "@prd.json @progress.txt \ 1. Find the highest-priority task and implement it. \ 2. Run your tests and type checks. \ 3. Update the PRD with what was done. \ 4. Append your progress to progress.txt. \ 5. Commit your changes. \ ONLY WORK ON A SINGLE TASK. \ If the PRD is complete, output COMPLETE.") echo "$result" if [[ "$result" == *"COMPLETE"* ]]; then echo "PRD complete after $i iterations." exit 0 fi done