Repository navigation
Replace the flag CLI with Cobra verbs - #22
Draft
kylecrawshaw wants to merge 1 commit into
Draft
kylecrawshaw wants to merge 1 commit into
kylecrawshaw wants to merge 1 commit into
Conversation
…e gate. A missing or mistyped command is help or an error instead of binding the listen port; healthcheck, validate, and version are first-class, and --verbose is serve-only. Co-authored-by: Cursor <cursoragent@cursor.com>
kylecrawshaw
force-pushed
the
feat/cobra-cli
branch
from
September 1, 2026 15:55
99a28b7 to
50a53b4
Compare
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
serveuseslogging.New(json/logfmt/text and request-scoped labels) instead of a hard-coded text handler.flagwith Cobra so the binary is a verb tree (serve,healthcheck,validate,version) instead of a default-serve process with mode bits.--configis only on commands that load toml;--verboseis serve-only and still forces debug over[log].level.CMD/HEALTHCHECK, docs, and examples for the breaking invocations.Test plan
go test ./cmd/anteroom/— CLI contract tests (unknown command,--healthcheckrejected on root,-vrejected on validate)anteroomwith no args prints help and does not bindanteroom stattexits 1 withunknown commandanteroom serve --config anteroom.tomlstarts the gate and honors[log]/ANTEROOM_LOG_*from feat(log): json/logfmt/text output with request-scoped labels #21serve --verboseforces debug hit lines regardless oflog.levelanteroom healthcheck --config …/validate/versionbehave as documentedHEALTHCHECKusesanteroom healthcheck --config …; compose/k8s that relied on imageCMDpick upserve