-
Notifications
You must be signed in to change notification settings - Fork 498
97 lines (75 loc) · 2.39 KB
/
build.yml
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
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
name: Build all firmwares
on:
push:
paths:
- 'qmk_firmware/keyboards/keyball/**.c'
- 'qmk_firmware/keyboards/keyball/**.h'
- 'qmk_firmware/keyboards/keyball/**.json'
- '.github/actions/setup-qmk/**.yml'
- '.github/workflows/build*.yml'
tags-ignore:
- '*'
branches:
- '*'
pull_request:
paths:
- 'qmk_firmware/keyboards/keyball/**.c'
- 'qmk_firmware/keyboards/keyball/**.h'
- 'qmk_firmware/keyboards/keyball/**.json'
- '.github/actions/setup-qmk/**.yml'
- '.github/workflows/build*.yml'
workflow_call: {}
jobs:
build:
strategy:
matrix:
keyboard: [ keyball39, keyball44, keyball61, keyball46, one47 ]
keymap: [ test, default, via ]
include:
- keyboard: keyball46
keymap: test_Left
- keyboard: keyball46
keymap: test_Both
- keyboard: keyball46
keymap: via_Left
- keyboard: keyball46
keymap: via_Both
name: Build ${{ matrix.keyboard }} w/ ${{ matrix.keymap }}
runs-on: ubuntu-latest
container:
image: ghcr.io/qmk/qmk_cli:latest
steps:
- name: Checkout source
uses: actions/checkout@v4
- name: Checkout qmk_firmware
uses: ./.github/actions/checkout-qmk_firmware
- name: Install a link to own source
run: ln -s $(pwd)/qmk_firmware/keyboards/keyball __qmk__/keyboards/keyball
- run: qmk compile -j 4 -kb keyball/${{ matrix.keyboard }} -km ${{ matrix.keymap }}
- name: Archive firmwares
uses: actions/upload-artifact@v3
with:
name: ${{ matrix.keyboard }}-firmwares
path: __qmk__/*.hex
check-size:
name: Check size
runs-on: ubuntu-latest
needs:
- build
steps:
- uses: actions/download-artifact@v3
with: { name: keyball39-firmwares }
- uses: actions/download-artifact@v3
with: { name: keyball44-firmwares }
- uses: actions/download-artifact@v3
with: { name: keyball61-firmwares }
- uses: actions/download-artifact@v3
with: { name: keyball46-firmwares }
- uses: actions/download-artifact@v3
with: { name: one47-firmwares }
- name: List size of firmwares
run: |
for f in *.hex ; do
cut -c 2,3 $f | awk '{s+=strtonum("0x" $1)}END{printf "%5d/28672 (%2d%%, %5d bytes free) ",s,s*100/28672,28672-s}'
echo $f
done