Skip to content

Commit

Permalink
ci: debug
Browse files Browse the repository at this point in the history
  • Loading branch information
felixerdy committed May 31, 2024
1 parent 3bf0dfa commit e800bd1
Showing 1 changed file with 31 additions and 35 deletions.
66 changes: 31 additions & 35 deletions .github/workflows/compile-sketches.yml
Original file line number Diff line number Diff line change
Expand Up @@ -19,14 +19,14 @@ jobs:
matrix:
board:
# senseBox MCU
# - fqbn: sensebox:samd:sb:power=on
# platforms: |
# - name: arduino:samd
# - name: sensebox:samd
# source-url: https://raw.githubusercontent.com/mariopesch/senseBoxMCU-core/master/package_sensebox_index.json
# sketch-paths: |
# - ./senseBox-bike
# artifact-name-suffix: sensebox.samd.sb
- fqbn: sensebox:samd:sb:power=on
platforms: |
- name: arduino:samd
- name: sensebox:samd
source-url: https://raw.githubusercontent.com/mariopesch/senseBoxMCU-core/master/package_sensebox_index.json
sketch-paths: |
- ./senseBox-bike
artifact-name-suffix: sensebox.samd.sb
# senseBox MCU S2 (ESP32)
- fqbn: esp32:esp32:sensebox_mcu_esp32s2
platforms: |
Expand Down Expand Up @@ -91,37 +91,33 @@ jobs:
echo "Processing sketch path: $sketch_path"
# replace ./ with nothing
clean_sketch_path=${sketch_path//.\//}
# DEBUG sketch_path
ls -lah ${{ github.workspace }}
ls -lah ${{ github.workspace }}/$sketch_path/build/${{ matrix.board.artifact-name-suffix}}
python3 lzss.py --encode ${{ github.workspace }}/$sketch_path/build/${{ matrix.board.artifact-name-suffix}}/$clean_sketch_path.ino.bin ${{ runner.temp }}/$clean_sketch_path.ino.lzss
ls -lah ${{ runner.temp }}
echo "LZSS file created: ${{ runner.temp }}/$clean_sketch_path.ino.lzss"
ls -lah ${{ runner.temp }}
python3 bin2ota.py ESP ${{ runner.temp }}/$clean_sketch_path.ino.lzss ${{ runner.temp }}/$clean_sketch_path.ino.ota
python3 bin2ota.py ESP32 ${{ runner.temp }}/$clean_sketch_path.ino.lzss ${{ runner.temp }}/$clean_sketch_path.ino.ota
echo "OTA file created: ${{ runner.temp }}/$clean_sketch_path.ino.ota"
mv ${{ runner.temp }}/$clean_sketch_path.ino.ota ${{ github.workspace }}/$sketch_path/build/${{ matrix.board.artifact-name-suffix}}/$clean_sketch_path.ino.ota
fi
done
# - name: Export binaries as artifacts
# uses: actions/upload-artifact@v4
# with:
# name: ${{ matrix.board.artifact-name-suffix }}
# path: ${{ github.workspace }}
- name: Export binaries as artifacts
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.board.artifact-name-suffix }}
path: ${{ github.workspace }}

# release:
# needs: compile-sketches
# runs-on: ubuntu-latest
# steps:
# - name: Download Firmware Files
# uses: actions/download-artifact@v4
# with:
# path: release
# - name: Release Firmware
# uses: ncipollo/release-action@v1
# if: startsWith(github.ref, 'refs/tags/')
# with:
# artifacts: release/**/*.bin
# allowUpdates: true
# omitBodyDuringUpdate: true
# token: ${{ secrets.GITHUB_TOKEN }}
release:
needs: compile-sketches
runs-on: ubuntu-latest
steps:
- name: Download Firmware Files
uses: actions/download-artifact@v4
with:
path: release
- name: Release Firmware
uses: ncipollo/release-action@v1
if: startsWith(github.ref, 'refs/tags/')
with:
artifacts: "release/**/*.bin, release/**/*.ota"
allowUpdates: true
omitBodyDuringUpdate: true
token: ${{ secrets.GITHUB_TOKEN }}

0 comments on commit e800bd1

Please sign in to comment.