Skip to content

Commit

Permalink
Replace goreleaser replacements with a dynamic name_template
Browse files Browse the repository at this point in the history
  • Loading branch information
gesellix committed Dec 28, 2022
1 parent 2005914 commit 70c4116
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 7 deletions.
2 changes: 1 addition & 1 deletion .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -17,7 +17,7 @@ jobs:
with:
fetch-depth: 1
- name: Check GoReleaser config
uses: goreleaser/goreleaser-action@v3
uses: goreleaser/goreleaser-action@v4
with:
version: latest
args: check
Expand Down
14 changes: 8 additions & 6 deletions .goreleaser.yml
Original file line number Diff line number Diff line change
Expand Up @@ -30,12 +30,14 @@ builds:
release:
draft: true
archives:
- replacements:
darwin: Darwin
linux: Linux
windows: Windows
386: i386
amd64: x86_64
- name_template: >-
{{ .ProjectName }}_
{{- .Version }}_
{{- title .Os }}_
{{- if eq .Arch "amd64" }}x86_64
{{- else if eq .Arch "386" }}i386
{{- else }}{{ .Arch }}{{ end }}
{{- if .Arm }}v{{ .Arm }}{{ end }}
format: tar.gz
format_overrides:
- goos: windows
Expand Down

0 comments on commit 70c4116

Please sign in to comment.