Build and Upload Commitify Installer #9
This file contains hidden or 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
| # .github/workflows/installer.yml | |
| name: Build and Upload Commitify Installer | |
| on: | |
| workflow_run: | |
| workflows: ["Build Executables"] # Must match the 'name:' in main.yml | |
| types: | |
| - completed | |
| workflow_dispatch: | |
| jobs: | |
| build-installer: | |
| runs-on: windows-latest | |
| steps: | |
| - name: Checkout repository | |
| uses: actions/checkout@v4 | |
| - name: Download commitify.exe from release | |
| uses: robinraju/release-downloader@v1.8 | |
| with: | |
| latest: true | |
| fileName: commitify.exe | |
| out-file-path: CommitifyInstaller | |
| - name: Compile Inno Setup Installer | |
| uses: Minionguyjpro/Inno-Setup-Action@v1.2.2 | |
| with: | |
| path: Commitify.iss | |
| - name: Get latest release tag | |
| id: get_latest_tag | |
| uses: actions/github-script@v7 | |
| with: | |
| script: | | |
| const latest = await github.rest.repos.getLatestRelease({ | |
| owner: context.repo.owner, | |
| repo: context.repo.repo | |
| }); | |
| return latest.data.tag_name; | |
| - name: Upload installer to latest release | |
| uses: softprops/action-gh-release@v2 | |
| with: | |
| files: output/CommitifyInstaller.exe | |
| tag_name: ${{ steps.get_latest_tag.outputs.result }} | |
| env: | |
| GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | |