Release workflow runs for a chosen tag

This commit is contained in:
ZacharyZhang-NY committed 2026-10-08 22:23:14 -04:00
1 parent 98d7e75fca
commit 570671abc3
1 file changed
+8 -5
+8 -5
View File
@@ -1,10 +1,12 @@
# On a version tag: macOS apps attached to its release.
# Builds macOS apps for a release tag and attaches them.
name: release
on:
push:
tags: ["v*"]
workflow_dispatch:
inputs:
tag:
description: Release tag to attach the packages to, such as v0.1.0
required: true
permissions:
contents: write
@@ -25,6 +27,8 @@ jobs:
GH_TOKEN: ${{ github.token }}
steps:
- uses: actions/checkout@v4
with:
ref: ${{ inputs.tag }}
- name: Engines
run: |
brew install zstd
@@ -45,9 +49,8 @@ jobs:
- name: Packages
run: packaging/macos/release.sh 1
- name: Attach to the release
if: startsWith(github.ref, 'refs/tags/')
run: |
version=${GITHUB_REF_NAME}
version=${{ inputs.tag }}
gh release view "$version" >/dev/null 2>&1 || gh release create "$version" --title "Ely Office $version" --notes "Built by release.yml."
gh release upload "$version" dist/*.dmg --clobber
if [ "${{ matrix.arch }}" = arm64 ]; then