Skip to content

Create Release

Create Release #11

Workflow file for this run

name: Create Release
on:
workflow_dispatch:
inputs:
tag:
description: 'The new version to tag, ex: 1.0.5'
required: true
type: string
prerelease:
default: true
description: Indicator of whether or not this is a prerelease.
type: boolean
jobs:
create-release:
runs-on: ubuntu-latest
steps:
- uses: bazel-contrib/setup-bazel@0.8.5
with:
bazelisk-cache: true
- uses: actions/checkout@v4
with:
fetch-tags: true
- name: Prepare release
run: |-
set -euo pipefail
PREFIX="asc_swift-${{ inputs.tag }}"
ARCHIVE="asc_swift-${{ inputs.tag }}.tar.gz"
git archive --format=tar --prefix="${PREFIX}/" "${{ inputs.tag }}" | gzip > $ARCHIVE
- name: Release
uses: softprops/action-gh-release@v2
with:
tag_name: ${{ inputs.tag }}
files: "asc_swift-*.tar.gz"
fail_on_unmatched_files: true
prerelease: ${{ inputs.prerelease }}
generate_release_notes: true