Skip to content

Format entire explain generated summary #1078

Merged
peyton-alt merged 13 commits into
mainfrom
format-entire-explain
Apr 30, 2026
Merged

Format entire explain generated summary #1078
peyton-alt merged 13 commits into
mainfrom
format-entire-explain

Conversation

@peyton-alt
Copy link
Copy Markdown
Contributor

@peyton-alt peyton-alt commented Apr 29, 2026

https://entire.io/gh/entireio/cli/trails/265

Summary

  • Reuse the shared Entire markdown styling helpers so entire explain can render generated
    checkpoint summaries with the same branded terminal markdown treatment as dispatch output.
  • Replace the summary-present entire explain body with structured markdown sections for intent,
    outcome, learnings, friction, open items, and verbose/full files while preserving plain markdown for
    piped and NO_COLOR output.
  • Add a compact checkpoint metadata header with session, created time, author, tokens, and
    associated commits, then tighten the summary spacing so ## Intent starts directly under the header
    rule.
  • Refactor pager command construction so default less receives LESS=-R only when the user has
    not set PAGER or LESS.

Test Plan

  • mise run check
  • mise run test:ci
  • Pseudo-terminal smoke check: script -q /tmp/entire-explain-tty.out ./entire explain --checkpoint <checkpointID> --no-pager

Note

Medium Risk
Touches user-facing CLI output formatting and paging behavior; low functional risk but moderate compatibility risk for scripts/tests that parse explain output or rely on previous pager environment defaults.

Overview
Updates entire explain to emit a compact, styled checkpoint header (session/created/author/tokens/commits) and to render AI checkpoint summaries as structured markdown sections (Intent/Outcome/Learnings/Friction/Open Items, plus Files in verbose/full), using the shared terminal markdown renderer and respecting NO_COLOR/piped output.

Refactors transcript display to use section rules and tighter spacing, adjusts output strings across unit/integration/e2e tests and docs, and extracts pager command construction so the default less pager gets LESS=-R only when the user hasn’t set PAGER/LESS (with new tests around env behavior).

Reviewed by Cursor Bugbot for commit e008cc7. Configure here.

Entire-Checkpoint: 36760b92b50f
Entire-Checkpoint: 36fc2763f43f
Entire-Checkpoint: 18c2a872e364
Copilot AI review requested due to automatic review settings April 29, 2026 13:02
Copy link
Copy Markdown
Contributor

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Updates entire explain to emit a more structured, branded output format (header/table + markdown-rendered summary) and adjusts the test suite to match the new strings.

Changes:

  • Reformats explain output header (e.g., ● Checkpoint <id>) and token/commit metadata presentation.
  • Renders AI summaries (and verbose/full file lists) as markdown, with terminal rendering when color is enabled.
  • Improves pager handling by centralizing pager resolution and conditionally injecting LESS=-R for less.

Reviewed changes

Copilot reviewed 6 out of 6 changed files in this pull request and generated 3 comments.

Show a summary per file
File Description
e2e/tests/explain_test.go Updates E2E assertions to match the new explain header format.
e2e/tests/attach_test.go Updates E2E assertions for explain output after attach/resume flows.
cmd/entire/cli/integration_test/explain_test.go Updates integration assertions to match the new checkpoint header string.
cmd/entire/cli/explain_test.go Updates/extends unit tests for the new formatting, markdown summary, header rows, and pager env behavior.
cmd/entire/cli/explain.go Implements the new formatted output, markdown summary builder, header rendering, and pager env injection logic.
cmd/entire/cli/dispatch_tui.go Renames markdown style helpers and switches the renderer to use the shared “entire brand” markdown styles.

Comment thread cmd/entire/cli/explain.go
Comment thread cmd/entire/cli/explain.go
Comment thread cmd/entire/cli/explain.go
Comment thread cmd/entire/cli/explain.go
@peyton-alt
Copy link
Copy Markdown
Contributor Author

see example:
format entire explain

@peyton-alt
Copy link
Copy Markdown
Contributor Author

@BugBot review

Copy link
Copy Markdown

@cursor cursor Bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

✅ Bugbot reviewed your changes and found no new issues!

Comment @cursor review or bugbot run to trigger another review on this PR

Reviewed by Cursor Bugbot for commit e008cc7. Configure here.

@peyton-alt peyton-alt marked this pull request as ready for review April 29, 2026 14:06
@peyton-alt peyton-alt requested a review from a team as a code owner April 29, 2026 14:06
@peyton-alt peyton-alt changed the title Format entire explain Format entire explain output Apr 29, 2026
@peyton-alt peyton-alt changed the title Format entire explain output Format entire explain generated summary Apr 29, 2026
@peyton-alt peyton-alt enabled auto-merge (squash) April 29, 2026 15:30
peyton-alt and others added 5 commits April 30, 2026 12:33
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Entire-Checkpoint: e7f82dfb5f49
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Entire-Checkpoint: 0cca1448b154
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Entire-Checkpoint: b4f9b076e097
Cover no-summary, temporary, list, session, and failure surfaces with the
same identity-bullet + metadata-rows + brand-rendered body shape that PR
on the generated summary already uses. Replace "(no prompt)" with a prompt
→ commit-message → "(no prompt recorded)" cascade. Failures print a styled
✗ block to stderr and return *SilentError so main.go does not double-print.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Entire-Checkpoint: 56895e1cb233
Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Entire-Checkpoint: 726145533b1d
@peyton-alt
Copy link
Copy Markdown
Contributor Author

More examples:
entire explain
entire explain no summary
entire explain short

peyton-alt and others added 3 commits April 30, 2026 15:31
formatSessionInfo has no production caller — entire explain --session
flows through formatBranchCheckpoints (the list view), not here.
Restyling it for the brand format added ~200 lines of dead-code styling
and test churn for a path nobody can reach via the CLI. Restore the
original implementation; if a session-detail surface ever ships, revisit.

Co-Authored-By: Claude Opus 4.7 (1M context) <[email protected]>
Entire-Checkpoint: 3769067bdde9
Copy link
Copy Markdown
Contributor

@toothbrush toothbrush left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Snazzy colours! I'm not really involved in this but approving to unblock the merge 👍 👍 👍

@peyton-alt peyton-alt merged commit e6988fe into main Apr 30, 2026
9 checks passed
@peyton-alt peyton-alt deleted the format-entire-explain branch April 30, 2026 15:54
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Development

Successfully merging this pull request may close these issues.

4 participants