fix: Update version string to v1.20.1-dev and enhance packaging of fi… #23
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: Build | |
| on: | |
| push: | |
| branches: [ master, main, develop ] | |
| pull_request: | |
| branches: [ master, main, develop ] | |
| workflow_dispatch: | |
| jobs: | |
| build: | |
| runs-on: ubuntu-latest | |
| timeout-minutes: 20 | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Set up Python | |
| uses: actions/setup-python@v5 | |
| with: | |
| python-version: '3.11' | |
| - name: Cache PlatformIO | |
| uses: actions/cache@v4 | |
| with: | |
| path: | | |
| ~/.platformio | |
| .pio | |
| key: ${{ runner.os }}-pio-${{ hashFiles('platformio.ini') }} | |
| restore-keys: | | |
| ${{ runner.os }}-pio- | |
| - name: Install PlatformIO | |
| run: | | |
| python -m pip install --upgrade pip | |
| pip install platformio | |
| - name: Set up Node | |
| uses: actions/setup-node@v4 | |
| with: | |
| node-version: '20' | |
| - name: Prepare default config | |
| run: | | |
| bash tools/prepare_config.sh | |
| - name: Build web assets | |
| run: | | |
| cd web | |
| npm install | |
| npm run build | |
| cd .. | |
| python scripts/web_to_header.py web/dist -o lib/WebService/generated/web_files.h | |
| - name: Build firmware | |
| run: | | |
| pio run -e geiger | |
| - name: Firmware size | |
| run: | | |
| pio run -e geiger -t size | |
| - name: Upload build artifacts | |
| uses: actions/upload-artifact@v4 | |
| with: | |
| name: firmware-geiger-${{ github.sha }} | |
| path: | | |
| .pio/build/geiger/firmware.bin | |
| .pio/build/geiger/firmware.elf |