Skip to content

Commit edbcf2a

Browse files
committed
Add "smoke test" examples compilation CI workflow
On every push or pull request that affects library source or example files, compile all example sketches for the specified boards.
1 parent 19d2309 commit edbcf2a

File tree

2 files changed

+59
-0
lines changed

2 files changed

+59
-0
lines changed
Lines changed: 58 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,58 @@
1+
name: Compile Examples
2+
3+
on:
4+
pull_request:
5+
paths:
6+
- ".github/workflows/compile-examples.yml"
7+
- "examples/**"
8+
- "src/**"
9+
push:
10+
paths:
11+
- ".github/workflows/compile-examples.yml"
12+
- "examples/**"
13+
- "src/**"
14+
# Scheduled trigger checks for breakage caused by changes to external resources (libraries, platforms)
15+
schedule:
16+
# run every Saturday at 3 AM UTC
17+
- cron: "0 3 * * 6"
18+
# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows#workflow_dispatch
19+
workflow_dispatch:
20+
# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows#repository_dispatch
21+
repository_dispatch:
22+
23+
jobs:
24+
build:
25+
runs-on: ubuntu-latest
26+
27+
strategy:
28+
fail-fast: false
29+
30+
matrix:
31+
board:
32+
- fqbn: arduino:mbed:envie_m7
33+
- fqbn: arduino:megaavr:uno2018
34+
- fqbn: arduino:samd:mkr1000
35+
- fqbn: arduino:samd:mkrwifi1010
36+
- fqbn: arduino:samd:nano_33_iot
37+
- fqbn: arduino:samd:mkrwan1300
38+
- fqbn: arduino:samd:mkrwan1310
39+
- fqbn: arduino:samd:mkrgsm1400
40+
- fqbn: arduino:samd:mkrnb1500
41+
- fqbn: arduino:samd:mkrvidor4000
42+
43+
steps:
44+
- name: Checkout
45+
uses: actions/checkout@v2
46+
47+
- name: Compile examples
48+
uses: arduino/compile-sketches@main
49+
with:
50+
github-token: ${{ secrets.GITHUB_TOKEN }}
51+
fqbn: ${{ matrix.board.fqbn }}
52+
libraries: |
53+
# Install the library from the local path.
54+
- source-path: ./
55+
# Additional library dependencies can be listed here.
56+
# See: https://github.com/arduino/compile-sketches#libraries
57+
sketch-paths: |
58+
- ./examples/

README.adoc

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@
44

55
= {repository-name} =
66

7+
image:https://github.com/{repository-owner}/{repository-name}/workflows/Compile%20Examples/badge.svg["Compile Examples Status", link="https://github.com/{repository-owner}/{repository-name}/actions?workflow=Compile+Examples"]
78
image:https://github.com/{repository-owner}/{repository-name}/workflows/Spell%20Check/badge.svg["Spell Check Status", link="https://github.com/{repository-owner}/{repository-name}/actions?workflow=Spell+Check"]
89

910
Arduino Library for the Atmel/Microchip ECC508 and ECC608 crypto chips

0 commit comments

Comments
 (0)