Skip to content
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
14 changes: 12 additions & 2 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,13 @@ name: Release
on:
push:
tags: ["v*"]
workflow_dispatch: {}
# Manual runs create the tag + release themselves (used by environments that
# can build PRs but cannot push tags). The version must match Cargo.toml.
workflow_dispatch:
inputs:
tag:
description: "Release tag to create (e.g. v0.2.0)"
required: true

permissions:
contents: write
Expand Down Expand Up @@ -39,7 +45,11 @@ jobs:
run: tar -C target/${{ matrix.target }}/release -czf tuiui-${{ matrix.target }}.tar.gz tuiui

- name: Attach to release
if: startsWith(github.ref, 'refs/tags/')
if: startsWith(github.ref, 'refs/tags/') || github.event_name == 'workflow_dispatch'
uses: softprops/action-gh-release@v2
with:
# On dispatch this creates the tag (at the run's commit) and the
# release; on a tag push it attaches to the existing tag's release.
tag_name: ${{ github.event.inputs.tag || github.ref_name }}
body: "See CHANGELOG.md for the full release notes."
files: tuiui-${{ matrix.target }}.tar.gz
Loading