refactor(cli): make openboot install the canonical entry point#52
Merged
fullstackjam merged 2 commits intomainfrom Apr 22, 2026
Merged
refactor(cli): make openboot install the canonical entry point#52fullstackjam merged 2 commits intomainfrom
fullstackjam merged 2 commits intomainfrom
Conversation
Root command no longer doubles as install — bare `openboot` now shows help instead of running the install wizard. All install flags move to `openboot install`, which is now the single, explicit entry point. - Remove RunE and all install flags from root command - Add missing --post-install flag to installCmd (was root-only before) - Update install.sh to exec `openboot install` instead of bare `openboot` (snapshot mode still execs `openboot snapshot` via passthrough) - Simplify PersistentPreRunE: map lookup → single cmd.Name() == "install" check Breaking: `openboot -p developer` style shortcuts no longer work; use `openboot install -p developer` instead.
|
👋 Thanks for opening this pull request! Before merging:
@fullstackjam will review this soon. Thanks for contributing! 🚀 |
Codecov Report❌ Patch coverage is
📢 Thoughts on this report? Let us know! |
Fixes CI failures from the root-command refactor. The mock server's inline install script and all e2e test exec.Command calls were still using the old root-level flag syntax. - scripts/mock-server.py: generated install script now calls `openboot install -s -u` instead of bare `openboot -s -u` - test/e2e/smoke_test.go: dry-run exec call updated - test/e2e/real_install_test.go: all exec calls updated (L6 tier) - test/e2e/macos_defaults_e2e_test.go: doc comment updated - test/e2e/dotfiles_e2e_test.go: doc comments updated - README.md, .github/pull_request_template.md: examples updated - internal/cli/install.go: remove stale comment about root alias
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.
What changed
openboot installis now the single, explicit entry point for setup. The root command (openbootwith no subcommand) previously doubled as an alias for install — it now shows help instead.Why
Having 12 install-specific flags on the root command made
openboot -hnoisy and the command structure ambiguous. Users couldn't tell when to useopenbootvsopenboot install. Making install the canonical entry point gives each command a clear job.Changes
internal/cli/root.go— removedRunEand all install flags; root is now help-only. SimplifiedPersistentPreRunEmap lookup to a singlecmd.Name() == "install"check.internal/cli/install.go— added missing--post-installflag (it existed only on root before, soopenboot install --post-installwas silently broken). Updated Long description and examples to reflect canonical status.scripts/install.sh—curl | bashnow execsopenboot installinstead of bareopenboot.curl | bash snapshotstill execsopenboot snapshotvia passthrough.Breaking change
Root-level install shortcuts no longer work:
Reviewer notes
install.shwas the only non-obvious affected caller — all other callers in tests already usedinstallCmddirectly.--post-installbug fix is a side effect of this refactor; it was masked because the flag existed on root but not oninstallCmd.