Skip to content

build: goreleaser modernising #12

build: goreleaser modernising

build: goreleaser modernising #12

Workflow file for this run

name: goreleaser
on:
push:
tags: ['v*']
permissions:
contents: write
id-token: write
packages: write
jobs:
release:
name: Update GitHub release
runs-on: ubuntu-latest
env:
flags: ""
steps:
- if: ${{ startsWith(github.ref, 'refs/tags/v') && contains(github.ref, '-rc') }}
run: echo "flags=-f .goreleaser.rc.yml" >> $GITHUB_ENV
- name: Checkout code
uses: actions/checkout@v2
- uses: actions/setup-go@v4
with:
go-version: "1.20"
- uses: goreleaser/goreleaser-action@v4
with:
distribution: goreleaser
version: latest
args: release ${{ env.flags }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}