Skip to content

Commit

Permalink
Add firmware-stock job
Browse files Browse the repository at this point in the history
  • Loading branch information
Apehaenger committed Nov 1, 2023
1 parent 98bdcc0 commit 719a910
Show file tree
Hide file tree
Showing 2 changed files with 50 additions and 62 deletions.
52 changes: 50 additions & 2 deletions .github/workflows/ci.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -41,6 +41,44 @@ jobs:
name: open-mower-pico-firmware
path: artifacts/

firmware-stock:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: actions/cache@v3
with:
path: |
~/.cache/pip
~/.platformio/.cache
key: ${{ runner.os }}-pio
- uses: actions/setup-python@v4
with:
python-version: '3.9'
- name: Install PlatformIO Core
run: pip install --upgrade platformio

- name: Run PlatformIO
run: pio run -d Firmware/CoverUI --environment YF_C500_STM32 --environment YF_C500_GD32

- name: Copy Artifacts
run: |
mkdir artifacts
cp Firmware/CoverUI/.pio/build/YF_C500_STM32/firmware.bin ./artifacts/firmware_C500_STM32.bin
cp Firmware/CoverUI/.pio/build/YF_C500_STM32_RAIN/firmware.bin ./artifacts/firmware_C500_STM32_RAIN.bin
cp Firmware/CoverUI/.pio/build/YF_C500_STM32_RAIN_HALL/firmware.bin ./artifacts/firmware_C500_STM32_RAIN_HALL.bin
cp Firmware/CoverUI/.pio/build/YF_C500_STM32_HALL/firmware.bin ./artifacts/firmware_C500_STM32_HALL.bin
cp Firmware/CoverUI/.pio/build/YF_C500_GD32/firmware.bin ./artifacts/firmware_C500_GD32.bin
cp Firmware/CoverUI/.pio/build/YF_C500_GD32_RAIN/firmware.bin ./artifacts/firmware_C500_GD32_RAIN.bin
cp Firmware/CoverUI/.pio/build/YF_C500_GD32_RAIN_HALL/firmware.bin ./artifacts/firmware_C500_GD32_RAIN_HALL.bin
cp Firmware/CoverUI/.pio/build/YF_C500_GD32_HALL/firmware.bin ./artifacts/firmware_C500_GD32_HALL.bin
cp Firmware/CoverUI/.pio/build/YF_RM-ECOW-V100_STM32/firmware.bin ./artifacts/firmware_RM-ECOW-V100_STM32.bin
cp Firmware/CoverUI/.pio/build/YF_RM-ECOW-V100_STM32_STOP/firmware.bin ./artifacts/firmware_RM-ECOW-V100_STM32_STOP.bin
- name: Step 3 - Use the Upload Artifact GitHub Action
uses: actions/upload-artifact@v3
with:
name: open-mower-stock-firmware
path: artifacts/

tagged-release:
runs-on: ubuntu-latest
Expand Down Expand Up @@ -97,7 +135,7 @@ jobs:
pre-release-latest-firmware:
runs-on: ubuntu-latest
if: github.ref_type != 'tag'
needs: firmware
needs: [firmware, firmware-stock]
steps:
- uses: actions/checkout@v3
with:
Expand All @@ -111,10 +149,20 @@ jobs:
- name: Create firmware zip
run: zip -r firmware.zip firmware

- uses: actions/download-artifact@v3
with:
name: open-mower-stock-firmware
path: firmware

- name: Create stock firmware zip
run: zip -r firmware-stock.zip firmware

- uses: "marvinpinto/action-automatic-releases@latest"
with:
repo_token: "${{ secrets.GITHUB_TOKEN }}"
title: "Latest Firmware"
automatic_release_tag: "latest"
prerelease: true
files: firmware.zip
files: |
firmware.zip
firmware-stock.zip
60 changes: 0 additions & 60 deletions .github/workflows/yardforce.yaml

This file was deleted.

0 comments on commit 719a910

Please sign in to comment.