Skip to content

0.8.83 release

0.8.83 release #20

name: Ahoy Release
on:
push:
branches: main
paths-ignore:
- '**.md' # Do no build on *.md changes
jobs:
build:
name: Build Environments
runs-on: ubuntu-latest
if: github.repository == 'lumapu/ahoy' && github.ref_name == 'main'
continue-on-error: false
strategy:
matrix:
variant:
- esp8266
- esp8266-prometheus
- esp8285
- esp32-wroom32
- esp32-wroom32-prometheus
- esp32-wroom32-ethernet
- esp32-s2-mini
- esp32-c3-mini
- opendtufusion
- opendtufusion-ethernet
- esp8266-de
- esp8266-prometheus-de
- esp8285-de
- esp32-wroom32-de
- esp32-wroom32-prometheus-de
- esp32-wroom32-ethernet-de
- esp32-s2-mini-de
- esp32-c3-mini-de
- opendtufusion-de
- opendtufusion-ethernet-de
steps:
- uses: actions/checkout@v4
- uses: benjlevesque/[email protected]
id: short-sha
with:
length: 7
- name: Cache Pip
uses: actions/cache@v4
with:
path: ~/.cache/pip
key: ${{ runner.os }}-pip-${{ hashFiles('**/requirements.txt') }}
restore-keys: |
${{ runner.os }}-pip-
- name: Cache PlatformIO
uses: actions/cache@v4
with:
path: ~/.platformio
key: ${{ runner.os }}-${{ hashFiles('**/lockfiles') }}
- name: Setup Python
uses: actions/setup-python@v5
with:
python-version: "3.x"
- name: Install PlatformIO
run: |
python -m pip install setuptools --upgrade pip
pip install --upgrade platformio
- name: Run PlatformIO
run: pio run -d src -e ${{ matrix.variant }}
- name: Rename Firmware
run: python scripts/getVersion.py ${{ matrix.variant }} >> $GITHUB_OUTPUT
- name: Create Artifact
uses: actions/upload-artifact@v4
with:
name: ${{ matrix.variant }}
path: firmware/*
release:
name: Create Release
runs-on: ubuntu-latest
needs: [build]
continue-on-error: false
permissions:
contents: write
steps:
- uses: actions/checkout@v4
- name: Get Artifacts
uses: actions/download-artifact@v4
with:
merge-multiple: true
path: firmware
- name: Get Version from code
id: version_name
run: python scripts/getVersion.py ${{ matrix.variant }} >> $GITHUB_OUTPUT
- name: Create tag
uses: actions/github-script@v7
with:
script: |
github.rest.git.createRef({
owner: context.repo.owner,
repo: context.repo.repo,
ref: 'refs/tags/${{ steps.version_name.outputs.name }}',
sha: context.sha
})
- name: Set Version
uses: cschleiden/replace-tokens@v1
with:
files: manual/User_Manual.md
env:
VERSION: ${{ steps.version_name.outputs.name }}
- name: Rename firmware directory
run: mv firmware ${{ steps.version_name.outputs.name }}
- name: Rename firmware directory
uses: vimtor/[email protected]
with:

Check failure on line 125 in .github/workflows/compile_release.yml

View workflow run for this annotation

GitHub Actions / .github/workflows/compile_release.yml

Invalid workflow file

You have an error in your yaml syntax on line 125
files: ${{ steps.version_name.outputs.name }} manual/User_Manual.md manual/Getting_Started.md
dest: '${{ steps.version_name.outputs.name }}.zip'
- name: Publish Release
uses: ncipollo/release-action@v1
with:
artifactErrorsFailBuild: true
skipIfReleaseExists: true
bodyFile: src/CHANGES.md
artifacts: '${{ steps.version_name.outputs.name }}.zip'
tag: ${{ steps.version_name.outputs.name }}
name: ${{ steps.version_name.outputs.name }}
token: ${{ secrets.GITHUB_TOKEN }}
deploy:
name: Deploy Environments to fw.ahoydtu.de
needs: [build, release]
runs-on: ubuntu-latest
continue-on-error: false
steps:
- uses: actions/checkout@v4
- name: Get Artifacts
uses: actions/download-artifact@v4
with:
merge-multiple: true
path: firmware
- name: Get Version from code
id: version_name
run: python scripts/getVersion.py ${{ matrix.variant }} >> $GITHUB_OUTPUT
- name: Set Version
uses: cschleiden/replace-tokens@v1
with:
files: manual/User_Manual.md
env:
VERSION: ${{ steps.version_name.outputs.name }}
- name: Rename firmware directory
run: mv firmware ${{ steps.version_name.outputs.name }}
- name: Deploy
uses: nogsantos/scp-deploy@master
with:
src: ${{ steps.version_name.outputs.name }}/
host: ${{ secrets.FW_SSH_HOST }}
remote: ${{ secrets.FW_SSH_DIR }}/release
port: ${{ secrets.FW_SSH_PORT }}
user: ${{ secrets.FW_SSH_USER }}
key: ${{ secrets.FW_SSH_KEY }}