feat(cli): visual and UX polish across all commands - #15
Conversation
|
Important Review skippedWe couldn't safely recover the incremental review. No full review was started, and the last reviewed checkpoint was preserved. Retry later, or explicitly request a full review by commenting You can disable this status message by setting the Use the checkbox below for a quick retry:
Note Reviews pausedIt looks like this branch is under active development. To avoid overwhelming you with review comments due to an influx of new commits, CodeRabbit has automatically paused this review. You can configure this behavior by changing the Use the following commands to manage reviews:
Use the checkboxes below for quick actions:
📝 WalkthroughWalkthroughThe CLI now uses grouped commands, terminal-aware output, structured errors, signal-specific exit codes, stable authentication status data, improved initialisation progress, Docker Compose container tables, and tracked ChangesCLI behaviour and interface refresh
Priority: ⬇️ Low Merge Risk: 🟠 High · up to This should not merge yet: initialization weakens local file protections, worktree removal can fail to protect user-managed files, and supported Windows test runs can fail. 🚥 Pre-merge checks | ✅ 4 | ❌ 1❌ Failed checks (1 warning)
✅ Passed checks (4 passed)
Full details: Docstring CoverageExplanation Docstring coverage is 34.50% which is insufficient. The required threshold is 80.00%. Docstring coverage is scoped to functions touched by this diff. Analyzed 229 functions across 50 files. (1 skipped: 1 unsupported.) Comment |
This comment has been minimized.
This comment has been minimized.
226711f to
4e8bcee
Compare
4e8bcee to
ecf6e93
Compare
ecf6e93 to
ae3aba2
Compare
Codecov Report❌ Patch coverage is Additional details and impacted files@@ Coverage Diff @@
## main #15 +/- ##
==========================================
+ Coverage 40.60% 43.44% +2.84%
==========================================
Files 62 63 +1
Lines 6224 6565 +341
==========================================
+ Hits 2527 2852 +325
- Misses 3697 3713 +16 🚀 New features to boost your workflow:
|
ae3aba2 to
02020e1
Compare
02020e1 to
9f606c6
Compare
e334c68 to
3c7004b
Compare
3c7004b to
13b6dca
Compare
13b6dca to
81a01c8
Compare
87c20cf to
7cbb155
Compare
Summary
✓summary box per outcome,→hints, consistent empty states, dates, plurals, punctuation), grouped and styled--help, a native styledpstable, and TTY-gated spinners/progress so piped output is ANSI-free andNO_COLORis respected.✗renderer with remediation hints, internal classification sentinels never leak into messages, prompt/menu cancellation exits 0 silently, and passthrough commands (php,composer,compose,exec, direct XF commands) propagate the child's exit code with no redundantError:trailer.[8/7]drift),xf debugdropping all arguments after the first, an unchecked checksum slice panic indownload, review-screen validation warnings being wiped before they could be read, and the keychain missing-entry sentinel.Testing
go build ./... && go vet ./... && gofmt -l . && go test ./...— all green.| cat -v,NO_COLOR=1) and on a TTY.doctor,auth status(all token states),cache list/purge/path,worktree list/prune, lifecycle (up/ps/down), error and exit-code paths.self-updateinstall and a fullupgraderun (no target install available); verified by reading and unit tests.Visual evidence
Errors, before → after:
auth statuswith an expired token, before → after:--helpis now grouped with styled headings instead of one flat alphabetical list of 22 commands, before → after:Notes
mainonce feat(worktree): create and manage development worktrees #14 merges.cache purgewithout flags is now a usage error (exit 1);doctorfailure exits 1 without a duplicate error line;xf -v <xenforo-command>is now an unknown-command usage error instead of root help with exit 0.Checklist
Note
Polish visual output and UX across all CLI commands
cmd/xf/root.go.SuccessBox, empty states usePrintEmpty, hints usePrintHint, and dates useFormatDate/FormatDateTime.uiutilities ininternal/ui/ui.go:Plural,FormatDate,FormatDateTime,IsTerminal,ShortHome,PrintHint,PrintEmpty,ClearScreen, andProgressBar.Abandon; removesBox,Subheader,Italic,Underline, andStatusTableStyle.passthroughErrorandexitCodeErrorso CLI exits mirror subprocess status; SIGTERM is now handled alongside SIGINT with signal-derived exit codes (128+signum).runner.PSInfotointernal/dockercompose/runner.gofor structured container status, and rewritesxf psto render a formatted table with colored state columns.xf doctornow exits non-zero when checks fail and prints an aggregated summary;xf cache purgenow errors when called without--allor--license.xf doctornow exits 1 on failures, child-command wrappers now forward subprocess exit codes instead of always exiting 1, andErrCancellednow exits 0.Macroscope summarized 3c7004b.
Summary by CodeRabbit
New Features
-n, --no-interactionand-c, --config <path>global options.Bug Fixes