Skip to content

Housekeeping

Housekeeping #123

Workflow file for this run

# LibraryBuild.yml
# Github workflow script to test compile all examples of an Arduino library repository.
#
# Copyright (C) 2020 Armin Joachimsmeyer
# https://github.com/ArminJo/Github-Actions
#
# This is the name of the workflow, visible on GitHub UI.
name: LibraryBuild
on:
workflow_dispatch: # To run it manually
description: 'manual build check'
push: # see: https://help.github.com/en/actions/reference/events-that-trigger-workflows#pull-request-event-pull_request
paths:
- '**.ino'
- '**.cpp'
- '**.hpp'
- '**.h'
- '**LibraryBuild.yml'
pull_request:
jobs:
build:
name: ${{ matrix.arduino-boards-fqbn }} - test compiling examples
runs-on: ubuntu-latest # I picked Ubuntu to use shell scripts.
env:
# Comma separated list without double quotes around the list.
REQUIRED_LIBRARIES: Adafruit NeoPixel,PlayRtttl
strategy:
matrix:
# The matrix will produce one job for each configuration parameter of type `arduino-boards-fqbn`
# In the Arduino IDE, the fqbn is printed in the first line of the verbose output for compilation as parameter -fqbn=... for the "arduino-builder -dump-prefs" command
#
# Examples: arduino:avr:uno, arduino:avr:leonardo, arduino:avr:nano, arduino:avr:mega
# arduino:sam:arduino_due_x, arduino:samd:arduino_zero_native"
# ATTinyCore:avr:attinyx5:chip=85,clock=1internal, digistump:avr:digispark-tiny, digistump:avr:digispark-pro
# STMicroelectronics:stm32:GenF1:pnum=BLUEPILL_F103C8
# esp8266:esp8266:huzzah:eesz=4M3M,xtal=80, esp32:esp32:featheresp32:FlashFreq=80
# You may add a suffix behind the fqbn with "|" to specify one board for e.g. different compile options like arduino:avr:uno|trace
#############################################################################################################
arduino-boards-fqbn:
- arduino:avr:uno
- arduino:avr:uno|All-DO_NOT_SUPPORT_RGBW
- arduino:avr:leonardo
- arduino:avr:mega
- esp8266:esp8266:huzzah:eesz=4M3M,xtal=80
- esp32:esp32:featheresp32:FlashFreq=80
- STMicroelectronics:stm32:GenF1:pnum=BLUEPILL_F103C8
# - stm32duino:STM32F1:genericSTM32F103C # 2 issues pending for it
# Specify parameters for each board.
#############################################################################################################
include:
- arduino-boards-fqbn: arduino:avr:uno|All-DO_NOT_SUPPORT_RGBW
build-properties:
AllPatternsOnMultiDevices: -DALL_PATTERN_ON_ONE_STRIP -DDO_NOT_SUPPORT_RGBW
OpenLedRace: -DUSE_SOFT_I2C_MASTER -DDO_NOT_SUPPORT_RGBW
SnowFlakes: -DTRACE
All: -DDO_NOT_SUPPORT_RGBW
- arduino-boards-fqbn: arduino:avr:leonardo
build-properties:
AllPatternOnOneBar: -DTEST_USER_PATTERNS
sketches-exclude: AllPatternsOnMultiDevices,OpenLedRace # too big
- arduino-boards-fqbn: esp8266:esp8266:huzzah:eesz=4M3M,xtal=80
platform-url: https://arduino.esp8266.com/stable/package_esp8266com_index.json
sketches-exclude: OpenLedRace,MatrixPatternsTest,TwoPatternsOnOneStrip # Comma separated list of example names to exclude in build
- arduino-boards-fqbn: esp32:esp32:featheresp32:FlashFreq=80
platform-url: https://raw.githubusercontent.com/espressif/arduino-esp32/gh-pages/package_esp32_index.json
sketches-exclude: OpenLedRace,MatrixPatternsTest,TwoPatternsOnOneStrip # MatrixPatternsTest,TwoPatternsOnOneStrip because of missing EasyButton library
- arduino-boards-fqbn: STMicroelectronics:stm32:GenF1:pnum=BLUEPILL_F103C8
platform-url: https://raw.githubusercontent.com/stm32duino/BoardManagerFiles/main/package_stmicroelectronics_index.json
sketches-exclude: OpenLedRace,MatrixPatternsTest,TwoPatternsOnOneStrip # MatrixPatternsTest,TwoPatternsOnOneStrip because of missing EasyButton library
# - arduino-boards-fqbn: stm32duino:STM32F1:genericSTM32F103C # Roger Clark version
# platform-url: http://dan.drown.org/stm32duino/package_STM32duino_index.json
# sketches-exclude: OpenLedRace,MatrixPatternsTest,TwoPatternsOnOneStrip # MatrixPatternsTest,TwoPatternsOnOneStrip because of missing EasyButton library
# Do not cancel all jobs / architectures if one job fails
fail-fast: false
steps:
- name: Checkout
uses: actions/checkout@master
- name: Compile all examples using the arduino-test-compile action
uses: ArminJo/arduino-test-compile@master
with:
arduino-board-fqbn: ${{ matrix.arduino-boards-fqbn }}
arduino-platform: ${{ matrix.arduino-platform }}
platform-url: ${{ matrix.platform-url }}
required-libraries: ${{ env.REQUIRED_LIBRARIES }}
sketches-exclude: ${{ matrix.sketches-exclude }}
build-properties: ${{ toJson(matrix.build-properties) }}