Skip to content

ci: add README↔action.yaml input/output parity guard#197

Merged
devantler merged 1 commit into
mainfrom
claude/docs-readme-parity-guard
May 31, 2026
Merged

ci: add README↔action.yaml input/output parity guard#197
devantler merged 1 commit into
mainfrom
claude/docs-readme-parity-guard

Conversation

@devantler
Copy link
Copy Markdown
Contributor

🤖 Generated by the Daily AI Assistant

Fixes #185.

What

Adds a lint-readme-parity CI job that fails if any input/output declared in an action's action.yaml is missing from its README's ## Inputs / ## Outputs table. It emits ::error annotations pointing at the offending action.yaml, and is wired into the CI - Required Checks gate (needs + the aggregate-job-checks result list). The check uses yq (preinstalled on the ubuntu-latest runner image) for the action.yaml side and awk/grep for the README side — no new dependencies, runs on every event with contents: read only.

Parity audit (acceptance criterion: one bullet per action)

I read every action.yaml against its README.md. Result: zero parity drift found — every declared input/output is already documented with matching required/default:

  • aggregate-job-checksjob-results, check-name documented; required/default match. ✅
  • approve-prapp-id, app-private-key, pr-number, dry-run all documented. ✅
  • cleanup-ghcr-packagesolder-than, keep-n-tagged, package, dry-run documented. ✅
  • create-issues-from-todosapp-id, app-private-key, project documented. ✅
  • enable-auto-merge-on-prpr-number, merge-method, dry-run documented. ✅
  • login-to-ghcrgithub-token documented. ✅
  • run-dotnet-testsapp-id, app-private-key, github-token, working-directory documented. ✅
  • setup-agent-skills — 5 inputs + output installed-skills documented. ✅
  • setup-go-toolchaingo-version, github-token + output go-version documented. ✅
  • setup-ksail-cli — no inputs/outputs declared; README correctly omits the tables. ✅
  • sync-github-labelsconfig-file, delete-other-labels documented. ✅
  • update-agent-skills — 5 inputs + outputs changed, updated-skills documented. ✅
  • upload-coverage — 5 inputs documented; no outputs ("This action has no outputs."). ✅
  • upsert-issue — 8 inputs + outputs issue-number and issue-url documented (the issue flagged issue-url as "unknown" — it is in fact already documented). ✅

So the READMEs are already in good shape; the durable value of this PR is the guard that keeps them that way and catches the "silent drift" #185 describes (e.g. a future agents:-style input added to action.yaml without a README row).

Validation

  • actionlint .github/workflows/ci.yaml — clean for this change (the two pre-existing code-quality permission-scope warnings at lines 213/629 are unrelated to this job and stem from actionlint's allowlist not yet knowing that scope).
  • Parity logic exercised locally against the live READMEs (passes) and against a synthetic action with an undocumented input + output (fails with ::error annotations + non-zero exit).

Notes / trade-offs

  • Kept the check inline in ci.yaml (self-contained, matching the repo's job style and the zizmor precedent) rather than introducing a new .github/scripts/ convention.
  • Forward-direction only (every action.yaml name must be documented) — it does not flag README rows with no matching action.yaml entry, to avoid false positives on intentionally-documented effective defaults (e.g. cleanup-ghcr-packages package).

Fixes #185.

Adds a `lint-readme-parity` CI job that fails if any input or output
declared in an action's `action.yaml` is missing from its README's
`## Inputs` / `## Outputs` table, with `::error` annotations pointing at
the offending `action.yaml`. Wired into the `CI - Required Checks` gate.

Co-Authored-By: Claude Opus 4.8 (1M context) <noreply@anthropic.com>
Copilot AI review requested due to automatic review settings May 31, 2026 01:22
@github-code-quality
Copy link
Copy Markdown

github-code-quality Bot commented May 31, 2026

Code Coverage Overview

Languages: Go, C#

Go / code-coverage/test

The overall coverage remains at 50%, unchanged from the branch.

C# / code-coverage/dotnet

The overall coverage remains at 100%, unchanged from the branch.


Updated May 31, 2026 01:22 UTC
Code Coverage is in Public Preview. Learn more and provide us with your feedback.

Copy link
Copy Markdown

Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

Adds a lint-readme-parity CI job that fails when an input/output declared in any action.yaml is missing from the matching README's ## Inputs / ## Outputs section, and wires it into the required-checks gate. Uses preinstalled yq + awk/grep, no new dependencies.

Changes:

  • New lint-readme-parity job iterates */action.yaml, extracts input/output names via yq, and verifies each appears (as `name`) inside the README's ## Inputs / ## Outputs section.
  • Adds the new job to the ci-required-checks needs: list and to the aggregate-job-checks result list.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

@devantler devantler marked this pull request as ready for review May 31, 2026 06:36
@devantler devantler merged commit 6d8bcd6 into main May 31, 2026
41 checks passed
@devantler devantler deleted the claude/docs-readme-parity-guard branch May 31, 2026 07:11
@github-project-automation github-project-automation Bot moved this from 🫴 Ready to ✅ Done in 🌊 Project Board May 31, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: ✅ Done

Development

Successfully merging this pull request may close these issues.

docs: audit per-action READMEs for inputs/outputs parity with action.yaml

2 participants