Skip to content

change directory for firmware build. #18

change directory for firmware build.

change directory for firmware build. #18

Workflow file for this run

name: CI
on:
# Triggers the workflow on push or pull request events but only for the master branch
push:
branches: [master]
tags: ["v*.*.*"]
pull_request:
branches: [master]
# Allows you to run this workflow manually from the Actions tab
workflow_dispatch:
jobs:
build:
runs-on: ubuntu-latest
steps:
# Checks-out your repository under $GITHUB_WORKSPACE, so your job can access it
- uses: actions/checkout@v2
# ensure we have the python version required for Platform IO.
- uses: actions/setup-python@v4
with:
python-version: "3.11"
# for CI builds. edit version.h to contain the branch name
- name: write version.h
run: |
export BRANCH_OR_TAG=${GITHUB_REF#refs/*/}
echo BRANCH_OR_TAG
echo "#define VERSION \"${BRANCH_OR_TAG}\"" > version.h
cat version.h
- name: Install PlatformIO Core
run: pip install --upgrade platformio
- name: Build PlatformIO Project
run: |
cd firmware
pio run
# # publish tags as releases.
# - name: Release
# uses: softprops/action-gh-release@v1
# if: startsWith(github.ref, 'refs/tags/')
# with:
# files: output/*