Release #15
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Release | |
on: | |
release: | |
permissions: | |
contents: write | |
jobs: | |
hacs: | |
name: HACS Action | |
runs-on: "ubuntu-latest" | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Get tag from commit summary | |
run: | | |
echo "tag=$(git describe --tags --abbrev=0)" >> $GITHUB_ENV | |
- name: Set version to release tag | |
run: | | |
sed -i "s/GITHUB_RELEASE_VERSION/${{ env.tag }}/g" custom_components/ankermake/manifest.json | |
sed -i "s/GITHUB_RELEASE_VERSION/${{ env.tag }}/g" custom_components/ankermake/const.py | |
- name: Zip custom_components/ankermake | |
run: zip -r ankermake.zip custom_components/ankermake | |
- name: Upload release asset to the existing release | |
uses: shogo82148/actions-upload-release-asset@v1 | |
with: | |
upload_url: ${{ github.event.release.upload_url }} | |
asset_path: ankermake.zip | |
asset_name: ankermake.zip | |
asset_content_type: application/zip | |
overwrite: true |