From de9ef4c9484184754f46c7eabc071005b4afc9c9 Mon Sep 17 00:00:00 2001 From: Shaun Reed Date: Fri, 14 Mar 2025 16:18:24 -0400 Subject: [PATCH] Add release CI. --- .github/workflows/all-builds.yml | 8 +++++++- .github/workflows/release.yml | 35 ++++++++++++++++++++++++++++++++ 2 files changed, 42 insertions(+), 1 deletion(-) create mode 100644 .github/workflows/release.yml diff --git a/.github/workflows/all-builds.yml b/.github/workflows/all-builds.yml index f69bf72..ea91e61 100644 --- a/.github/workflows/all-builds.yml +++ b/.github/workflows/all-builds.yml @@ -1,10 +1,16 @@ -name: All Builds +name: Build on: push: + branches: + - '*' + # Runs on tag so the release workflow can use its artifact. + tags: + - "v*" pull_request: workflow_dispatch: + env: QT_VERSION: 6.6.0 diff --git a/.github/workflows/release.yml b/.github/workflows/release.yml new file mode 100644 index 0000000..9c4e027 --- /dev/null +++ b/.github/workflows/release.yml @@ -0,0 +1,35 @@ +name: Release + +on: + workflow_run: + workflows: ["Build"] + types: + - completed + +jobs: + release: + runs-on: ubuntu-latest + if: startsWith(github.ref, 'refs/tags/') + steps: + - name: Download Installer Artifact + uses: actions/download-artifact@v4 + with: + name: Qtk Packages + path: | + build/packages/* + install/* + + - name: Create GitHub Release + id: create_release + uses: softprops/action-gh-release@v1 + with: + tag_name: ${{ github.event.workflow_run.head_branch }} + name: Qtk ${{ github.event.workflow_run.head_branch }} + draft: true + prerelease: false + generate_release_notes: true + files: | + build/packages/* + install/* + env: + GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} \ No newline at end of file