Skip to content

fix(ci): tweak macos targets to install LLVM #54

fix(ci): tweak macos targets to install LLVM

fix(ci): tweak macos targets to install LLVM #54

Workflow file for this run

name: Build & Test
permissions:
contents: read
checks: write
on:
push:
branches: [main]
pull_request:
branches: [main]
env:
CARGO_TERM_COLOR: always
# Allow only one concurrent deployment, skipping runs queued between the run in-progress and latest queued.
# However, do NOT cancel in-progress runs as we want to allow these production deployments to complete.
concurrency:
group: rust
cancel-in-progress: false
jobs:
build:
name: Build
runs-on: ubuntu-latest
timeout-minutes: 30
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
- name: Cache
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-rust-${{ hashFiles('**/Cargo.toml') }}
- name: Build
run: cargo build --verbose
clippy:
name: Clippy Check
timeout-minutes: 30
runs-on: ubuntu-latest
needs: build
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
- name: Cache
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-rust-${{ hashFiles('**/Cargo.toml') }}
- name: Install Nightly Toolchain
uses: dtolnay/rust-toolchain@stable
with:
components: clippy
toolchain: nightly-2024-01-17
- name: Run clippy
run: cargo clippy -- -D warnings
test:
name: Test
timeout-minutes: 30
needs: build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
- name: Cache
uses: actions/cache@v3
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-rust-${{ hashFiles('**/Cargo.toml') }}
- name: Run tests
run: cargo test --verbose