Skip to content

ci: add universal PR Gate required status check - #90

Merged
joshua-temple merged 1 commit into
mainfrom
ci/pr-gate
Jun 10, 2026
Merged

joshua-temple merged 1 commit into
mainfrom
ci/pr-gate

Conversation

@joshua-temple

Copy link
Copy Markdown
Collaborator

Problem

The PR Validation workflow had a workflow-level paths-ignore for docs and config files. On a docs-only PR the entire workflow (Unit Tests + Lint) never ran, so those checks never reported. Requiring them in branch protection would permanently block any docs-only PR, since a required check that never reports can't be satisfied.

Change

Restructure so the workflow triggers on every PR to main and add a single aggregate gate:

  • Removed the workflow-level paths-ignore. The workflow now runs on all PRs to main.
  • Added a changes job using SHA-pinned dorny/paths-filter to detect whether non-docs (code) files changed.
  • Gated the expensive Unit Tests and Lint jobs on needs.changes.outputs.code == 'true', so they skip on docs-only PRs but keep their existing behavior otherwise.
  • Added a final PR Gate job (needs: [unit-tests, lint], if: always()) that passes when each gated job succeeds or is skipped, and fails when any failed or was cancelled.

Resolution

  • Docs-only PR: expensive jobs skip, PR Gate reports green.
  • Code PR that passes: jobs run and succeed, PR Gate reports green.
  • Code PR with a failing check: PR Gate reports red.

Branch protection

Require the single check named PR Gate. It reports on every PR, so docs-only PRs are no longer locked out, while real failures still block.

Signed-off-by: Joshua Temple <joshua.temple@stablekernel.com>
@joshua-temple
joshua-temple merged commit 6c97606 into main Jun 10, 2026
6 checks passed
@joshua-temple
joshua-temple deleted the ci/pr-gate branch June 10, 2026 11:03
@joshua-temple joshua-temple added the ci CI/CD pipeline and workflow changes label Jun 27, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci CI/CD pipeline and workflow changes

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant