Skip to content

Merge pull request #87 from commentcov/dependabot/go_modules/github.c… #74

Merge pull request #87 from commentcov/dependabot/go_modules/github.c…

Merge pull request #87 from commentcov/dependabot/go_modules/github.c… #74

Workflow file for this run

name: release
on:
push:
branches:
- main
tags:
- "v[0-9]+.[0-9]+.[0-9]+"
jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: haya14busa/action-bumpr@v1
id: bumpr
if: "!startsWith(github.ref, 'refs/tags/')"
# Get tag name.
- uses: haya14busa/action-cond@v1
id: tag
with:
cond: "${{ startsWith(github.ref, 'refs/tags/') }}"
if_true: ${{ github.ref }}
if_false: ${{ steps.bumpr.outputs.next_version }}
- uses: actions/setup-go@v4
if: "steps.tag.outputs.value != ''"
with:
go-version: "1.18"
- uses: goreleaser/goreleaser-action@v5
if: "steps.tag.outputs.value != ''"
with:
version: latest
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}