diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index ba4c505..9bd3b01 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -54,13 +54,24 @@ jobs: - name: Archive OTA ESP32 run: | - find .pio/build -name "firmware.bin" -exec sh -c 'cp ~/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin "artifacts/0xe000_boot_$(basename $(dirname {})).bin"' \; + declare -A board_map=( + ["esp32"]="0xe000_boot" + ["esp32-s2"]="0xe000_boot" + ["esp32-s3"]="0xe000_boot" + ["lilygo-t-display-s3"]="0xe000_boot" + ) + for board in "${!board_map[@]}"; do + if [ ! -d ".pio/build/$board" ]; then + continue + fi + find .pio/build/$board -name "firmware.bin" -exec sh -c 'cp ~/.platformio/packages/framework-arduinoespressif32/tools/partitions/boot_app0.bin "artifacts/'"${board_map[$board]}_$(basename $(dirname {})).bin"'"' \; + rm -rf .pio/build/$board + done working-directory: ${{ github.workspace }} - name: Archive Artifacts with Address run: | - # Define the mapping of board names to file prefixes declare -A board_map=( ["esp8266"]="0x0000_firmware" ["geekmagic-smalltv"]="0x0000_firmware"