Skip to content

Commit bc00cd0

Browse files
nyurikemilio
authored andcommitted
remove check-cfg, separate clippy from nightly
1 parent 5fcf09f commit bc00cd0

File tree

1 file changed

+14
-19
lines changed

1 file changed

+14
-19
lines changed

.github/workflows/bindgen.yml

+14-19
Original file line numberDiff line numberDiff line change
@@ -12,14 +12,24 @@ on:
1212
- main
1313

1414
jobs:
15-
rustfmt-clippy:
15+
rustfmt:
1616
runs-on: ubuntu-latest
17-
1817
steps:
1918
- uses: actions/checkout@v4
2019

20+
- name: Install nightly
21+
uses: dtolnay/rust-toolchain@master
22+
with:
23+
toolchain: nightly
24+
components: rustfmt
25+
2126
- name: Run rustfmt
22-
run: cargo fmt -- --check
27+
run: cargo +nightly fmt -- --check
28+
29+
clippy:
30+
runs-on: ubuntu-latest
31+
steps:
32+
- uses: actions/checkout@v4
2333

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

169-
check-cfg:
170-
runs-on: ubuntu-latest
171-
env:
172-
RUSTFLAGS: -D warnings
173-
steps:
174-
- uses: actions/checkout@v4
175-
176-
- name: Install nightly
177-
uses: dtolnay/rust-toolchain@master
178-
with:
179-
toolchain: nightly
180-
181-
- name: Check cfg
182-
run: cargo check -Z unstable-options -Z check-cfg
183-
184179
test-book:
185180
runs-on: ubuntu-latest
186181
steps:
@@ -213,7 +208,7 @@ jobs:
213208
# separately.
214209
success:
215210
runs-on: ubuntu-latest
216-
needs: [rustfmt-clippy, msrv, minimal, docs, quickchecking, test-expectations, test, check-cfg, test-book, test-no-headers]
211+
needs: [rustfmt, clippy, msrv, minimal, docs, quickchecking, test-expectations, test, test-book, test-no-headers]
217212
# GitHub branch protection is exceedingly silly and treats "jobs skipped
218213
# because a dependency failed" as success. So we have to do some
219214
# contortions to ensure the job fails if any of its dependencies fails.

0 commit comments

Comments
 (0)