-
Notifications
You must be signed in to change notification settings - Fork 3
46 lines (37 loc) · 997 Bytes
/
pio.yaml
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
name: PlatformIO Build
on:
push:
pull_request:
jobs:
build:
runs-on: ubuntu-latest
outputs:
pkgfile: ${{ steps.pkgname.outputs.pkgfile }}
steps:
- name: Check out repo
uses: actions/checkout@v2
- name: Install dependencies
run: |
sudo apt update -qq
sudo apt install -yqq python3
pip install -U platformio
- name: Update PlatformIO
run: |
cd "$(realpath "$GITHUB_WORKSPACE")"
pio pkg update
- name: Build firmware
run: |
platformio run
- name: Upload files
uses: actions/upload-artifact@v3
with:
name: bin
path: ".pio/build/firmware.bin"
- name: Release build artifacts
uses: softprops/action-gh-release@v1
if: startsWith(github.ref, 'refs/tags/')
with:
files: |
./.pio/build/firmware.bin
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}