Skip to content

Add stale branch detection and expandable file diffs#20

Merged
Umaaz merged 1 commit into
mainfrom
cosmic-wren
Apr 4, 2026
Merged

Add stale branch detection and expandable file diffs#20
Umaaz merged 1 commit into
mainfrom
cosmic-wren

Conversation

@Umaaz

@Umaaz Umaaz commented Apr 4, 2026

Copy link
Copy Markdown
Contributor

Summary

  • Stale branch detection: Branches are flagged stale based on PR status (merged/closed), remote gone, no commits ahead of origin/main, or inactive >3 days. Dirty worktrees are never stale.
  • PR status badges: Each branch shows its GitHub PR state (open/merged/closed) via gh CLI lookups.
  • Expandable details panel: Click the arrow on any branch to see a split view with file tree (committed vs uncommitted) and syntax-colored diff viewer.
  • Optimistic deletes: Removing a branch no longer reloads the entire list — it just removes the row.
  • Worktree removal fix: Handles suid binaries (chrome-sandbox) that broke fs.rm.
  • Watcher fix: Ignore .konductor/ in both Vite and chokidar to prevent inotify exhaustion from worktree node_modules.

Test plan

  • Open Branches view, verify stale badges appear on merged/empty branches
  • Check PR badges show correct state for branches with PRs
  • Expand a branch with changes, verify file tree and diff load
  • Delete a branch, verify it disappears without full list refresh
  • Remove a worktree with node_modules, verify no ENOTEMPTY error

🤖 Generated with Claude Code

@Umaaz Umaaz enabled auto-merge April 4, 2026 20:04
…ranchesView

- Enrich BranchDetail with aheadCount (vs origin/main), dirty status, and PR state from gh CLI
- New stale detection: dirty files override (never stale), then check PR merged/closed,
  remote gone, 0 ahead, or last commit >3 days old
- Expandable details panel per branch with file tree (committed vs uncommitted) and diff viewer
- New getBranchFiles and getBranchDiff IPC endpoints for branch-level file/diff queries
- Optimistic UI updates on delete (no full list reload)
- Fix worktree removal for dirs with suid binaries (git worktree remove --force with rm -rf fallback)
- Ignore .konductor/ in Vite watchers and chokidar to prevent inotify exhaustion
- Tooltips on all status badges explaining what each means

Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
@Umaaz Umaaz merged commit 04c643b into main Apr 4, 2026
3 checks passed
@Umaaz Umaaz deleted the cosmic-wren branch April 4, 2026 20:09
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