From 593842144a437d08f7bb0a0224a0f749570900cc Mon Sep 17 00:00:00 2001 From: Andre Basche Date: Wed, 12 Apr 2023 23:59:09 +0200 Subject: [PATCH] Add zip release for download count --- .github/workflows/release.yml | 25 +++++++++++++++++++++++++ hacs.json | 4 +++- 2 files changed, 28 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..584696c --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,25 @@ +name: Release + +on: + release: + types: [published] + +jobs: + release-zip: + runs-on: ubuntu-latest + steps: + - uses: actions/checkout@v2 + + - name: ZIP Component Dir + run: | + cd ${{ github.workspace }}/custom_components/hon + zip -r haier_hon.zip ./ + + - name: Upload zip to release + uses: svenstaro/upload-release-action@v2 + with: + repo_token: ${{ secrets.GITHUB_TOKEN }} + file: ${{ github.workspace }}/custom_components/hon/haier_hon.zip + asset_name: haier_hon.zip + tag: ${{ github.ref }} + overwrite: true \ No newline at end of file diff --git a/hacs.json b/hacs.json index 85b5cbe..c9f8fc1 100644 --- a/hacs.json +++ b/hacs.json @@ -1,4 +1,6 @@ { "name": "Haier hOn", - "homeassistant": "2023.2.0" + "homeassistant": "2023.2.0", + "zip_release": true, + "filename": "haier_hon.zip" }