ReviewOS

also looking at this

zig-utils/zig-test-framework

feat: load strict JSON configuration files

#19
Merged glennmichael123 wants to merge codex/issue-12-config into main
10 files +249 -286
9 days ago

Closes #12.

Loads --config <file> before execution, applies configuration as defaults, and reparses explicit CLI flags so the CLI wins. Configuration is now strict JSON: unknown/duplicate keys, wrong types, unsupported extensions, and invalid reporter/job/port/timeout/debounce values fail clearly. Parsed strings remain owned for the loader lifetime.

The advertised formats are aligned with reality in help and documentation: JSON is supported; TOML and YAML are explicitly not yet supported.

End-to-end build checks invoke the real CLI to prove config-driven discovery, CLI-over-config filter precedence, and invalid-config exit behavior.

This PR is stacked on #18 so its diff stays scoped to issue #12. Merge #18 first, then retarget this PR to main.

Verification:

  • zig fmt --check .
  • zig build
  • zig build test
  • zig build examples
  • zig build -Dtarget=x86_64-linux-gnu

10 changed files on the files tab, with 0 review threads.

Sign in to comment on this pull request.