Skip to content

feat: add branch comparison view with conflict detection and PR review#1

Merged
locchh merged 12 commits into
masterfrom
20260329-205124-branch-compare
Apr 4, 2026
Merged

feat: add branch comparison view with conflict detection and PR review#1
locchh merged 12 commits into
masterfrom
20260329-205124-branch-compare

Conversation

@locchh
Copy link
Copy Markdown
Owner

@locchh locchh commented Mar 29, 2026

Summary

Adds a branch comparison feature to Commit Explorer, enabling detailed
diff analysis between any two remote branches — from both the TUI and CLI.

What's New

  • Compare screen (c key): dedicated TUI screen to compare two branches,
    showing diff summary, changed files with +/- counts, unique commits, and
    conflict detection
  • Detailed export (Export button / --compare flag): writes a full
    .txt report with git diff and git log --stat output
  • PR/MR review (--pr <URL> / PR number in TUI): resolves base and head
    branches from a GitHub PR or GitLab MR URL, supports cross-fork PRs
  • CLI flags:
    • cex owner/repo --compare main feature/foo
    • cex --pr https://github.com/owner/repo/pull/123

Technical Notes

  • Works with filter=blob:none partial clones — fetches blobs on demand
    for diff and stat calculations only
  • Cross-fork PRs: adds fork as pr-head remote, fetches head branch, then
    compares origin/<base> vs pr-head/<head>
  • Conflict detection via git merge-tree (no working tree needed)

Spec

specs/20260329-205124-branch-compare/

@locchh locchh merged commit 9ee67a4 into master Apr 4, 2026
@locchh locchh deleted the 20260329-205124-branch-compare branch April 4, 2026 04:10
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