Skip to content

chore: Add test workflow #132

chore: Add test workflow

chore: Add test workflow #132

Workflow file for this run

name: Release
on:
push:
branches:
- main
workflow_dispatch:
jobs:
release-please:
permissions:
contents: write
pull-requests: write
runs-on: ubuntu-latest
outputs:
releases_created: ${{ steps.r.outputs.releases_created }}
tag_name: ${{ steps.r.outputs.tag_name }}
steps:
- name: Run Release Please
uses: googleapis/release-please-action@7987652d64b4581673a76e33ad5e98e3dd56832f # v4.1.3
id: r
with:
token: ${{ secrets.OKCTL_FINE_GRAINED_TOKEN }}
goreleaser:
needs:
- release-please
if: needs.release-please.outputs.releases_created == 'true'
permissions:
contents: write
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@692973e3d937129bcbf40652eb9f2f61becf3332 # v4.1.7
with:
fetch-depth: 0
- name: Set up Go
uses: actions/setup-go@0a12ed9d6a96ab950c8f026ed9f722fe0da7ef32 # v5.0.2
with:
go-version-file: "go.mod"
cache-dependency-path: "go.sum"
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@286f3b13b1b49da4ac219696163fb8c1c93e1200 # v6.0.0
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}