use sha1_checked for all Sha1 hashing, except for MDC #639
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: CI | |
on: | |
pull_request: | |
push: | |
branches: | |
- master | |
concurrency: | |
group: ${{ github.workflow }}-${{ github.ref }} | |
cancel-in-progress: true | |
env: | |
RUST_BACKTRACE: 1 | |
RUSTFLAGS: -Dwarnings | |
RUST_NIGHTLY: nightly-2024-02-07 | |
jobs: | |
build_and_test_nix: | |
name: Build and test (Nix) | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [ubuntu-latest, macOS-latest] | |
rust: | |
- nightly-2024-02-07 | |
- beta | |
- stable | |
steps: | |
- name: Checkout | |
uses: actions/checkout@master | |
with: | |
submodules: recursive | |
- name: Install ${{ matrix.rust }} | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: ${{ matrix.rust }} | |
override: true | |
- name: check | |
uses: actions-rs/cargo@v1 | |
with: | |
command: check | |
args: --all --bins --tests | |
- name: check nightly | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: check | |
args: --features nightly --all --bins --examples --tests | |
- name: check wasm | |
uses: actions-rs/cargo@v1 | |
with: | |
command: check | |
target: wasm32-unknown-unknown | |
override: true | |
args: --features wasm --all --bins | |
- name: check bench | |
uses: actions-rs/cargo@v1 | |
with: | |
command: check | |
args: --benches | |
- name: check asm | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: check | |
args: --features asm | |
- name: tests | |
uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
args: --all | |
- name: nightly | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: test | |
args: --all --features nightly | |
- name: asm | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: test | |
args: --all --features asm | |
- name: tests ignored | |
uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
args: --all --release -- --ignored | |
- name: nightly ignored | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: test | |
args: --all --features nightly --release -- --ignored | |
- name: asm ignored | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: test | |
args: --all --features asm --release -- --ignored | |
build_and_test_windows: | |
name: Build and test (Windows) | |
runs-on: ${{ matrix.os }} | |
strategy: | |
matrix: | |
os: [windows-latest] | |
rust: | |
- nightly-2024-02-07 | |
- beta | |
- stable | |
target: | |
- x86_64-pc-windows-gnu | |
# FIXME | |
# - x86_64-pc-windows-msvc | |
steps: | |
- name: Checkout | |
uses: actions/checkout@master | |
with: | |
submodules: recursive | |
- name: Install ${{ matrix.rust }} | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: ${{ matrix.rust }} | |
target: ${{ matrix.target }} | |
override: true | |
- uses: msys2/setup-msys2@v2 | |
- name: check | |
uses: actions-rs/cargo@v1 | |
with: | |
command: check | |
args: --all --bins --tests --target ${{ matrix.target }} | |
- name: check nightly | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: check | |
args: --features nightly --all --bins --examples --tests --target ${{ matrix.target }} | |
- name: check wasm | |
uses: actions-rs/cargo@v1 | |
with: | |
command: check | |
override: true | |
args: --features wasm --all --bins --target wasm32-unknown-unknown | |
- name: check bench | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: check | |
target: ${{ matrix.target }} | |
args: --benches | |
- name: tests | |
uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
args: --all --target ${{ matrix.target }} | |
- name: nightly | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: test | |
args: --all --features nightly --target ${{ matrix.target }} | |
- name: tests ignored | |
uses: actions-rs/cargo@v1 | |
with: | |
command: test | |
args: --all --target ${{ matrix.target }} --release -- --ignored | |
- name: nightly ignored | |
uses: actions-rs/cargo@v1 | |
if: ${{ matrix.rust == env.RUST_NIGHTLY }} | |
with: | |
command: test | |
args: --all --features nightly --target ${{ matrix.target }} --release -- --ignored | |
cross: | |
name: Cross compile | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
target: | |
- i686-unknown-linux-gnu | |
- powerpc-unknown-linux-gnu | |
- arm-linux-androideabi | |
steps: | |
- name: Checkout | |
uses: actions/checkout@master | |
with: | |
submodules: recursive | |
- name: Install stable | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: 1.74 | |
target: ${{ matrix.target }} | |
override: true | |
- name: Install cross | |
run: cargo install cross | |
- name: check | |
run: cross check --all --target ${{ matrix.target }} | |
- name: test | |
run: cross test --all --target ${{ matrix.target }} | |
check_wasm: | |
name: Check wasm targets | |
runs-on: ubuntu-latest | |
strategy: | |
matrix: | |
rust: | |
- nightly-2024-02-07 | |
- beta | |
- stable | |
steps: | |
- uses: actions/checkout@master | |
- name: Install rust with wasm32-unknown-unknown | |
uses: actions-rs/toolchain@v1 | |
with: | |
toolchain: ${{ matrix.rust }} | |
target: wasm32-unknown-unknown | |
override: true | |
- name: Cache cargo registry | |
uses: actions/cache@v2 | |
with: | |
path: ~/.cargo/registry | |
key: wasm32-${{ matrix.rust }}-cargo-registry-${{ hashFiles('**/Cargo.toml') }} | |
- name: check | |
uses: actions-rs/cargo@v1 | |
with: | |
command: check | |
args: --target wasm32-unknown-unknown --features wasm | |
check_fmt_and_docs: | |
name: Checking fmt and docs | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
- uses: actions-rs/toolchain@v1 | |
with: | |
profile: minimal | |
toolchain: ${{ env.RUST_NIGHTLY }} | |
override: true | |
components: rustfmt | |
- name: setup | |
run: | | |
rustup component add rustfmt | |
rustc --version | |
- name: fmt | |
run: cargo fmt --all -- --check | |
- name: Docs | |
run: cargo doc | |
clippy_check: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@master | |
- uses: actions-rs/toolchain@v1 | |
with: | |
profile: minimal | |
toolchain: ${{ env.RUST_NIGHTLY }} | |
override: true | |
components: clippy | |
- uses: actions-rs/clippy-check@v1 | |
with: | |
token: ${{ secrets.GITHUB_TOKEN }} | |
args: --all-features --all-targets | |
codespell: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v2 | |
- uses: codespell-project/actions-codespell@master |