Skip to content

Commit

Permalink
Merge pull request #190 from huizebruin/dev
Browse files Browse the repository at this point in the history
try again
  • Loading branch information
huizebruin authored Jun 30, 2024
2 parents 42f71c9 + 1c3be9e commit 746232a
Show file tree
Hide file tree
Showing 2 changed files with 22 additions and 39 deletions.
31 changes: 22 additions & 9 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,19 +13,32 @@ jobs:
id-token: write
runs-on: ubuntu-latest
steps:
- name: Get variables
- name: Checkout code
uses: actions/checkout@v4

- name: Get version from tag
id: version
run: echo "::set-output name=version::${GITHUB_REF#refs/tags/}"
run: echo "version=${GITHUB_REF#refs/tags/}" >> $GITHUB_ENV

- uses: actions/checkout@v4
with:
ref: ${{ steps.version.outputs.version }}
- name: Read version from YAML file
id: read_version
run: |
yaml_version=$(grep 'project_version:' esphome/components/basis.yaml | awk '{print $2}' | tr -d '"')
echo "yaml_version=$yaml_version" >> $GITHUB_ENV
- name: Validate version consistency
id: validate_version
run: |
if [ "${yaml_version}" != "${version}" ]; then
echo "Tag version (${version}) does not match project_version (${yaml_version}) in YAML file."
exit 1
fi
- uses: release-drafter/[email protected]
with:
tag: ${{ steps.version.outputs.version }}
name: ${{ steps.version.outputs.version }}
version: ${{ steps.version.outputs.version }}
tag: ${{ env.version }}
name: ${{ env.version }}
version: ${{ env.version }}
publish: true
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
30 changes: 0 additions & 30 deletions .github/workflows/sitemaps.yaml

This file was deleted.

0 comments on commit 746232a

Please sign in to comment.