Skip to content

Commit 9c577bf

Browse files
author
zenus
committed
Create round-0 summary scaffold during RLCR setup
1 parent 7359345 commit 9c577bf

3 files changed

Lines changed: 36 additions & 0 deletions

File tree

scripts/setup-rlcr-loop.sh

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1044,6 +1044,10 @@ SUMMARY_TMPL_EOF
10441044

10451045
SUMMARY_PATH="$LOOP_DIR/round-0-summary.md"
10461046

1047+
# Create the round-0 summary scaffold before either mode starts so stop-hook
1048+
# validation and BitLesson Delta checks have a valid target file.
1049+
write_summary_template "$SUMMARY_PATH"
1050+
10471051
if [[ "$SKIP_IMPL" == "true" ]]; then
10481052
# Skip-impl mode: create a prompt for code review only
10491053
cat > "$LOOP_DIR/round-0-prompt.md" << EOF

tests/robustness/test-setup-scripts-robustness.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1069,6 +1069,22 @@ else
10691069
fail "--skip-impl goal-tracker" "goal-tracker.md exists" "not found"
10701070
fi
10711071

1072+
# Test 44b: --skip-impl creates summary scaffold with BitLesson Delta section
1073+
echo ""
1074+
echo "Test 44b: --skip-impl creates summary scaffold"
1075+
if [[ -n "$LOOP_DIR" ]] && [[ -f "$LOOP_DIR/round-0-summary.md" ]]; then
1076+
if grep -q '^## BitLesson Delta$' "$LOOP_DIR/round-0-summary.md" && \
1077+
grep -q '^Action: none$' "$LOOP_DIR/round-0-summary.md"; then
1078+
pass "--skip-impl creates round-0 summary scaffold with BitLesson Delta defaults"
1079+
else
1080+
fail "--skip-impl summary scaffold" \
1081+
"BitLesson Delta section with Action: none" \
1082+
"$(cat "$LOOP_DIR/round-0-summary.md")"
1083+
fi
1084+
else
1085+
fail "--skip-impl summary scaffold" "round-0-summary.md exists" "not found"
1086+
fi
1087+
10721088
# Test 45: --skip-impl with plan file still works
10731089
echo ""
10741090
echo "Test 45: --skip-impl with plan file still works"

tests/test-unified-codex-config.sh

Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -596,6 +596,22 @@ PLAN_EOF
596596
else
597597
pass "setup execution: state.md was created"
598598

599+
SUMMARY_FILE="$(dirname "$STATE_FILE")/round-0-summary.md"
600+
if [[ -f "$SUMMARY_FILE" ]]; then
601+
if grep -q '^## BitLesson Delta$' "$SUMMARY_FILE" && \
602+
grep -q '^Action: none$' "$SUMMARY_FILE"; then
603+
pass "setup execution: round-0 summary scaffold includes BitLesson Delta defaults"
604+
else
605+
fail "setup execution: round-0 summary scaffold includes BitLesson Delta defaults" \
606+
"BitLesson Delta scaffold" \
607+
"$(cat "$SUMMARY_FILE")"
608+
fi
609+
else
610+
fail "setup execution: round-0 summary scaffold was created" \
611+
"round-0-summary.md exists" \
612+
"not found"
613+
fi
614+
599615
# Verify codex_model from --codex-model flag
600616
assert_eq "setup execution: --codex-model set codex_model (gpt-5.3)" \
601617
"gpt-5.3" "$(grep '^codex_model:' "$STATE_FILE" | sed 's/codex_model: *//')"

0 commit comments

Comments
 (0)