Skip to content

Commit

Permalink
Publish releases
Browse files Browse the repository at this point in the history
Signed-off-by: or-shachar <[email protected]>
  • Loading branch information
or-shachar committed Nov 16, 2023
1 parent ef6c7b1 commit 3f2e8e1
Show file tree
Hide file tree
Showing 2 changed files with 53 additions and 0 deletions.
26 changes: 26 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,26 @@
name: goreleaser

on:
push:
tags:
- '*'

jobs:
goreleaser:
runs-on: ubuntu-latest
steps:
- name: Checkout
uses: actions/checkout@v4

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

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v5
with:
version: latest
args: release --clean
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
27 changes: 27 additions & 0 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
builds:
- binary: go-cacher
main: ./cmd/go-cacher
goos:
- darwin
- linux
goarch:
- amd64
- arm64
goarm:
- '6'
env:
- CGO_ENABLED=0
mod_timestamp: '{{ .CommitTimestamp }}'
flags:
- -trimpath
ldflags:
- -s -w # Don't set main.version.

archives:
- name_template: "{{.Binary}}_{{.Os}}_{{.Arch}}"
files:
- README.md
- LICENSE

checksum:
name_template: "go-tool-cache_checksums.txt"

0 comments on commit 3f2e8e1

Please sign in to comment.