Skip to content

Add a specific CI job on which we can gate PRs. #335

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 1 commit into from
Mar 6, 2025
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
21 changes: 21 additions & 0 deletions .github/workflows/ValidatePullRequest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -66,3 +66,24 @@ jobs:
- uses: actions/checkout@v4
- name: Spell Check Repo
uses: crate-ci/[email protected]

# Gate PR merges on this specific "join-job" which requires all other
# jobs to run first. We need this job since we cannot gate on particular jobs
# in the workflow, since they can sometimes be skipped (e.g. if the PR only touches docs).
# This step fixes this issue by always running.
report-ci-status:
needs:
- docs-pr
- rust
- fuzzing
- spelling
if: always()
runs-on: ubuntu-latest
steps:
- name: Previous jobs succeeded
if: ${{ !(contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled')) }}
run: exit 0
- name: Previous jobs failed
if: ${{ contains(needs.*.result, 'failure') || contains(needs.*.result, 'cancelled') }}
run: exit 1

Loading