Skip to content

Commit 8039665

Browse files
committed
Modernize the examples compilation CI workflow
The previous workflow was using the original experimental version of the action, which is now deprecated.
1 parent 803181c commit 8039665

File tree

2 files changed

+84
-18
lines changed

2 files changed

+84
-18
lines changed
Lines changed: 78 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -1,19 +1,82 @@
11
name: Compile Examples
2-
on: [push, pull_request]
2+
3+
# See: https://docs.github.com/en/free-pro-team@latest/actions/reference/events-that-trigger-workflows
4+
on:
5+
push:
6+
paths:
7+
- ".github/workflows/compile-examples.yml"
8+
- "examples/**"
9+
- "src/**"
10+
pull_request:
11+
paths:
12+
- ".github/workflows/compile-examples.yml"
13+
- "examples/**"
14+
- "src/**"
15+
schedule:
16+
# Run every Tuesday at 8 AM UTC to catch breakage caused by changes to external resources (libraries, platforms).
17+
- cron: "0 8 * * TUE"
18+
workflow_dispatch:
19+
repository_dispatch:
20+
321
jobs:
4-
build:
5-
runs-on: ubuntu-latest
22+
build:
23+
name: ${{ matrix.board.fqbn }}
24+
runs-on: ubuntu-latest
25+
26+
strategy:
27+
fail-fast: false
28+
29+
matrix:
30+
board:
31+
# Compile for all boards using the MKR form factor.
32+
- fqbn: arduino:samd:mkr1000
33+
platforms: |
34+
- name: arduino:samd
35+
- fqbn: arduino:samd:mkrzero
36+
platforms: |
37+
- name: arduino:samd
38+
- fqbn: arduino:samd:mkrwifi1010
39+
platforms: |
40+
- name: arduino:samd
41+
- fqbn: arduino:samd:mkrfox1200
42+
platforms: |
43+
- name: arduino:samd
44+
- fqbn: arduino:samd:mkrwan1300
45+
platforms: |
46+
- name: arduino:samd
47+
- fqbn: arduino:samd:mkrwan1310
48+
platforms: |
49+
- name: arduino:samd
50+
- fqbn: arduino:samd:mkrgsm1400
51+
platforms: |
52+
- name: arduino:samd
53+
- fqbn: arduino:samd:mkrnb1500
54+
platforms: |
55+
- name: arduino:samd
56+
- fqbn: arduino:samd:mkrvidor4000
57+
platforms: |
58+
- name: arduino:samd
59+
- fqbn: arduino:mbed_portenta:envie_m4
60+
platforms: |
61+
- name: arduino:mbed_portenta
62+
- fqbn: arduino:mbed_portenta:envie_m7
63+
platforms: |
64+
- name: arduino:mbed_portenta
665
7-
strategy:
8-
matrix:
9-
fqbn: [
10-
"arduino:samd:mkrzero"
11-
]
66+
steps:
67+
- name: Checkout repository
68+
uses: actions/checkout@v2
1269

13-
steps:
14-
- uses: actions/checkout@v1
15-
with:
16-
fetch-depth: 1
17-
- uses: arduino/actions/libraries/compile-examples@master
18-
with:
19-
fqbn: ${{ matrix.fqbn }}
70+
- name: Compile examples
71+
uses: arduino/compile-sketches@v1
72+
with:
73+
github-token: ${{ secrets.GITHUB_TOKEN }}
74+
fqbn: ${{ matrix.board.fqbn }}
75+
platforms: ${{ matrix.board.platforms }}
76+
libraries: |
77+
# Install the library from the local path.
78+
- source-path: ./
79+
# Additional library dependencies can be listed here.
80+
# See: https://github.com/arduino/compile-sketches#libraries
81+
sketch-paths: |
82+
- examples

README.adoc

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1,10 +1,13 @@
1-
= MKRTHERM Library for Arduino =
1+
:repository-owner: arduino-libraries
2+
:repository-name: Arduino_MKRTHERM
23

3-
image:https://github.com/arduino-libraries/Arduino_MKRTHERM/workflows/Compile%20Examples/badge.svg["Compile Examples Status", link="https://github.com/arduino-libraries/Arduino_MKRTHERM/actions?workflow=Compile+Examples"] image:https://github.com/arduino-libraries/Arduino_MKRTHERM/workflows/Spell%20Check/badge.svg["Spell Check Status", link="https://github.com/arduino-libraries/Arduino_MKRTHERM/actions?workflow=Spell+Check"]
4+
= {repository-name} Library for Arduino =
5+
6+
image:https://github.com/{repository-owner}/{repository-name}/actions/workflows/compile-examples.yml/badge.svg["Compile Examples status", link="https://github.com/{repository-owner}/{repository-name}/actions/workflows/compile-examples.yml"]
47

58
Allows you to read the temperature sensors connected to your MKR THERM shield.
69

7-
For more information about this library please visit us at https://www.arduino.cc/en/Reference/Arduino_MKRTHERM
10+
For more information about this library please visit us at https://www.arduino.cc/en/Reference/{repository-name}
811

912

1013
== License ==

0 commit comments

Comments
 (0)