uv-k5-firmware-chinese-lts/.github/workflows/docker-image.yml
2023-12-08 22:39:56 +08:00

48 lines
1.2 KiB
YAML

on:
push:
jobs:
build:
runs-on: ubuntu-22.04
container:
image: archlinux:latest
steps:
- name: Install dependencies
run: |
pacman -Syyu --noconfirm \
base-devel \
arm-none-eabi-gcc \
arm-none-eabi-newlib \
git \
python-pip \
python-crcmod
- name: Checkout
uses: actions/checkout@v3
- name: safe.directory
run: git config --global --add safe.directory /__w/uv-k5-firmware-custom/uv-k5-firmware-custom
- name: Make
run: make
- name: size
run: arm-none-eabi-size firmware
- name: Upload Artifact
uses: actions/upload-artifact@v3
with:
name: firmware
path: firmware*.bin
- name: Upload binaries to release
if: ${{ startsWith(github.ref, 'refs/tags/v') }}
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.GITHUB_TOKEN }}
file: firmware.packed.bin
asset_name: egzumer_$tag.packed.bin
tag: ${{ github.ref }}
overwrite: true
release_name: release ${{ github.ref_name }}