Skip to content
Merged
Show file tree
Hide file tree
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
19 changes: 0 additions & 19 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -149,22 +149,3 @@ jobs:
with:
token: ${{ secrets.QLTY_COVERAGE_TOKEN }}
files: lcov.info

# Single required status check for branch protection.
# Passes when all jobs pass OR when jobs are skipped (no Rust changes).
ci-pass:
name: CI
runs-on: ubuntu-latest
if: always()
needs: [quality, test, test-cross-platform, coverage]
steps:
- name: Check results
run: |
results=("${{ needs.quality.result }}" "${{ needs.test.result }}" "${{ needs.test-cross-platform.result }}" "${{ needs.coverage.result }}")
for result in "${results[@]}"; do
if [[ "$result" != "success" && "$result" != "skipped" ]]; then
echo "Job failed with result: $result"
exit 1
fi
done
echo "All jobs passed or were skipped"
32 changes: 32 additions & 0 deletions .mergify.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
merge_protections:
- name: CI must pass
description: >-
All CI checks must pass or be legitimately skipped (path filtering).
Matrix job names differ between running and skipped states, so the
test-cross-platform rule uses an and/or pattern to handle both.
if:
- base = main
success_conditions:
- or:
- check-success = quality
- check-skipped = quality
- or:
- check-success = test
- check-skipped = test
- or:
- and:
- "check-success = test-cross-platform (ubuntu-latest, Linux)"
- "check-success = test-cross-platform (ubuntu-22.04, Linux)"
- "check-success = test-cross-platform (macos-latest, macOS)"
- "check-success = test-cross-platform (windows-latest, Windows)"
- check-skipped = test-cross-platform
- or:
- check-success = coverage
- check-skipped = coverage

- name: Do not merge outdated PRs
description: Make sure PRs are within 10 commits of the base branch before merging
if:
- base = main
success_conditions:
- "#commits-behind <= 10"
Loading