feat: add interactive Bubble Tea dashboard

Add repository selection, blocked-worktree inspection, explicit sync confirmation, responsive navigation, and retained per-repository hub output while preserving the CLI and JSON workflows.
This commit is contained in:
2026-09-06 18:34:05 +01:00
parent 9e7c079f1a
commit 761424b2d5
6 changed files with 569 additions and 6 deletions
+13 -1
View File
@@ -2,7 +2,7 @@
`stack-sync` safely runs [`hub sync`](https://hub.github.com/hub-sync.1.html) across every Git repository in a workspace. It is designed for directory trees such as JezzWTF where the root may not be a repository and a parent repository may contain deliberately untracked, nested repositories.
The interface is deliberately a CLI rather than a full-screen TUI: every run produces a reviewable plan, it works over SSH and in automation, and its JSON output can drive a future TUI or GUI without putting safety logic in the presentation layer.
It provides both a full-screen [Bubble Tea](https://github.com/charmbracelet/bubbletea) control deck for interactive work and a conventional CLI/JSON interface for SSH sessions and automation. Both interfaces use the same discovery and safety engine.
## Safety model
@@ -32,6 +32,18 @@ install -Dm755 stack-sync ~/.local/bin/stack-sync
## Usage
### Interactive TUI
Launch the control deck for the workspace:
```bash
stack-sync tui --root ~/Coding/jwtf
```
Every eligible repository starts selected. Move with the arrow keys or `j`/`k`, toggle the focused repository with Space, select all with `a`, clear the selection with `n`, and refresh with `r`. Press `s` or Enter to review the destructive-branch warning, then `y` to begin. Blocked repositories cannot be selected and show their first dirty paths in the detail panel. After a run, focusing a repository shows its latest `hub` output.
### CLI and automation
Scan the current workspace. This is read-only and is the default command:
```bash