feat: add --verbose flag to mex check#23
Conversation
theDakshJaitly
left a comment
There was a problem hiding this comment.
Looks good — clean, well-scoped feature. Approving, but two things to address before merge:
-
--verbose --jsoninconsistency: PR description says verbose is ignored with--json, butverboseLogis still populated and included in the JSON output. Either gate it off when JSON mode is active, or update the description to say it's intentionally included. -
No tests:
buildVerboseLogis a pure function — easy to unit test. Would also be good to verifyrunDriftCheckwith{ verbose: true }populatesverboseLogon the report.
Minor nit: per-file edges:/staleness: entries in checkerIssueCounts could get noisy on large scaffolds (2 lines per file vs 1 per aggregate checker). Worth considering whether to aggregate those too.
- reportJSON now strips verboseLog unless --verbose is also passed - Export buildVerboseLog for testing - Add test/verbose.test.ts with 4 tests: - buildVerboseLog claim breakdown and file count - buildVerboseLog empty inputs - JSON output excludes verboseLog without --verbose - JSON output includes verboseLog with --verbose
|
Addressed both items in c81f5c5:
89/89 tests passing. |
|
Both items addressed in c81f5c5:
On the nit about per-file checker counts getting noisy: agreed, but I'd leave that for a follow-up since it's a display preference rather than a correctness issue. |
theDakshJaitly
left a comment
There was a problem hiding this comment.
Looks great, both items addressed cleanly. Approving and merging.
Also — thanks for the contribution, really appreciate you taking the time on this. Been following your 30 Days Skill repo too, the work you're doing there is incredible. Cheers Matt 🤝
|
Omg thanks for using last30days!! You're first person to notice here. :) |
Summary
Adds
--verbosetomex check. When passed, it prints diagnostic output before the normal report: scaffold files scanned, claims extracted (broken down by kind), and per-checker summaries.Changes
src/cli.ts: Added--verboseoption, passed through torunDriftCheck, callsreportVerbosebeforereportConsolesrc/drift/index.ts:runDriftCheckaccepts{ verbose?: boolean }options, populatesverboseLogon the report with file counts, claim breakdowns, and checker summariessrc/types.ts: AddedverboseLog?: string[]toDriftReportsrc/reporter.ts: AddedreportVerbosefunction that prints dim-styled diagnostic linesBehavior
mex check(default): unchangedmex check --verbose: prints diagnostic info, then normal reportmex check --quiet: verbose ignoredmex check --json: verbose ignored (verboseLog field is included in JSON output)Fixes #5
This contribution was developed with AI assistance (Codex).