Repository navigation
feat(#705): fix -q/-Q flag collision, make boxed Ink TUI the default for run - #706
Merged
admarble merged 2 commits intoJun 3, 2026
Conversation
…for run CLI UX fixes for the run command: - Free `-q` from quiet: `--quiet` moves to `-s` (mnemonic: silent). `-q` becomes a hidden alias for `-Q, --quality-loop` (Commander 14 allows one short per Option), ORed into qualityLoop at the top of runCommand. Both `-q` and `-Q` enable the quality loop; neither enables quiet. - Boxed Ink TUI is now the default on a TTY: tuiEnabled = options.tui !== false && isTTY && !quiet. `--no-tui` opts out to the line phase-matrix renderer; non-TTY auto-degrades. `--quiet`/`-s` suppresses the renderer entirely (heartbeat-only). - `--experimental-tui` retained as a hidden no-op alias for backward compat. - ready parity (AC-6): both run and ready mount the identical renderTui provider — confirmed structurally identical, no gap to close. Flag resolvers extracted to run-flags.ts (normalizeQualityLoop, resolveTuiEnabled) as pure functions for unit testing and to keep run.ts under the 200-LOC cap. Reversed the #658 -q-binds-to-quiet test. Docs: README TUI-default framing + opt-out; quiet-mode-heartbeat.md (-q->-s, gating prose), run-command.md flag table, run-renderer.md and experimental-tui-dashboard.md (default/opt-in framing inverted, corrected the now-wrong --quiet+TUI interaction claim). CHANGELOG entry added. Closes #705 Entire-Checkpoint: 04f8bb49d4f7
9 tasks
admarble
deleted the
feature/705-cli-ux-fix-q-q-flag-collision-make-boxed-ink-tui-t
branch
June 3, 2026 05:36
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
-qfrom quiet.--quietmoves to-s(mnemonic: silent).-qis now a hidden alias for-Q, --quality-loop, ORed intoqualityLoopat the top ofrunCommand— both-qand-Qenable the quality loop; neither enables quiet. Ends the footgun whererun … -qsilently enabled quiet mode instead of the quality loop.runon a TTY:tuiEnabled = options.tui !== false && isTTY && !quiet.--no-tuiopts out to the line phase-matrix renderer; non-TTY / piped output auto-degrades;--quiet/-ssuppresses the renderer entirely (heartbeat-only).--experimental-tuikept as a hidden no-op alias for backward compatibility.readyparity (AC-6): bothrunandreadymount the identicalrenderTui(provider)(sameApp, same full box) — confirmed structurally identical, no gap to close.Flag resolution extracted to
src/commands/run-flags.ts(normalizeQualityLoop,resolveTuiEnabled) as pure functions, making the flag behavior directly unit-testable and keepingrun.tsunder its 200-LOC cap (matches the existingrun-progress.tsextraction pattern).Pre-PR AC Verification
-qand-Qboth enable the quality loop; neither enables quietrun-flags.tsnormalizeQualityLoop+ unit tests;bin/cli.tshidden-qalias; CLI parse tests incli.integration.test.ts--quietreachable via-s; suppresses the rendererbin/cli.ts:-s, --quiet;resolveTuiEnabled!quietterm + unit test; help-surface testsequant runshows boxed Ink TUI by default on a TTYresolveTuiEnabled({}, true) === trueunit test;run.tswiring--no-tuiopts out; non-TTY auto-degrades--no-tuiregistered;resolveTuiEnabledunit tests (tui:false, non-TTY)--experimental-tuistill parses (hidden no-op)addOption(new Option("--experimental-tui").hideHelp()); parse + hidden-from-help tests inrun-tui.integration.test.tsreadyrenders the same full boxed TUI asrunrenderTuifromui/tui/index.ts(run.ts:140,ready.ts:182) — structurally identical; confirmed, no code change neededrun-command.md,quiet-mode-heartbeat.md,run-renderer.md,experimental-tui-dashboard.md, CHANGELOGTest plan
npm run build— passesnpm run lint— passes (0 warnings)npx vitest runon all affected files (run-flags, cli.integration, run-tui.integration, run-progress, ready, heartbeat) — 69 passedrun --helpshows-Q,-s, --quiet,--no-tui; hides-qalias +--experimental-tui-q,-Q,-s,--no-tui,--experimental-tuiall parse without "unknown option"Known unrelated failure
src/commands/__tests__/prompt-wait.test.tshas one pre-existing flaky failure (a timer/filesystem race reading the relayinbox.jsonl). It fails identically on the clean base and touches thesequant prompt --waitrelay system — none of which this PR modifies.Closes #705