Skip to content

Update CHANGELOG.md for #54 #3

Update CHANGELOG.md for #54

Update CHANGELOG.md for #54 #3

Workflow file for this run

---
name: 'Release'
on:
push:
tags:
- 'v[0-9]+.[0-9]+.[0-9]+*'
permissions:
contents: write
jobs:
goreleaser:
name: 'Release the latest tag'
runs-on: ubuntu-22.04
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@v5
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
distribution: goreleaser
version: latest
args: release --clean -f ${{ vars.GORELEASER_CONFIG_PATH }}
env:
GITHUB_TOKEN: ${{ secrets.TOFUENV_GITHUB_TOKEN }}
checksums:
name: 'Generate release checksums'
needs: goreleaser
runs-on: ubuntu-22.04
steps:
- name: Download artifacts
run: |
curl -L --output tofuenv-$(echo $TAG | sed s/v//).tar.gz \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer $GITHUB_TOKEN" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://github.com/$GITHUB_REPOSITORY/archive/refs/tags/$TAG.tar.gz
curl -L --output tofuenv-$(echo $TAG | sed s/v//).zip \
-H "Accept: application/vnd.github+json" \
-H "Authorization: Bearer $GITHUB_TOKEN" \
-H "X-GitHub-Api-Version: 2022-11-28" \
https://github.com/$GITHUB_REPOSITORY/archive/refs/tags/$TAG.zip
env:
GITHUB_TOKEN: ${{ secrets.TOFUENV_GITHUB_TOKEN }}
TAG: ${{ github.ref_name }}
- name: Check contents
run: ls -la
- name: Generate checksum
run: |
shasum -a 256 *.tar.gz > checksums_$version.txt
shasum -a 256 *.zip >> checksums_$version.txt
env:
version: ${{ github.ref_name }}
- name: Upload checksum to release
uses: svenstaro/upload-release-action@v2
with:
repo_token: ${{ secrets.TOFUENV_GITHUB_TOKEN }}
file: checksums_${{ github.ref_name }}.txt
tag: ${{ github.ref_name }}