Skip to content

feat: group loop result output into sections#64

Merged
satyaborg merged 1 commit into
mainfrom
refactor/result-output-sections
Jun 16, 2026
Merged

feat: group loop result output into sections#64
satyaborg merged 1 commit into
mainfrom
refactor/result-output-sections

Conversation

@satyaborg

Copy link
Copy Markdown
Owner

Problem

The loop's final result block was a flat list of lowercase label: value lines, and the worktree-shell entry guards were duplicated between maybe_enter_worktree and display_path, where they could drift.

Approach

  • Reformat print_result into sections: devloop <status> header → key/values → Open Next (PR/Report/Track) → optional Shell hint.
  • Extract the six worktree-shell entry conditions into a single predicate will_enter_worktree_shell, reused by maybe_enter_worktree, the Shell hint, and display_path.
  • display_path now renders report/track paths relative when the user will be dropped into the worktree shell (cwd becomes the worktree), and worktree-qualified otherwise — driven by the same predicate so the two can't disagree.
  • Relocate the "exit the shell" hint from maybe_enter_worktree into print_result's Shell section (still prints before the shell launches).

Tests

bash scripts/devloop_test.sh — full suite green. Assertions updated for the new format and extended to pin worktree-qualified report/track paths, the Open Next grouping, the PR line, and Commit none.

@cloudflare-workers-and-pages

Copy link
Copy Markdown

Deploying with  Cloudflare Workers  Cloudflare Workers

The latest updates on your project. Learn more about integrating Git with Workers.

Status Name Latest Commit Preview URL Updated (UTC)
✅ Deployment successful!
View logs
devloop 26b3c6f Commit Preview URL

Branch Preview URL
Jun 16 2026, 01:23 AM

@satyaborg satyaborg merged commit 21038e7 into main Jun 16, 2026
4 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant