2021-07-29 21:59:25 +01:00
|
|
|
name: Build_firmware_master
|
2020-12-23 16:10:10 +00:00
|
|
|
|
|
|
|
on:
|
2023-05-23 15:55:19 +01:00
|
|
|
workflow_dispatch: # Start a workflow
|
2020-12-23 16:10:10 +00:00
|
|
|
push:
|
|
|
|
branches: master
|
2021-07-29 21:59:25 +01:00
|
|
|
paths-ignore:
|
2022-10-26 14:50:44 +01:00
|
|
|
- '.github/**' # Ignore changes towards the .github directory
|
|
|
|
- '**.md' # Do no build if *.md files changes
|
2020-12-23 16:10:10 +00:00
|
|
|
|
2022-01-18 14:00:24 +00:00
|
|
|
# Ensures that only one deploy task per branch/environment will run at a time.
|
|
|
|
concurrency:
|
|
|
|
group: environment-${{ github.ref }}
|
|
|
|
cancel-in-progress: true
|
|
|
|
|
2020-12-23 16:10:10 +00:00
|
|
|
jobs:
|
2022-10-26 14:50:44 +01:00
|
|
|
safeboot-images:
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
if: github.repository == 'arendst/Tasmota'
|
|
|
|
continue-on-error: true
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
variant:
|
|
|
|
- tasmota32solo1-safeboot
|
|
|
|
- tasmota32-safeboot
|
|
|
|
- tasmota32c3-safeboot
|
|
|
|
- tasmota32c3cdc-safeboot
|
|
|
|
- tasmota32s2-safeboot
|
|
|
|
- tasmota32s2cdc-safeboot
|
|
|
|
- tasmota32s3-safeboot
|
|
|
|
- tasmota32s3cdc-safeboot
|
2023-08-30 17:23:00 +01:00
|
|
|
- tasmota32c2-safeboot
|
|
|
|
- tasmota32c6-safeboot
|
|
|
|
- tasmota32c6cdc-safeboot
|
2022-10-26 14:50:44 +01:00
|
|
|
steps:
|
2024-01-28 18:05:20 +00:00
|
|
|
- uses: actions/checkout@v4
|
2022-10-26 14:50:44 +01:00
|
|
|
with:
|
|
|
|
ref: master
|
|
|
|
- name: Set up Python
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: actions/setup-python@v5
|
2022-10-26 14:50:44 +01:00
|
|
|
with:
|
|
|
|
python-version: '3.x'
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
pip install wheel
|
2023-07-06 14:02:25 +01:00
|
|
|
pip install -U platformio
|
2023-08-30 17:23:00 +01:00
|
|
|
cp ./platformio_tasmota_core3_env_sample.ini ./platformio_tasmota_core3_env.ini
|
2023-11-14 22:44:34 +00:00
|
|
|
cp ./platformio_override_sample.ini ./platformio_override.ini
|
2022-10-26 14:50:44 +01:00
|
|
|
- name: Run PlatformIO
|
|
|
|
run: platformio run -e ${{ matrix.variant }}
|
|
|
|
- name: Upload safeboot firmware artifacts
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: jason2866/upload-artifact@v2.0.3
|
2022-10-26 14:50:44 +01:00
|
|
|
with:
|
|
|
|
name: firmware_safeboot
|
|
|
|
path: ./build_output
|
|
|
|
|
2021-12-12 16:15:43 +00:00
|
|
|
base-images:
|
|
|
|
runs-on: ubuntu-latest
|
2021-12-12 16:21:31 +00:00
|
|
|
if: github.repository == 'arendst/Tasmota'
|
2021-12-12 16:15:43 +00:00
|
|
|
continue-on-error: true
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
variant:
|
|
|
|
- tasmota
|
2023-01-10 16:28:56 +00:00
|
|
|
- tasmota-4M
|
2021-12-12 16:15:43 +00:00
|
|
|
- tasmota-minimal
|
|
|
|
- tasmota-display
|
|
|
|
- tasmota-ir
|
|
|
|
- tasmota-knx
|
|
|
|
- tasmota-lite
|
|
|
|
- tasmota-sensors
|
|
|
|
- tasmota-zbbridge
|
|
|
|
- tasmota-zigbee
|
2022-10-26 14:50:44 +01:00
|
|
|
steps:
|
2024-01-28 18:05:20 +00:00
|
|
|
- uses: actions/checkout@v4
|
2022-10-26 14:50:44 +01:00
|
|
|
with:
|
|
|
|
ref: master
|
|
|
|
- name: Set up Python
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: actions/setup-python@v5
|
2022-10-26 14:50:44 +01:00
|
|
|
with:
|
|
|
|
python-version: '3.x'
|
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
|
|
|
pip install wheel
|
2023-07-06 14:02:25 +01:00
|
|
|
pip install -U platformio
|
2022-10-26 14:50:44 +01:00
|
|
|
- name: Run PlatformIO
|
|
|
|
run: platformio run -e ${{ matrix.variant }}
|
|
|
|
- name: Upload firmware artifacts
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: jason2866/upload-artifact@v2.0.3
|
2022-10-26 14:50:44 +01:00
|
|
|
with:
|
|
|
|
name: firmware
|
|
|
|
path: ./build_output
|
|
|
|
|
|
|
|
base32-images:
|
|
|
|
needs: safeboot-images
|
|
|
|
runs-on: ubuntu-latest
|
|
|
|
if: github.repository == 'arendst/Tasmota'
|
|
|
|
continue-on-error: true
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
variant:
|
2021-12-12 16:15:43 +00:00
|
|
|
- tasmota32
|
2022-06-02 19:44:00 +01:00
|
|
|
- tasmota32-zbbrdgpro
|
2021-12-12 16:15:43 +00:00
|
|
|
- tasmota32-webcam
|
|
|
|
- tasmota32-bluetooth
|
2022-06-02 19:44:00 +01:00
|
|
|
- tasmota32-nspanel
|
2021-12-12 16:15:43 +00:00
|
|
|
- tasmota32-display
|
|
|
|
- tasmota32-ir
|
|
|
|
- tasmota32-lvgl
|
|
|
|
- tasmota32c3
|
2022-06-07 15:37:10 +01:00
|
|
|
- tasmota32c3cdc
|
2022-05-21 14:14:17 +01:00
|
|
|
- tasmota32s2
|
2022-06-07 15:37:10 +01:00
|
|
|
- tasmota32s2cdc
|
2022-05-21 14:14:17 +01:00
|
|
|
- tasmota32s3
|
2022-06-07 15:37:10 +01:00
|
|
|
- tasmota32s3cdc
|
2021-12-12 16:15:43 +00:00
|
|
|
- tasmota32solo1
|
|
|
|
steps:
|
2024-01-28 18:05:20 +00:00
|
|
|
- uses: actions/checkout@v4
|
2021-12-12 22:36:46 +00:00
|
|
|
with:
|
|
|
|
ref: master
|
2021-12-12 16:15:43 +00:00
|
|
|
- name: Set up Python
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: actions/setup-python@v5
|
2022-10-25 10:41:21 +01:00
|
|
|
with:
|
|
|
|
python-version: '3.x'
|
2021-12-12 16:15:43 +00:00
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
2022-09-18 12:32:48 +01:00
|
|
|
pip install wheel
|
2023-07-06 14:02:25 +01:00
|
|
|
pip install -U platformio
|
2022-10-26 14:50:44 +01:00
|
|
|
- name: Download safeboot firmwares
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: jason2866/download-artifact@v3.0.4
|
2022-10-26 14:50:44 +01:00
|
|
|
with:
|
|
|
|
name: firmware_safeboot
|
|
|
|
path: ./firmware
|
|
|
|
- name: Display downloaded files
|
|
|
|
run: |
|
|
|
|
ls -R ./firmware/
|
2021-12-12 16:15:43 +00:00
|
|
|
- name: Run PlatformIO
|
|
|
|
run: platformio run -e ${{ matrix.variant }}
|
2022-10-26 14:50:44 +01:00
|
|
|
- name: Upload firmware artifacts
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: jason2866/upload-artifact@v2.0.3
|
2021-12-12 16:15:43 +00:00
|
|
|
with:
|
|
|
|
name: firmware
|
|
|
|
path: ./build_output
|
|
|
|
|
|
|
|
language-images:
|
2022-10-26 14:50:44 +01:00
|
|
|
needs: safeboot-images
|
2021-12-12 16:15:43 +00:00
|
|
|
runs-on: ubuntu-latest
|
2021-12-12 16:21:31 +00:00
|
|
|
if: github.repository == 'arendst/Tasmota'
|
2021-12-12 16:15:43 +00:00
|
|
|
continue-on-error: true
|
|
|
|
strategy:
|
|
|
|
matrix:
|
|
|
|
variant: [ tasmota, tasmota32 ]
|
2022-08-07 10:33:32 +01:00
|
|
|
language: [ AD, AF, BG, BR, CN, CZ, DE, ES, FR, FY, GR, HE, HU, IT, KO, NL, PL, PT, RO, RU, SE, SK, TR, TW, UK, VN ]
|
2021-12-12 16:15:43 +00:00
|
|
|
steps:
|
2024-01-28 18:05:20 +00:00
|
|
|
- uses: actions/checkout@v4
|
2021-12-12 22:36:46 +00:00
|
|
|
with:
|
|
|
|
ref: master
|
2021-12-12 16:15:43 +00:00
|
|
|
- name: Set up Python
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: actions/setup-python@v5
|
2022-10-25 10:41:21 +01:00
|
|
|
with:
|
|
|
|
python-version: '3.x'
|
2021-12-12 16:15:43 +00:00
|
|
|
- name: Install dependencies
|
|
|
|
run: |
|
2022-09-18 12:32:48 +01:00
|
|
|
pip install wheel
|
2023-07-06 14:02:25 +01:00
|
|
|
pip install -U platformio
|
2022-10-26 14:50:44 +01:00
|
|
|
- name: Download safeboot firmwares
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: jason2866/download-artifact@v3.0.4
|
2022-10-26 14:50:44 +01:00
|
|
|
with:
|
|
|
|
name: firmware_safeboot
|
|
|
|
path: ./firmware
|
|
|
|
- name: Display downloaded files
|
|
|
|
run: |
|
|
|
|
ls -R ./firmware/
|
2021-12-12 16:15:43 +00:00
|
|
|
- name: Run PlatformIO
|
|
|
|
run: platformio run -e ${{ matrix.variant }}-${{ matrix.language }}
|
2022-10-26 14:50:44 +01:00
|
|
|
- name: Upload language firmware artifacts
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: jason2866/upload-artifact@v2.0.3
|
2021-12-12 16:15:43 +00:00
|
|
|
with:
|
|
|
|
name: firmware
|
|
|
|
path: ./build_output
|
2020-12-23 16:10:10 +00:00
|
|
|
|
2023-05-23 15:55:19 +01:00
|
|
|
Release:
|
2022-12-16 11:00:33 +00:00
|
|
|
needs: [base-images, base32-images, language-images]
|
2020-12-23 16:10:10 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
continue-on-error: true
|
|
|
|
steps:
|
2024-01-28 18:05:20 +00:00
|
|
|
- uses: actions/checkout@v4
|
2022-12-14 14:14:14 +00:00
|
|
|
- name: Download Tasmota firmwares
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: jason2866/download-artifact@v3.0.4
|
2020-12-23 16:10:10 +00:00
|
|
|
with:
|
|
|
|
name: firmware
|
|
|
|
path: ./mv_firmware
|
2022-12-14 14:14:14 +00:00
|
|
|
- name: Download safeboot firmwares
|
2024-01-28 18:05:20 +00:00
|
|
|
uses: jason2866/download-artifact@v3.0.4
|
2022-12-14 14:14:14 +00:00
|
|
|
with:
|
|
|
|
name: firmware_safeboot
|
|
|
|
path: ./mv_firmware
|
2020-12-23 16:10:10 +00:00
|
|
|
- name: Display structure of downloaded files
|
2021-05-01 15:21:46 +01:00
|
|
|
run: ls -R ./mv_firmware/
|
2023-05-25 15:05:53 +01:00
|
|
|
- name: Zip all map.gz files in one file -> map_all.zip
|
|
|
|
run: 7z a -mx=9 -tzip -xr'!.*' map_all.zip mv_firmware/map
|
2021-05-01 15:21:46 +01:00
|
|
|
- name: Release
|
2022-11-16 15:43:25 +00:00
|
|
|
uses: jason2866/action-gh-release@v1.2
|
2021-05-01 15:21:46 +01:00
|
|
|
#if: startsWith(github.ref, 'refs/tags/')
|
|
|
|
with:
|
|
|
|
tag_name: ${{ github.run_number }}
|
2023-05-25 15:05:53 +01:00
|
|
|
files: |
|
|
|
|
./mv_firmware/firmware/*
|
|
|
|
map_all.zip
|
2021-05-01 15:21:46 +01:00
|
|
|
env:
|
|
|
|
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
|
2021-07-29 21:59:25 +01:00
|
|
|
|
2021-11-29 10:29:38 +00:00
|
|
|
Start_final_copy:
|
2023-05-23 16:08:21 +01:00
|
|
|
needs: Release
|
2021-11-29 10:29:38 +00:00
|
|
|
runs-on: ubuntu-latest
|
|
|
|
steps:
|
2023-05-23 15:55:19 +01:00
|
|
|
- name: Dispatch workflow in arendst/Tasmota-firmware
|
2021-08-28 15:57:43 +01:00
|
|
|
run: |
|
2023-05-23 15:55:19 +01:00
|
|
|
curl -X POST https://api.github.com/repos/arendst/Tasmota-firmware/actions/workflows/fetch_deploy.yml/dispatches \
|
|
|
|
-H 'Accept: application/vnd.github.everest-preview+json' \
|
|
|
|
-u ${{ secrets.API_TOKEN_GITHUB }} \
|
2023-05-24 18:43:53 +01:00
|
|
|
--data '{"ref": "gh_actions"}'
|