Skip to content

Commit

Permalink
Merge pull request #60 from cuviper/ci-merge
Browse files Browse the repository at this point in the history
Try to make the CI status more robust
  • Loading branch information
cuviper committed Feb 1, 2024
2 parents 9b4acd7 + f43ba21 commit d946e96
Show file tree
Hide file tree
Showing 2 changed files with 19 additions and 13 deletions.
17 changes: 10 additions & 7 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -37,19 +37,22 @@ jobs:
name: Format
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v5
- uses: actions/checkout@v4
- uses: dtolnay/rust-toolchain@1.62.0
with:
components: rustfmt
- run: cargo fmt --all --check

ci-status:
ci-success:
name: Complete
runs-on: ubuntu-latest
needs: [test, no_std, fmt]
steps:
- run: exit 0
ci-failed:
name: Complete
runs-on: ubuntu-latest
needs: [test, no_std, fmt]
if: always()
if: failure()
steps:
- if: ${{ success() }}
run: exit 0
- if: ${{ !success() }}
run: exit 1
- run: exit 1
15 changes: 9 additions & 6 deletions .github/workflows/pr.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -28,13 +28,16 @@ jobs:
components: rustfmt
- run: cargo fmt --all --check

ci-status:
ci-success:
name: Complete
runs-on: ubuntu-latest
needs: [test, fmt]
if: always()
steps:
- if: ${{ success() }}
run: exit 0
- if: ${{ !success() }}
run: exit 1
- run: exit 0
ci-failed:
name: Complete
runs-on: ubuntu-latest
needs: [test, fmt]
if: failure()
steps:
- run: exit 1

0 comments on commit d946e96

Please sign in to comment.