Bump goreleaser/goreleaser-action from 5.1.0 to 6.0.0 #61
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# SPDX-FileCopyrightText: 2024 Shun Sakai | |
# | |
# SPDX-License-Identifier: GPL-3.0-or-later | |
name: CD | |
on: | |
pull_request: | |
push: | |
branches: | |
- "develop" | |
tags: | |
- "v[0-9]+.[0-9]+.[0-9]+" | |
permissions: | |
contents: write | |
jobs: | |
release: | |
name: Release | |
runs-on: ubuntu-22.04 | |
steps: | |
- name: Checkout code | |
uses: actions/checkout@v4 | |
with: | |
fetch-depth: 0 | |
- name: Setup Go environment | |
uses: actions/setup-go@v5 | |
with: | |
go-version: "stable" | |
- name: Setup Ruby | |
uses: ruby/setup-ruby@v1 | |
with: | |
ruby-version: 3.2 | |
- name: Install Asciidoctor | |
run: | | |
gem install asciidoctor | |
asciidoctor -V | |
- name: Check `.goreleaser.yaml` | |
uses: goreleaser/goreleaser-action@v6.0.0 | |
with: | |
distribution: "goreleaser" | |
version: "latest" | |
args: check | |
- name: Check GoReleaser | |
uses: goreleaser/goreleaser-action@v6.0.0 | |
if: ${{ !startsWith(github.ref, 'refs/tags/') }} | |
with: | |
distribution: "goreleaser" | |
version: "latest" | |
args: release --clean --snapshot | |
- name: Run GoReleaser | |
uses: goreleaser/goreleaser-action@v6.0.0 | |
if: startsWith(github.ref, 'refs/tags/') | |
with: | |
distribution: "goreleaser" | |
version: "latest" | |
args: release --clean | |
env: | |
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} |