Skip to content

Commit aebcbc4

Browse files
committed
Split checking of docs in CI
And use stable Rust again for the Check jobs.
1 parent b632eb4 commit aebcbc4

File tree

1 file changed

+17
-3
lines changed

1 file changed

+17
-3
lines changed

.github/workflows/main.yml

Lines changed: 17 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -59,14 +59,12 @@ jobs:
5959
target: ["aarch64-apple-ios", "aarch64-linux-android", "x86_64-apple-darwin", "x86_64-fuchsia", "x86_64-pc-windows-msvc", "x86_64-pc-solaris", "x86_64-unknown-freebsd", "x86_64-unknown-illumos", "x86_64-unknown-linux-gnu", "x86_64-unknown-netbsd", "x86_64-unknown-redox"]
6060
steps:
6161
- uses: actions/checkout@v3
62-
- uses: dtolnay/rust-toolchain@nightly # NOTE: need nightly for `doc_cfg` feature.
62+
- uses: dtolnay/rust-toolchain@stable
6363
with:
6464
targets: ${{ matrix.target }}
6565
- uses: taiki-e/install-action@cargo-hack
6666
- name: Run check
6767
run: cargo hack check --feature-powerset --all-targets --examples --bins --tests --target ${{ matrix.target }}
68-
- name: Check docs for docs.rs
69-
run: RUSTDOCFLAGS="-D warnings --cfg docsrs" cargo doc --no-deps --all-features --target ${{ matrix.target }}
7068
Clippy:
7169
name: Clippy
7270
runs-on: ubuntu-latest
@@ -75,3 +73,19 @@ jobs:
7573
- uses: dtolnay/rust-toolchain@stable
7674
- name: Run Clippy
7775
run: cargo clippy --all-targets --all-features -- -D warnings
76+
Docs:
77+
name: Docs
78+
runs-on: ubuntu-latest
79+
strategy:
80+
fail-fast: false
81+
matrix:
82+
# NOTE: missing "x86_64-fuchsia", nightly unavailable at the time of
83+
# writing.
84+
target: ["aarch64-apple-ios", "aarch64-linux-android", "x86_64-apple-darwin", "x86_64-pc-windows-msvc", "x86_64-pc-solaris", "x86_64-unknown-freebsd", "x86_64-unknown-illumos", "x86_64-unknown-linux-gnu", "x86_64-unknown-netbsd", "x86_64-unknown-redox"]
85+
steps:
86+
- uses: actions/checkout@v3
87+
- uses: dtolnay/rust-toolchain@nightly # NOTE: need nightly for `doc_cfg` feature.
88+
with:
89+
targets: ${{ matrix.target }}
90+
- name: Check docs for docs.rs
91+
run: RUSTDOCFLAGS="-D warnings --cfg docsrs" cargo doc --no-deps --all-features --target ${{ matrix.target }}

0 commit comments

Comments
 (0)