Skip to content

feat(cli): modernize presentation and CI reporting - #165

Open
Teakowa wants to merge 3 commits into
mainfrom
codex/issue-164-cli-presentation
Open

feat(cli): modernize presentation and CI reporting#165
Teakowa wants to merge 3 commits into
mainfrom
codex/issue-164-cli-presentation

Conversation

@Teakowa

@Teakowa Teakowa commented Aug 18, 2026

Copy link
Copy Markdown
Contributor

Summary

  • replace the hand-written wright argv/help layer with one clap command model;
  • generate Bash, Zsh, Fish, and PowerShell completion from that model;
  • add deterministic text/JSON, terminal/plain/GitHub Actions, and color policies;
  • keep driver envelopes, exit codes, JSON stdout, and compile/convert source artifacts unchanged;
  • add escaped structured GitHub annotations, grouping, and PASS/WARN/ERROR summary output;
  • document the presentation contract and add black-box regression coverage.

Contract boundaries

wright-driver remains the owner of semantic execution, typed wright-result/v1 envelopes, diagnostics, exit codes, and artifact file I/O. The CLI presentation layer consumes those structured results.

JSON mode emits only one envelope to stdout. Compile/convert text mode emits only the source artifact, byte-for-byte; compile -o emits no artifact to stdout. GitHub workflow commands are emitted on the diagnostic stream, while artifact stdout remains pure; GITHUB_STEP_SUMMARY is used when available.

Verification

  • cargo fmt --all -- --check
  • git diff --check
  • cargo check --workspace --all-targets
  • cargo clippy --workspace --all-targets -- -D warnings
  • cargo test --locked -p wright-cli --all-targets --all-features — 63 passed
  • cargo test --workspace — passed
  • independent QA verified top-level help compatibility, all four completion shells, renderer/override coverage, and plain/GitHub artifact byte equality.

Fixes #164

@Teakowa

Teakowa commented Aug 18, 2026

Copy link
Copy Markdown
Contributor Author

Follow-up commit 7c25fe3 fixes the first CI failure. Root cause: the default black-box run() helper inherited GitHub runner CI/GITHUB_ACTIONS, so existing text-contract tests unintentionally selected the GitHub Actions renderer. The helper now clears presentation environment variables; explicit environment-matrix tests still inject them. Reproduced with CI=true GITHUB_ACTIONS=true cargo test --locked -p wright-cli --all-targets --all-features: 63 passed. Checks are being rerun.

@Teakowa

Teakowa commented Aug 18, 2026

Copy link
Copy Markdown
Contributor Author

Final CI evidence for head 7c25fe38dc2aa884dac02cc1da6b331a3d1062dd: all 13 checks pass, including Rust quality (stable and 1.85.0), macOS/Ubuntu/Windows distribution validation, LPP integration, native/reference differentials, OverPy compatibility, OSTW baselines/differential, and v1 release gates. The Draft PR is ready for review/merge.

@Teakowa

Teakowa commented Aug 18, 2026

Copy link
Copy Markdown
Contributor Author

PM audit blockers resolved in head 1641f9549c20e56797429c38cd36737d43dc7d56: (1) GHA summary status now aggregates structured diagnostics and findings by highest severity — error=ERROR, warning=WARN, info/notice-only=PASS — with regression coverage for all three cases and both sources; (2) added the Wright CLI GitHub Actions smoke job. Its real hosted-runner execution passed, proving auto renderer detection from actual GITHUB_ACTIONS, clean artifact stdout, workflow grouping, and GITHUB_STEP_SUMMARY PASS output. All 13 PR checks pass. PR remains Draft for PM/QA merge review.

@Teakowa
Teakowa marked this pull request as ready for review August 18, 2026 06:18
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

Development

Successfully merging this pull request may close these issues.

Modernize CLI UX and add first-class CI/GitHub Actions reporting

1 participant