Give -v to verbose, move --version to -V (closes #64)
check / check (push) Successful in 2m3s

urfave/cli's built-in version flag claimed -v, so "mfer -v --version"
failed to parse, and -v meant version at the root but verbose on
generate, check, freshen and fetch. Verbose is the more common meaning,
so the root now takes -v and -q too, the version flag takes -V, and a
-v or -q before the subcommand name applies to that subcommand.

User-visible changes: -v alone prints help with verbose logging, not
the version; use -V or --version. "mfer version" prints "mfer version
0.1.0 (...)", the same line as --version, instead of the bare
"0.1.0 (...)".

The error-message tests now send their log lines to io.Discard; they
were landing in other tests' output buffers.

Model: opus-4-8 (implementation); opus-5-5 (rework)
This commit is contained in:
2026-10-04 01:10:43 +00:00
parent c31796998f
commit c2e40f3d25
5 changed files with 163 additions and 10 deletions
+2 -2
View File
@@ -417,8 +417,8 @@ proto `go_package` option. Which is canonical?
matching Scanner
- [ ] Add `--deterministic` flag or make it default — omit `createdAt`, sort
files (pending design question answer)
- [ ] Wire `--version` flag properly (currently only a `version` subcommand
exists; top-level `--version` shows urfave/cli generic output)
- [x] Wire `--version` flag properly: `--version` and `-V` print the same line
as the `version` subcommand, and `-v` means verbose
- [ ] Add retry logic to `fetch` — currently no retries on transient HTTP
errors; needs exponential backoff
- [ ] `fetch` command uses bare `http.Get` with no timeout — needs `http.Client`