diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml index fe7a3b9c7..7ea57168f 100644 --- a/.github/workflows/release.yml +++ b/.github/workflows/release.yml @@ -8,9 +8,9 @@ on: types: [published] jobs: - release: + release-common: runs-on: ubuntu-latest - name: Release + name: Release Common steps: - name: 🧰 Checkout @@ -110,3 +110,25 @@ jobs: tag: ImHex-v${{env.IMHEX_VERSION}} repo: ImHex-Patterns token: ${{ secrets.RELEASE_TOKEN }} + + release-windows: + name: Release Windows + needs: release-common + runs-on: windows-2022 + steps: + - name: ⬇️ Download dependencies + shell: pwsh + run: | + iwr https://github.com/microsoft/winget-create/releases/download/v1.0.4.0/wingetcreate.exe -OutFile wingetcreate.exe + - name: ⬆️ Update winget manifest + shell: pwsh + env: + WINGET_GITHUB_TOKEN: ${{ secrets.RELEASE_TOKEN }} + run: | + $tagname = $env:GITHUB_REF.Replace("refs/tags/", "") + $version = $tagname.Replace("v", "") + $url = "https://github.com/WerWolv/ImHex/releases/download/${tagname}/imhex-${version}-win64.msi" + .\wingetcreate.exe update WerWolv.ImHex -u $url --version $version + if ($version -notmatch "-") { + .\wingetcreate.exe submit .\manifests\w\WerWolv\ImHex\${version}\ --token $env:WINGET_GITHUB_TOKEN + } \ No newline at end of file diff --git a/cmake/build_helpers.cmake b/cmake/build_helpers.cmake index 2a3138882..e46ffa5e7 100644 --- a/cmake/build_helpers.cmake +++ b/cmake/build_helpers.cmake @@ -133,7 +133,7 @@ macro(configurePackingResources) if (CREATE_PACKAGE) set(CPACK_GENERATOR "WIX") - set(CPACK_PACKAGE_NAME "ImHex") + set(CPACK_PACKAGE_NAME "imhex") set(CPACK_PACKAGE_VENDOR "WerWolv") set(CPACK_WIX_UPGRADE_GUID "05000E99-9659-42FD-A1CF-05C554B39285") set(CPACK_WIX_PRODUCT_ICON "${PROJECT_SOURCE_DIR}/resources/dist/windows/icon.ico")