Skip to content

build(deps): bump the minor-updates group with 2 updates #339

build(deps): bump the minor-updates group with 2 updates

build(deps): bump the minor-updates group with 2 updates #339

Workflow file for this run

name: Build & Test
permissions:
contents: read
on:
push:
branches: [main]
pull_request:
branches: [main]
env:
CARGO_TERM_COLOR: always
nightly_toolchain: nightly-2024-01-17
# sccache enablement
SCCACHE_GHA_ENABLED: true
RUSTC_WRAPPER: sccache
# 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: step-security/harden-runner@17d0e2bd7d51742c71671bd19fa12bdc9d40a3d6 # v2.8.1
with:
egress-policy: audit
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
- name: Run sccache-cache
uses: mozilla-actions/sccache-action@89e9040de88b577a072e3760aaf59f585da083af # 0.0.5
- uses: dtolnay/rust-toolchain@21dc36fb71dd22e3317045c0c31a3f4249868b17 # master
with:
targets: x86_64-unknown-linux-gnu
toolchain: ${{ env.nightly_toolchain }}
- name: Build
run: cargo build
- name: Show sccache stats
shell: bash
run: |
echo '## SCCACHE STATS' >> $GITHUB_STEP_SUMMARY
echo '| Metric | Value |' >> $GITHUB_STEP_SUMMARY
echo '|--------|-------|' >> $GITHUB_STEP_SUMMARY
${SCCACHE_PATH} --show-stats | awk -F'[[:space:]][[:space:]]+' 'NR<=22{ print "| "$1" | "$2" |"}' >> $GITHUB_STEP_SUMMARY
echo '</hr>' >> $GITHUB_STEP_SUMMARY
clippy:
name: Clippy Check
timeout-minutes: 30
runs-on: ubuntu-latest
needs: build
steps:
- uses: step-security/harden-runner@17d0e2bd7d51742c71671bd19fa12bdc9d40a3d6 # v2.8.1
with:
egress-policy: audit
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
- name: Run sccache-cache
uses: mozilla-actions/sccache-action@89e9040de88b577a072e3760aaf59f585da083af # 0.0.5
- uses: dtolnay/rust-toolchain@21dc36fb71dd22e3317045c0c31a3f4249868b17 # master
with:
targets: x86_64-unknown-linux-gnu
toolchain: ${{ env.nightly_toolchain }}
- name: Install Nightly Toolchain
uses: dtolnay/rust-toolchain@21dc36fb71dd22e3317045c0c31a3f4249868b17 # 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: step-security/harden-runner@17d0e2bd7d51742c71671bd19fa12bdc9d40a3d6 # v2.8.1
with:
egress-policy: audit
- uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4
- name: Install Dependencies
run: sudo apt-get update; sudo apt-get install --no-install-recommends libasound2-dev libudev-dev
- name: Run sccache-cache
uses: mozilla-actions/sccache-action@89e9040de88b577a072e3760aaf59f585da083af # 0.0.5
- uses: dtolnay/rust-toolchain@21dc36fb71dd22e3317045c0c31a3f4249868b17 # master
with:
targets: x86_64-unknown-linux-gnu
toolchain: ${{ env.nightly_toolchain }}
- uses: taiki-e/install-action@331a600f1b10a3fed8dc56f925012bede91ae51f # v2.41.7
with:
tool: cargo-nextest
- name: Run tests
run: cargo nextest run