Skip to content

CLI quiet-mode and directory-summary consistency gaps: build --quiet prints summary while lint/check/fmt suppress; lint has no directory summary #216

Description

@dean0x

Background

Two pre-existing consistency gaps in CLI quiet/summary behavior were noted during the PR #196 review. Neither was introduced by PR #196, but both were identified in files within the diff and are now tracked here.

Ledger IDs: #46 (consistency-cli/build.rs:1491-quiet_summary_unguarded), #48 (consistency-cli/lint.rs:849-no_directory_summary)
Files: mds-cli/src/build.rs:1491, mds-cli/src/lint.rs:849-937
Originating reviewer: Consistency

Issue A — build --quiet prints a summary line (#46)

mds-cli/src/build.rs:1491 emits a compilation summary (N compiled, M failed) unconditionally — it does not check the --quiet flag. mds lint --quiet, mds fmt --quiet, and mds check --quiet all suppress their equivalent summary lines. A developer using build in a quiet CI pipeline still gets summary noise.

This is a deliberate divergence currently, not an oversight — but no code comment documents it, and it was not called out in the CHANGELOG as intentional behavior.

Issue B — lint has no directory summary (#48)

mds lint dir/ produces per-file diagnostics but no trailing summary line (e.g., "N files checked, M with errors, K warnings"). Every other subcommand in directory mode (build, fmt, check) prints a summary. The omission means a quiet mds lint dir/ exit 0 gives no feedback at all about how many files were processed.

Adding a summary is a new output contract — needs a decision about format and whether it is quiet-suppressed — so it is a feature addition, not a fix.

Why deferred from PR #196

Both are pre-existing gaps not introduced by PR #196. #46 is a behavior change to --quiet semantics for build; #48 is a new output line. The right fix is to settle them together in a coordinated "quiet and summary audit" PR after the v0.4.0 release.

Proposed approach

  1. Decide whether build --quiet should suppress its summary (likely yes — align with siblings).
  2. Design the lint directory summary format: "N files checked: M error, K warning" + exit code spec.
  3. Update README.md and --help text for both subcommands together.
  4. File CHANGELOG entry under Changed (behavior change for build --quiet).

Acceptance Criteria

  • mds build --quiet dir/ produces no output on success (currently: prints summary line)
  • mds lint dir/ prints a directory summary on completion (currently: none)
  • mds lint dir/ --quiet suppresses the summary line (consistent with build/check/fmt)
  • --help text updated to document --quiet behavior consistently
  • README.md updated to reflect the final quiet behavior for all subcommands

Deferred from: PR #196
Bundle: Pair with #42 (quiet-flag help-text family fix) which addresses the text inconsistencies.

Activity

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    architectureArchitectural refactoringcliCLI commands and optionstech-debtTechnical debt

    Projects

    No projects

      Milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions