-
Notifications
You must be signed in to change notification settings - Fork 0
52 lines (50 loc) · 1.64 KB
/
release-firmware.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
---
name: Release Firmware
on:
workflow_dispatch:
inputs:
bump:
type: choice
default: "patch"
required: true
description: "The type of semantic version increment to make."
options:
- patch
- minor
- major
jobs:
update-version-strings:
name: Update Version Strings
runs-on: ubuntu-latest
steps:
- name: Generate Release Version
id: generate_release_version
uses: zwaldowski/semver-release-action@v3
with:
bump: ${{ inputs.bump }}
github_token: ${{ secrets.GITHUB_TOKEN }}
prefix: "v"
dry_run: true
- uses: actions/checkout@v4
with:
token: ${{ secrets.GITHUBACTION }}
- name: Update Project Version String
uses: mikefarah/yq@v4
with:
cmd: >
yq -i
'
.esphome.project.version = "${{ steps.generate_release_version.outputs.version_tag }}"
'
econet_base.yaml
- name: Commit Changes
uses: stefanzweifel/git-auto-commit-action@v5
with:
commit_message: "Automated project versioning update"
push_options: '--force'
- name: Create Release
uses: ncipollo/release-action@v1
with:
generateReleaseNotes: true
tag: ${{ steps.generate_release_version.outputs.version_tag }}
token: ${{ secrets.GITHUBACTION }}