Rust SDK Update and Refactor #463
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
on: [push, pull_request] | |
name: CI | |
env: | |
CARGO_TERM_COLOR: always | |
RUSTFLAGS: -D warnings | |
RUSTDOCFLAGS: -D warnings | |
jobs: | |
Features: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -yqq alsa | |
sudo apt-get install -y libasound2-dev pkg-config | |
- name: Check no features | |
run: cargo check --all-targets --no-default-features | |
- name: Check prerecorded feature | |
run: cargo check --all-targets --no-default-features --features=prerecorded | |
- name: Check live feature | |
run: cargo check --all-targets --no-default-features --features=live | |
Build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -yqq alsa | |
sudo apt-get install -y libasound2-dev pkg-config | |
- name: Cargo Build | |
run: cargo build --all-targets --all-features | |
Clippy: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -yqq alsa | |
sudo apt-get install -y libasound2-dev pkg-config | |
- name: Cargo Clippy | |
run: cargo clippy --all-targets --all-features | |
Test: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -yqq alsa | |
sudo apt-get install -y libasound2-dev pkg-config | |
- name: Cargo Test | |
run: cargo test --all --all-features | |
Format: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Cargo Fmt | |
run: cargo fmt --check --all | |
Documentation: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Cargo Doc | |
run: cargo doc --workspace --all-features | |
Audit: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: sudo apt-get update | |
- name: Install cargo-audit | |
run: cargo install --locked cargo-audit | |
- name: Remove Dev Dependencies | |
run: | | |
cargo install --locked cargo-hack | |
cargo hack --remove-dev-deps | |
cargo generate-lockfile | |
- name: Cargo Audit | |
run: cargo audit | |
Minimal-Versions: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: | | |
sudo apt-get update | |
sudo apt-get install -yqq alsa | |
sudo apt-get install -y libasound2-dev pkg-config | |
- name: Install Rust Nightly | |
run: rustup toolchain install nightly | |
- name: Cargo Build | |
run: rustup run nightly cargo build --all-targets --all-features -Z minimal-versions | |
- name: Cargo Test | |
run: rustup run nightly cargo test --all --all-features -Z minimal-versions | |
- name: Remove Dev Dependencies | |
run: | | |
cargo install --locked cargo-hack | |
cargo hack --remove-dev-deps | |
rustup run nightly cargo generate-lockfile -Z minimal-versions | |
- name: Cargo Build Without Dev Dependencies | |
run: rustup run nightly cargo build --all-features -Z minimal-versions | |
SemVer: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v3 | |
- name: Install dependencies | |
run: sudo apt-get update | |
- name: Install cargo-semver-checks | |
run: cargo install --locked cargo-semver-checks | |
- name: Cargo SemVer Checks | |
run: cargo semver-checks check-release --verbose |