Skip to content

Merge branch 'main' into get-kernel-variants-example #2675

Merge branch 'main' into get-kernel-variants-example

Merge branch 'main' into get-kernel-variants-example #2675

Workflow file for this run

name: Rust
on:
push:
pull_request:
paths-ignore:
- "docs/**"
- "*.md"
concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.ref }}
cancel-in-progress: true
jobs:
fmt:
name: Rustfmt
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: dtolnay/rust-toolchain@e081816240890017053eacbb1bdf337761dc5582 # 1.95.0
with:
components: rustfmt
- name: Cargo fmt (kernel-abi-check)
run: |
( cd kernel-abi-check && cargo fmt --all -- --check )
- name: Cargo fmt (kernels-data)
run: |
( cd kernels-data && cargo fmt --all -- --check )
( cd kernels-data/bindings/python && cargo fmt --all -- --check )
- name: Cargo fmt (kernel-builder)
run: ( cd kernel-builder && cargo fmt --all -- --check )
clippy:
name: Clippy
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- uses: dtolnay/rust-toolchain@e081816240890017053eacbb1bdf337761dc5582 # 1.95.0
with:
components: clippy
- name: Clippy (kernel-abi-check)
run: |
( cd kernel-abi-check && cargo clippy -- -D warnings )
- name: Clippy (kernels-data)
run: |
( cd kernels-data && cargo clippy -- -D warnings )
( cd kernels-data/bindings/python && cargo clippy -- -D warnings )
- name: Clippy (kernel-builder)
run: ( cd kernel-builder && cargo clippy -- -D warnings )
test:
name: Test
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@de0fac2e4500dabe0009e67214ff5f5447ce83dd # v6.0.2
- uses: actions/cache@27d5ce7f107fe9357f9df03efb73ab90386fccae # v5.0.5
with:
path: |
~/.cargo/bin/
~/.cargo/registry/index/
~/.cargo/registry/cache/
~/.cargo/git/db/
target/
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
- uses: dtolnay/rust-toolchain@e081816240890017053eacbb1bdf337761dc5582 # 1.95.0
- name: Test (kernel-abi-check)
run: cargo test -p kernel-abi-check
- name: Test (kernels-data)
run: cargo test -p kernels-data
- name: Test (kernel-builder)
run: cargo test -p hf-kernel-builder