summaryrefslogtreecommitdiff
path: root/.github
diff options
context:
space:
mode:
authorinnovaker <66737976+innovaker@users.noreply.github.com>2020-12-02 10:24:32 +0000
committerPete Johanson <peter@peterjohanson.com>2020-12-06 22:49:35 -0500
commit8ad4f4133d737963795b0afe9d40f4612618a476 (patch)
treedf3d927cc8c6de3437c101d7c15e01f1e6ac3765 /.github
parent7ea1892bbb146eb5ce4d8602c136fadb54d454c8 (diff)
ci(build): add support for board-only builds
Lays the groundwork for CI building boards that don't require shields. PR: #464
Diffstat (limited to '.github')
-rw-r--r--.github/workflows/build.yml19
1 files changed, 17 insertions, 2 deletions
diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml
index 6ead576..eed7843 100644
--- a/.github/workflows/build.yml
+++ b/.github/workflows/build.yml
@@ -86,13 +86,28 @@ jobs:
id: west-zephyr-export
with:
args: "zephyr-export"
+ - name: Prepare variables
+ id: variables
+ run: |
+ SHIELD_ARG=
+ ARTIFACT_NAME="${{ matrix.board }}"
+
+ if [ -n "${{ matrix.shield }}" ]; then
+ SHIELD_ARG="-DSHIELD=${{ matrix.shield }}"
+ ARTIFACT_NAME="${ARTIFACT_NAME}-${{ matrix.shield }}"
+ fi
+
+ ARTIFACT_NAME="${ARTIFACT_NAME}-zmk"
+
+ echo ::set-output name=shield-arg::${SHIELD_ARG}
+ echo ::set-output name=artifact-name::${ARTIFACT_NAME}
- name: West build
uses: "docker://zmkfirmware/zephyr-west-action-arm:latest"
id: west-build
with:
- args: 'build "-s app -b ${{ matrix.board }} -- -DSHIELD=${{ matrix.shield }}"'
+ args: 'build "-s app -b ${{ matrix.board }} -- ${{ steps.variables.outputs.shield-arg }}'
- name: Archive build
uses: actions/upload-artifact@v2
with:
- name: "${{ matrix.board }}-${{ matrix.shield }}-zmk-uf2"
+ name: "${{ steps.variables.outputs.artifact-name }}-uf2"
path: build/zephyr/zmk.uf2