Skip to content

Commit

Permalink
CI: goreleaser
Browse files Browse the repository at this point in the history
  • Loading branch information
NotAShelf committed Oct 27, 2023
1 parent cf7d1eb commit e48903d
Showing 1 changed file with 38 additions and 0 deletions.
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: Go Build & Release CI

on:
workflow_dispatch:
push:
tags:
- "v*"
pull_request:
branch: dev

permissions:
contents: write

jobs:
build:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4
with:
fetch-depth: 0
- run: git fetch --force --tags

- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: "1.21.x"
cache: true

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v2
if: success() && startsWith(github.ref, 'refs/tags/')
with:
distribution: goreleaser
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{secrets.GITHUB_TOKEN}}

0 comments on commit e48903d

Please sign in to comment.