Skip to content

Add examples to workflow #4

Add examples to workflow

Add examples to workflow #4

name: Build Examples
on:
push:
branches: [main, master]
pull_request:
branches: [main, master]
jobs:
build:
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
board: [esp32dev, esp32-s2-saola-1, esp32-s3-devkitc-1, esp32-c3-devkitm-1]
steps:
- name: Checkout repository
uses: actions/checkout@v4
- name: Set up Python
uses: actions/setup-python@v5
with:
python-version: '3.x'
- name: Install PlatformIO
run: pip install platformio
- name: Compile all examples
run: |
for ino in examples/*/*.ino; do
echo "Building: $ino (board: ${{ matrix.board }})"
pio ci "$ino" \
--lib=src \
--board=${{ matrix.board }} \
--project-option="platform=espressif32@~4.4.0" \
--project-option="framework=arduino"
done