Skip to content

fix(diff): separate every bulk header block with a blank line#34

Merged
rickliujh merged 1 commit into
mainfrom
feat/diff-breadcrumb-visibility
Jul 23, 2026
Merged

fix(diff): separate every bulk header block with a blank line#34
rickliujh merged 1 commit into
mainfrom
feat/diff-breadcrumb-visibility

Conversation

@rickliujh

Copy link
Copy Markdown
Owner

Summary

Follow-up to #33. The module breadcrumb between diffs wasn't visible enough: inside a turn, a submodule's ▸ parent › child hand-off (and a bare target change) printed glued to the end of the diff above it — only the turn banner was set off by a blank line. So a breadcrumb sitting between two diffs got lost in the surrounding diff text.

This leads every header block with a blank line, not just the turn banner — the separator moves out of diffTurnBanner and into the callers (DiffCollector.Print and DiffHeader), emitted whenever a new header block starts.

Before (within a turn)

+kind: ClusterIssuer
+duration: 720h
▸ deploy-k8s-1 › ingress      ← glued to the diff above, easy to miss
file://…/cluster-1 (main)

After

+kind: ClusterIssuer
+duration: 720h

▸ deploy-k8s-1 › ingress      ← blank line sets it apart
file://…/cluster-1 (main)

The rendered header bytes are otherwise unchanged, so full mode and the single-module path are unaffected.

Testing

  • go build ./..., go vet ./..., full go test ./... — all green.
  • Added a within-turn separation assertion to TestDiffCollector_BannerOncePerTurnHandoffPerSubmodule.
  • Drove the built binary against a nested bulk module with two submodules per turn to confirm the real output.

🤖 Generated with Claude Code

Inside a turn, a submodule's "▸ parent › child" hand-off (and a bare target
change) printed glued to the end of the diff above it — only the turn banner
was set off by a blank line. So a breadcrumb sitting between two diffs got
lost in the surrounding diff text.

Lead every header block with a blank line, not just the turn banner: move the
separator out of diffTurnBanner and into the callers (DiffCollector.Print and
DiffHeader), emitted whenever a new header block starts. The rendered header
bytes are otherwise unchanged, so full mode and the single-module path are
unaffected.

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
@rickliujh
rickliujh merged commit 059e31d into main Jul 23, 2026
2 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