-
Notifications
You must be signed in to change notification settings - Fork 7
51 lines (42 loc) · 1.27 KB
/
build-esp32-c3-rust.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
name: CI for ESP32-C3
on:
push:
paths:
- "esp32-c3/**"
- "spooky-core/**"
- "spooky-embedded/**"
workflow_dispatch:
env:
CARGO_TERM_COLOR: always
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
jobs:
rust-checks:
name: Rust Checks
runs-on: ubuntu-latest
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Setup Rust (Xtensa)
uses: esp-rs/xtensa-toolchain@v1.5
with:
default: true
version: '1.82.0'
buildtargets: esp32c3
ldproxy: false
- name: Enable caching
uses: Swatinem/rust-cache@v2
- name: Run checks sequentially for all boards
working-directory: esp32-c3
run: |
# Define the list of boards to build
# boards=("esp32-c3-devkit-rust" "esp32-c3-lcdkit")
boards=("esp32-c3-lcdkit")
# Perform common checks
echo "Running common checks"
cargo fmt --all -- --check --color always
# Iterate through each board and build
for board in "${boards[@]}"; do
echo "Building for board: $board"
cargo clippy --release --features "$board" --workspace -- -D warnings
cargo build --release --features "$board"
done