Build in CI using a build matrix (#41)

This commit is contained in:
Eirik Stanghelle Morland 2025-07-08 01:24:03 +02:00 committed by GitHub
parent 50dec7f82a
commit efeba609db
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -6,15 +6,24 @@ on:
branches-ignore:
- gh-pages
env:
BOARD: sensorwatch_red
DISPLAY: classic
jobs:
build:
container:
image: ghcr.io/armmbed/mbed-os-env:latest
runs-on: ubuntu-latest
strategy:
matrix:
board:
- "sensorwatch_red"
- "sensorwatch_green"
- "sensorwatch_blue"
- "sensorwatch_pro"
display:
- "classic"
- "custom"
env:
BOARD: ${{ matrix.board }}
DISPLAY: ${{ matrix.display }}
steps:
- name: Checkout
uses: actions/checkout@v4
@ -28,12 +37,25 @@ jobs:
- name: Upload artifacts
uses: actions/upload-artifact@v4
with:
name: movement.uf2
name: ${{ matrix.board }}-display-${{ matrix.display }}-movement.uf2
path: build/firmware.uf2
build-simulator:
container:
image: emscripten/emsdk
strategy:
matrix:
board:
- "sensorwatch_red"
- "sensorwatch_green"
- "sensorwatch_blue"
- "sensorwatch_pro"
display:
- "classic"
- "custom"
env:
BOARD: ${{ matrix.board }}
DISPLAY: ${{ matrix.display }}
runs-on: ubuntu-latest
steps:
- name: Checkout
@ -52,5 +74,5 @@ jobs:
- name: Upload simulator build
uses: actions/upload-artifact@v4
with:
name: movement.tar.gz
name: ${{ matrix.board }}-display-${{ matrix.display }}-movement.tar.gz
path: build-sim/movement.tar.gz