diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 66c1a690..d1e6b0cf 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -24,6 +24,7 @@ jobs: DO_BENCH: true AS_DEPENDENCY: true DO_NO_STD: true + DO_DOCS: true - rust: 1.29.0 env: AS_DEPENDENCY: true @@ -82,20 +83,6 @@ jobs: - name: run cross test run: cross test --target s390x-unknown-linux-gnu - Docs: - name: Docs - runs-on: ubuntu-latest - steps: - - name: Checkout Crate - uses: actions/checkout@v2 - - name: Checkout Toolchain - uses: actions-rs/toolchain@v1 - with: - profile: minimal - toolchain: stable - override: true - - name: Create Doc - run: cargo doc Embedded: runs-on: ubuntu-latest steps: diff --git a/contrib/test.sh b/contrib/test.sh index 922e3ea7..41503bc9 100755 --- a/contrib/test.sh +++ b/contrib/test.sh @@ -67,6 +67,11 @@ do cargo test --verbose --features="$feature" done +# Build the docs if told to (this only works with the nightly toolchain) +if [ "$DO_DOCS" = true ]; then + RUSTDOCFLAGS="--cfg docsrs" cargo doc --all --features="$FEATURES" +fi + # Fuzz if told to if [ "$DO_FUZZ" = true ] then