-
Notifications
You must be signed in to change notification settings - Fork 189
81 lines (64 loc) · 1.83 KB
/
build.yml
File metadata and controls
81 lines (64 loc) · 1.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
name: build
on:
push:
branches: ["**"]
tags: ["**"]
pull_request:
workflow_dispatch:
jobs:
build-test:
strategy:
fail-fast: false
max-parallel: 3
matrix:
os: [ubuntu-latest, macos-15, windows-latest]
runs-on: ${{ matrix.os }}
timeout-minutes: 15
steps:
- uses: actions/checkout@v5
- uses: actions/cache@v4
with:
path: |
~/.cache/pip
~/.platformio/.cache
key: ${{ runner.os }}-pio
- uses: actions/setup-python@v6
with:
python-version: "3.13"
- uses: maxim-lobanov/setup-xcode@v1
if: matrix.os == 'macos-15'
with:
xcode-version: latest-stable
- name: Install PlatformIO Core
run: pip install --upgrade platformio
- name: Display PlatformIO Information
run: |
pio system info
g++ --version
gcc --version
- name: build (trmnl)
run: pio run
- name: build (TRMNL_X)
run: pio run -e TRMNL_X
- name: test
if: matrix.os != 'windows-latest'
run: pio test -e native -v
- name: test (windows)
if: matrix.os == 'windows-latest'
run: pio test -e native-windows -v
- name: static analysis
run: pio check --skip-packages --fail-on-defect high
publish-engineering-build:
needs: build-test
if: github.ref == 'refs/heads/main' && github.event_name == 'push'
uses: ./.github/workflows/publish-firmware.yml
with:
include_git_hash_in_firmware_version: true
filename_suffix_type: git_short_hash
publish-tagged-build:
needs: build-test
if: startsWith(github.ref, 'refs/tags/')
uses: ./.github/workflows/publish-firmware.yml
with:
include_git_hash_in_firmware_version: false
filename_suffix_type: git_tag