Skip to content

Commit

Permalink
remove check-cfg, separate clippy from nightly
Browse files Browse the repository at this point in the history
  • Loading branch information
nyurik committed Feb 3, 2025
1 parent 7ea2e7c commit eb0bf63
Showing 1 changed file with 14 additions and 19 deletions.
33 changes: 14 additions & 19 deletions .github/workflows/bindgen.yml
Original file line number Diff line number Diff line change
Expand Up @@ -12,14 +12,24 @@ on:
- main

jobs:
rustfmt-clippy:
rustfmt:
runs-on: ubuntu-latest

steps:
- uses: actions/checkout@v4

- name: Install nightly
uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly
components: rustfmt

- name: Run rustfmt
run: cargo fmt -- --check
run: cargo +nightly fmt -- --check

clippy:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4

- name: Run clippy
run: cargo clippy --all-targets --workspace --exclude bindgen-integration --exclude tests_expectations -- -D warnings
Expand Down Expand Up @@ -166,21 +176,6 @@ jobs:
BINDGEN_RUST_FOR_LINUX_TEST: ${{matrix.os == 'ubuntu-latest' && matrix.llvm_version == '16.0' && matrix.feature_extra_asserts == 0 && 1 || 0}}
run: ./ci/test.sh

check-cfg:
runs-on: ubuntu-latest
env:
RUSTFLAGS: -D warnings
steps:
- uses: actions/checkout@v4

- name: Install nightly
uses: dtolnay/rust-toolchain@master
with:
toolchain: nightly

- name: Check cfg
run: cargo check -Z unstable-options -Z check-cfg

test-book:
runs-on: ubuntu-latest
steps:
Expand Down Expand Up @@ -213,7 +208,7 @@ jobs:
# separately.
success:
runs-on: ubuntu-latest
needs: [rustfmt-clippy, msrv, minimal, docs, quickchecking, test-expectations, test, check-cfg, test-book, test-no-headers]
needs: [rustfmt, clippy, msrv, minimal, docs, quickchecking, test-expectations, test, test-book, test-no-headers]
# GitHub branch protection is exceedingly silly and treats "jobs skipped
# because a dependency failed" as success. So we have to do some
# contortions to ensure the job fails if any of its dependencies fails.
Expand Down

0 comments on commit eb0bf63

Please sign in to comment.