Skip to content

Commit

Permalink
Add release.yml
Browse files Browse the repository at this point in the history
  • Loading branch information
bbkane committed Mar 2, 2023
1 parent b9adeed commit 3c15fb4
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 32 deletions.
32 changes: 0 additions & 32 deletions .github/workflows/gorelease.yml

This file was deleted.

38 changes: 38 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,38 @@
name: Release

on:
push:
tags:
- "v[0-9]+.[0-9]+.[0-9]+"
permissions:
contents: write

jobs:
ci:
uses: ./.github/workflows/ci.yml
setup:
name: Release
runs-on: ubuntu-latest
needs: ci
steps:
# https://github.com/marketplace/actions/checkout`
- name: Checkout Repo
uses: actions/checkout@v3

# https://github.com/marketplace/actions/setup-go-environment
- name: Set up Go 1.x >= 1.18
uses: actions/setup-go@v3
with:
go-version-file: go.mod
# requires go.sum file (i.e., external libraries)
cache: true

# https://github.com/marketplace/actions/goreleaser-action
- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v3
with:
version: latest
args: release --rm-dist
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
KEY_GITHUB_GORELEASER_TO_HOMEBREW_TAP: ${{ secrets.KEY_GITHUB_GORELEASER_TO_HOMEBREW_TAP }}

0 comments on commit 3c15fb4

Please sign in to comment.