Upload Binaries #109
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| name: Upload Binaries | |
| on: | |
| workflow_dispatch: | |
| workflow_run: | |
| workflows: [Build Firmware CI] | |
| types: | |
| - completed | |
| jobs: | |
| on-success: | |
| runs-on: ubuntu-latest | |
| if: ${{ github.event.workflow_run.conclusion == 'success' }} | |
| steps: | |
| - name: Checkout gh-pages branch | |
| uses: actions/checkout@v4 | |
| with: | |
| ref: gh-pages | |
| - name: Download hactar binaries | |
| shell: bash | |
| run: | | |
| mkdir -p build/mgmt | |
| mkdir -p build/net | |
| mkdir -p build/ui | |
| gh release download nightly -p 'mgmt.bin' -D build/mgmt --clobber | |
| gh release download nightly -p 'net.bin' -D build/net --clobber | |
| gh release download nightly -p 'bootloader.bin' -D build/net --clobber | |
| gh release download nightly -p 'partition-table.bin' -D build/net --clobber | |
| gh release download nightly -p 'ui.bin' -D build/ui --clobber | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |
| - name: Commit and push binaries | |
| shell: bash | |
| run: | | |
| git config user.name "github-actions[bot]" | |
| git config user.email "github-actions[bot]@users.noreply.github.com" | |
| git add build | |
| git commit -m "Update binaries from Nightly build" || echo "No changes to commit" | |
| git push origin gh-pages |