diff --git a/.github/workflows/rust.yml b/.github/workflows/rust.yml index 82f80460..96e70464 100644 --- a/.github/workflows/rust.yml +++ b/.github/workflows/rust.yml @@ -12,27 +12,6 @@ env: CARGO_REGISTRIES_CRATES_IO_PROTOCOL: sparse jobs: - rustfmt_and_clippy: - name: Rustfmt and Clippy - runs-on: ubuntu-latest - - steps: - - uses: actions/checkout@v4 - - - name: Install Rust Nightly with rustfmt and clippy - uses: dtolnay/rust-toolchain@stable - with: - toolchain: nightly - components: rustfmt, clippy - - - uses: Swatinem/rust-cache@v2.7.3 - - - name: "Check formatting" - run: cargo +nightly fmt --check --all - - - name: Run Clippy - run: cargo clippy --all-targets --all-features - build_and_test: name: "Build and Test" runs-on: ubuntu-latest @@ -47,9 +26,6 @@ jobs: - uses: Swatinem/rust-cache@v2.7.3 - - name: Cargo update - run: cargo update - - name: "Build" run: cargo build @@ -63,6 +39,27 @@ jobs: # RUSTDOCFLAGS: -D warnings run: cargo doc --no-deps --workspace --lib --document-private-items --examples + rustfmt_and_clippy: + name: Rustfmt and Clippy + runs-on: ubuntu-latest + + steps: + - uses: actions/checkout@v4 + + - name: Install Rust Nightly with rustfmt and clippy + uses: dtolnay/rust-toolchain@stable + with: + toolchain: nightly + components: rustfmt, clippy + + - uses: Swatinem/rust-cache@v2.7.3 + + - name: "Check formatting" + run: cargo +nightly fmt --check --all + + - name: Run Clippy + run: cargo clippy --all-targets --all-features + miri: if: ( ! github.event.pull_request.draft ) name: "Test with Miri" @@ -71,16 +68,13 @@ jobs: steps: - uses: actions/checkout@v4 - - name: Stable + - name: Install Rust nightly with Miri uses: dtolnay/rust-toolchain@stable with: toolchain: nightly components: miri - uses: Swatinem/rust-cache@v2.7.3 - - - name: Cargo update - run: cargo update - name: Test with Miri on x86_64 run: cargo miri test -p clmul -p matrix-transpose --target x86_64-unknown-linux-gnu