refactor(installer): replace gum with fzf, backup configs on overwrite#4
Merged
Conversation
Remove gum entirely — one fewer dep, zero TUI-mode lag between prompts. Interactive prompts now use fzf (single-select via _pick, multi-select via _pick_multi with start:select-all pre-selection) and plain read for y/n confirmations. Themed with Catppuccin Mocha fzf colour scheme. Banner and post-install message use printf + raw ANSI escapes (no external binary needed). brew install progress uses \r\033[K inline overwrite rather than gum spin. fzf is bootstrapped via brew if absent (same pattern as gum was). Non-interactive / CI / dry-run paths are unchanged; all 22 tests pass. Refs: cmuxup low-deps-installer
When CMUXUP_OVERWRITE=1 and a config file already exists, copy it to <file>.bak before writing the new content. Prevents silent data loss on re-runs or accidental overwrites. Refs: cmuxup safe-overwrite
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
fzf(single/multi-select) and plainread(confirmations); pureprintf+ ANSI escapes for the banner and post-install message; inline\r\033[Kfor brew progress. One fewer dep, zero TUI alternate-screen lag between prompts._write_filenow copies<file>→<file>.bakbefore writing new content whenCMUXUP_OVERWRITE=1. Re-running the installer is safe.Test plan
bats test/cmuxup.bats test/install.bats→ 23/23 passCMUXUP_OVERWRITE=1→.bakfiles created on second runCMUXUP_NON_INTERACTIVE=1 bash install.sh --dry-run→ exits 0 (no fzf needed)🤖 Generated with Claude Code