Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Version #12

Merged
merged 1 commit into from
Nov 8, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
31 changes: 10 additions & 21 deletions .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -39,30 +39,11 @@ jobs:
echo "::set-output name=yaml_changed::false"
fi

read-version:
name: Read Version from YAML
runs-on: ubuntu-latest
needs: check-for-yaml
if: always()
outputs:
project_version: ${{ steps.read_version.outputs.project_version }}
steps:
- name: Checkout code
uses: actions/checkout@v3

- name: Read version from YAML file
id: read_version
run: |
version=$(awk '/substitutions:/ {found=1} found && /version:/ {print $2; exit}' Integrations/ESPHome/Core.yaml | tr -d '"')
echo "project_version=$version" >> $GITHUB_ENV
shell: bash

build-firmware:
name: Build And Release
uses: esphome/workflows/.github/workflows/build.yml@main
needs:
- check-for-yaml
- read-version
if: needs.check-for-yaml.outputs.yaml_changed == 'true'
with:
files: |
Expand All @@ -78,7 +59,6 @@ jobs:
uses: esphome/workflows/.github/workflows/build.yml@main
needs:
- check-for-yaml
- read-version
if: needs.check-for-yaml.outputs.yaml_changed == 'true'
with:
files: |
Expand All @@ -94,7 +74,6 @@ jobs:
runs-on: ubuntu-latest
needs:
- check-for-yaml
- read-version
- build-firmware
- build-firmware-b
if: needs.check-for-yaml.outputs.yaml_changed == 'true'
Expand Down Expand Up @@ -148,6 +127,16 @@ jobs:
PR_BODY=$(echo "$PR_INFO" | jq -r '.[0].body')
echo "::set-output name=body::$PR_BODY"

- name: Checkout code
uses: actions/checkout@v3

- name: Read version from YAML file
id: read_version
run: |
version=$(awk '/substitutions:/ {found=1} found && /version:/ {print $2; exit}' Integrations/ESPHome/Core.yaml | tr -d '"')
echo "project_version=$version" >> $GITHUB_ENV
shell: bash

# Create GitHub Release using the last PR's body
- name: Create Release
id: create_release
Expand Down
2 changes: 1 addition & 1 deletion Integrations/ESPHome/Core.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
substitutions:
version: "24.11.7.6"
version: "24.11.7.7"

esp32:
board: esp32-c3-devkitm-1
Expand Down
Loading