Skip to content

chore(deps): bump goreleaser/goreleaser-action from 5.1.0 to 6.0.0 #39

chore(deps): bump goreleaser/goreleaser-action from 5.1.0 to 6.0.0

chore(deps): bump goreleaser/goreleaser-action from 5.1.0 to 6.0.0 #39

Workflow file for this run

name: GoReleaser
on:
push:
branches: [ main ]
tags: [ 'v*.*.*' ]
pull_request:
branches: [ main ]
permissions:
contents: write
jobs:
release:
strategy:
matrix:
os: [ubuntu-latest]
runs-on: ${{ matrix.os }}
steps:
- name: Checkout repository
uses: actions/checkout@v4
with:
fetch-depth: 0 # It is required for GoReleaser to work properly.
# This is needed if you use fields like TagBody, TagSubject or
# TagContents in your templates.
- name: Fetch all tags
run: git fetch --force --tags
- name: Set up Go
uses: actions/setup-go@v5
with:
# Getting go version from the go.mod file
go-version-file: 'go.mod'
- run: go version
# Sanity check before publishing
- name: Test all
run: go test -v ./...
- name: Set goreleaser snapshot env
run: if [[ $GITHUB_REF != refs/tags/v* ]]; then echo "goreleaser_snapshot=--snapshot"; fi >> $GITHUB_ENV
- name: Read variables
run: |
echo "goreleaser_snapshot=${{ env.goreleaser_snapshot }}"
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@286f3b13b1b49da4ac219696163fb8c1c93e1200 # V6.0.0
with:
distribution: goreleaser
version: latest
args: release --clean ${{ env.goreleaser_snapshot }}
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}