Skip to content

0.2.0

0.2.0 #8

Workflow file for this run

# Cut a release whenever a new tag is pushed to the repo.
# You should use an annotated tag, like `git tag -a v1.2.3`
# and put the release notes into the commit message for the tag.
name: release
on:
push:
tags:
- "*.*.*"
jobs:
# Attach tarballs to releases with stable release url's
# NB: tag url's aren't guaranteed to be persistent
# See: https://blog.bazel.build/2023/02/15/github-archive-checksum.html
release:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- name: Env Variables
shell: bash
run: |
echo "TAG=${GITHUB_REF_NAME}" >> $GITHUB_ENV
echo "REPO_NAME=${{ github.event.repository.name }}" >> $GITHUB_ENV
echo "ARCHIVE_NAME=${{ github.event.repository.name }}-${GITHUB_REF_NAME}" >> $GITHUB_ENV
- name: Variables
run: |
echo "Repository Name: ${{ github.event.repository.name }}"
echo "GITHUB_REF: ${GITHUB_REF}"
echo "GITUB_REF_NAME: ${GITHUB_REF_NAME}"
echo "ARCHIVE_NAME: ${{ env.ARCHIVE_NAME }}"
- name: Create Release Asset
run: git archive $GITHUB_REF --prefix=${{ env.ARCHIVE_NAME }}/ -o "${{ env.ARCHIVE_NAME }}.tar.gz"
- name: Cut a Release
uses: softprops/action-gh-release@v1
with:
prerelease: false
files: ${{ env.ARCHIVE_NAME }}.tar.gz