Template
Compare commits
1
Commits
master
...
a99599110d
| Author | SHA1 | Date | |
|---|---|---|---|
|
|
a99599110d |
@@ -0,0 +1,67 @@
|
||||
|
||||
name: Lint & Build
|
||||
|
||||
on:
|
||||
push:
|
||||
branches: [ main, master ]
|
||||
pull_request:
|
||||
|
||||
jobs:
|
||||
lint:
|
||||
name: Linting
|
||||
runs-on: ubuntu-latest
|
||||
|
||||
steps:
|
||||
- name: Checkout Project
|
||||
uses: actions/checkout@v5
|
||||
|
||||
- name: Setup Rust
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
targets: thumbv8m.main-none-eabihf
|
||||
components: rustfmt, clippy
|
||||
|
||||
- name: Install cargo sort
|
||||
uses: taiki-e/install-action@v2
|
||||
with:
|
||||
tool: cargo-sort
|
||||
|
||||
- name: Install cargo machete
|
||||
uses: taiki-e/install-action@v2
|
||||
with:
|
||||
tool: cargo-machete
|
||||
|
||||
- name: Check formatting
|
||||
run: cargo fmt --check
|
||||
|
||||
- name: Check import sorting
|
||||
run: cargo sort --grouped --check --check-format
|
||||
|
||||
- name: Check for unused dependencies
|
||||
run: cargo machete
|
||||
|
||||
- name: Clippy for RP2350 ARM Cores
|
||||
run: |
|
||||
cargo clippy --target thumbv8m.main-none-eabihf -- -D warnings
|
||||
build:
|
||||
name: Build
|
||||
runs-on: ubuntu-latest
|
||||
needs: lint
|
||||
|
||||
steps:
|
||||
- name: Checkout Project
|
||||
uses: actions/checkout@v5
|
||||
|
||||
- name: Setup Rust
|
||||
uses: dtolnay/rust-toolchain@stable
|
||||
with:
|
||||
targets: thumbv8m.main-none-eabihf
|
||||
|
||||
- name: Build for RP2350 ARM Cores
|
||||
run: |
|
||||
cargo build --target thumbv8m.main-none-eabihf --release --locked
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
Reference in New Issue
Block a user