[ci] Update actions to node 20 versions #125
Workflow file for this run
This file contains 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: PlatformIO CI | |
on: [pull_request, push] | |
defaults: | |
run: | |
working-directory: ./ | |
jobs: | |
build: | |
runs-on: ubuntu-latest | |
steps: | |
- uses: actions/checkout@v4 | |
- name: Set FIRMWARE_VERSION variable | |
run: | | |
FIRMWARE_VER=$(cat VERSION) | |
echo "FIRMWARE_VERSION=$FIRMWARE_VER" >> $GITHUB_ENV | |
- name: Set FIRMWARE_COMMIT_HASH variable | |
run: echo "FIRMWARE_COMMIT_SHA=$(git rev-parse --short "$GITHUB_SHA")" >> "$GITHUB_ENV" | |
- name: Set up Python | |
uses: actions/setup-python@v5 | |
with: | |
python-version: 3.8 | |
- name: Install dependencies | |
run: | | |
python -m pip install --upgrade pip | |
pip install platformio | |
- name: Build | |
run: pio run | |
- name: Rename firmware | |
run: mv .pio/build/rpipicow/firmware.uf2 .pio/build/rpipicow/xrp-wpilib-firmware-${{ env.FIRMWARE_VERSION }}-${{ env.FIRMWARE_COMMIT_SHA }}.uf2 | |
- uses: actions/upload-artifact@v4 | |
with: | |
name: xrp-wpilib-firmware-${{ env.FIRMWARE_VERSION }}-${{ env.FIRMWARE_COMMIT_SHA }} | |
path: .pio/build/rpipicow/xrp-wpilib-firmware-*.uf2 |