Skip to content

Move the interactive screen to Bubble Tea; add projects, sorting, mouse - #1

Closed
devloop01 wants to merge 21 commits into
mainfrom
bubbletea
Closed

devloop01 wants to merge 21 commits into
mainfrom
bubbletea

Conversation

@devloop01

@devloop01 devloop01 commented Nov 4, 2026 •

Copy link
Copy Markdown
Owner

Moves the interactive screen to Charm's Bubble Tea, Bubbles and Lip Gloss, and builds on that.

Screen

  • Styled list: highlighted cursor row, [ ] / [✓] checkboxes, column names, a spinner while scanning or deleting, and a key bar that shows only keys that do something.
  • Enter opens a confirm dialog. Cancel has focus first, so a held-down enter deletes nothing.
  • t lists folders under their project. A monorepo (Turborepo, Nx, Lerna, pnpm or npm/Yarn workspaces) counts as one project. Other projects are labelled by framework (Next.js, SvelteKit, Astro, ...). ←/→ collapse and open a project, tab jumps to the next one, and c collapses or opens all of them.
  • s sorts by size, name, or last change. The sorted column is marked.
  • ? lists every key. o shows a folder in Finder.
  • Mouse: scroll, click rows, checkboxes, ▾/▸, column names, and dialog buttons. A click hits the folder that was drawn there, even if the list re-sorted since.

Safety

  • Project rows are never folders. They can't reach the delete path, and a test checks that deleting through a Turborepo row leaves turbo.json and package.json in place.
  • Quitting waits for running deletions, including on SIGTERM/SIGHUP, at end of input, and if Bubble Tea's Run ends with an error.
  • sweep waits for the terminal's background-colour reply before quitting, so the reply doesn't land in the shell.

New targets

  • Rust and Maven target folders get the same git check as dist and build: they're deleted only in a repo where git confirms nothing inside is tracked.
  • Python tool caches: .pytest_cache, .mypy_cache and .ruff_cache. __pycache__ and .venv are left out.
  • The project view groups Rust projects (Cargo.toml, with Cargo workspaces as one project) and Python projects (pyproject.toml).

Other

  • The screen's header shows free disk space, refreshed after each delete.
  • Wording cleanup in help, messages, README and DEVELOPMENT.md.
  • Dependabot now also updates Go modules.
  • sweep -n / -y output is unchanged.
  • The release binary grows from about 6.3 MB to 7.8 MB.

Testing

go test -race ./... passes. I checked the screen by hand in a real terminal: dialog, project view, collapse, sort, the key list and mouse clicks.

🤖 Generated with Claude Code

- Bubble Tea owns the terminal: raw input, key parsing, the alternate
  screen, resizes, restoring on exit. The hand-written versions are gone.
- The list and its rules (cursor follows folders, the enter guard,
  selections) are unchanged in screen.
- Paths are cut by display width, so wide characters no longer overflow.
- Closing stdin no longer quits; Ctrl-D and a hangup still do.
@changeset-bot

changeset-bot Bot commented Nov 4, 2026 •

Copy link
Copy Markdown

⚠️ No Changeset found

Latest commit: 22bee71

Merging this PR will not cause a version bump for any packages. If these changes should not result in a new version, you're good to go. If these changes should result in a version bump, you need to add a changeset.

Click here to learn what changesets are, and how to add one.

Click here if you're a maintainer who wants to add a changeset to this PR

@devloop01

devloop01 commented Nov 4, 2026 •

Copy link
Copy Markdown
Owner Author

Continued in #2 after renaming the branch to release-1.0.

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