Add GitHub Actions build
This commit is contained in:
101
.github/workflows/build.yml
vendored
Normal file
101
.github/workflows/build.yml
vendored
Normal file
@@ -0,0 +1,101 @@
|
|||||||
|
name: Build firmware
|
||||||
|
on:
|
||||||
|
push:
|
||||||
|
paths-ignore:
|
||||||
|
- '**.md'
|
||||||
|
|
||||||
|
jobs:
|
||||||
|
build-default:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
keyboard:
|
||||||
|
- ergodox_ez
|
||||||
|
- ergodox_ez/shine
|
||||||
|
- ergodox_ez/glow
|
||||||
|
- moonlander
|
||||||
|
- planck/ez
|
||||||
|
- planck/ez/glow
|
||||||
|
keymap:
|
||||||
|
- default
|
||||||
|
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
fetch-depth: 1
|
||||||
|
persist-credentials: false
|
||||||
|
submodules: true
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
id: build
|
||||||
|
run: |
|
||||||
|
TARGET="${{ matrix.keyboard }}"
|
||||||
|
|
||||||
|
if [ -n "${{ matrix.keymap }}" ]; then
|
||||||
|
TARGET="${TARGET}:${{ matrix.keymap }}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
sed -i 's/run --rm -it/run --rm/' util/docker_build.sh
|
||||||
|
util/docker_build.sh ${TARGET}
|
||||||
|
|
||||||
|
ls
|
||||||
|
|
||||||
|
echo ::set-output name=artifact-name::${TARGET//[:<>|*?\\\/]/_}
|
||||||
|
echo "Artifact-name: ${{ steps.build.outputs.artifact-name }}"
|
||||||
|
|
||||||
|
- name: Archive artifacts
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: "${{ steps.build.outputs.artifact-name }}"
|
||||||
|
path: |
|
||||||
|
*.hex
|
||||||
|
*.bin
|
||||||
|
continue-on-error: true
|
||||||
|
|
||||||
|
build-default:
|
||||||
|
runs-on: ubuntu-latest
|
||||||
|
strategy:
|
||||||
|
fail-fast: false
|
||||||
|
matrix:
|
||||||
|
keyboard:
|
||||||
|
- ergodox_ez
|
||||||
|
- ergodox_ez/shine
|
||||||
|
- ergodox_ez/glow
|
||||||
|
- moonlander
|
||||||
|
- planck/ez
|
||||||
|
- planck/ez/glow
|
||||||
|
keymap:
|
||||||
|
- oryx
|
||||||
|
steps:
|
||||||
|
- uses: actions/checkout@v2
|
||||||
|
with:
|
||||||
|
fetch-depth: 1
|
||||||
|
persist-credentials: false
|
||||||
|
submodules: true
|
||||||
|
|
||||||
|
- name: Build
|
||||||
|
id: build
|
||||||
|
run: |
|
||||||
|
TARGET="${{ matrix.keyboard }}"
|
||||||
|
|
||||||
|
if [ -n "${{ matrix.keymap }}" ]; then
|
||||||
|
TARGET="${TARGET}:${{ matrix.keymap }}"
|
||||||
|
fi
|
||||||
|
|
||||||
|
sed -i 's/run --rm -it/run --rm/' util/docker_build.sh
|
||||||
|
util/docker_build.sh ${TARGET}
|
||||||
|
|
||||||
|
ls
|
||||||
|
|
||||||
|
echo ::set-output name=artifact-name::${TARGET//[:<>|*?\\\/]/_}
|
||||||
|
echo "Artifact-name: ${{ steps.build.outputs.artifact-name }}"
|
||||||
|
|
||||||
|
- name: Archive artifacts
|
||||||
|
uses: actions/upload-artifact@v2
|
||||||
|
with:
|
||||||
|
name: "${{ steps.build.outputs.artifact-name }}"
|
||||||
|
path: |
|
||||||
|
*.hex
|
||||||
|
*.bin
|
||||||
|
continue-on-error: true
|
||||||
Reference in New Issue
Block a user