Skip to content

Commit

Permalink
use the same goreleaser config as for my other projects
Browse files Browse the repository at this point in the history
  • Loading branch information
xrstf committed Oct 25, 2023
1 parent d4b42db commit eac4048
Show file tree
Hide file tree
Showing 2 changed files with 18 additions and 8 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/release.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,7 +30,7 @@ jobs:
- name: Set up Go
uses: actions/setup-go@v4
with:
go-version: '1.21.0'
go-version: '1.21.3'

- name: Run GoReleaser
uses: goreleaser/goreleaser-action@v4
Expand Down
24 changes: 17 additions & 7 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
@@ -1,3 +1,6 @@
# SPDX-FileCopyrightText: 2023 Christoph Mewes
# SPDX-License-Identifier: MIT

builds:
- env:
# goreleaser does not work with CGO, it could also complicate
Expand All @@ -8,24 +11,31 @@ builds:
flags:
- -trimpath
ldflags:
- '-s -w -X main.Tag={{.Version}} -X main.Commit={{.Commit}}'
- '-s -w -X main.BuildTag={{.Version}} -X main.BuildCommit={{.Commit}} -X main.BuildDate={{.Date}}'
goos:
- darwin
- freebsd
- windows
- linux
- darwin
- windows
goarch:
- amd64
- '386'
- arm
- arm64
ignore:
- goos: darwin
goarch: '386'
- goos: freebsd
goarch: '386'
- goos: windows
goarch: '386'
binary: '{{ .ProjectName }}'
archives:
- format: zip
- format: tar.gz
name_template: '{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}'
wrap_in_directory: true
strip_parent_binary_folder: true
format_overrides:
- goos: windows
format: zip
checksum:
name_template: '{{ .ProjectName }}_{{ .Version }}_SHA256SUMS'
algorithm: sha256
disable: true

0 comments on commit eac4048

Please sign in to comment.