From 54edf1d49afbd6bd5b09454af332dfe7cd234f2e Mon Sep 17 00:00:00 2001 From: Jon Hadfield Date: Sun, 27 Aug 2023 12:53:33 +0100 Subject: [PATCH] update gorelease with new syntax. --- .goreleaser.yml | 15 +++++++++++---- 1 file changed, 11 insertions(+), 4 deletions(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index 09ae5ae..1920a84 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -26,7 +26,7 @@ builds: post: | sh -c ' cat > /tmp/sn-cli-gon-amd64.hcl << EOF - source = ["./dist/sn-macos_darwin_amd64/sn"] + source = ["./dist/sn-macos_darwin_amd64_v1/sn"] bundle_id = "uk.co.lessknown.sn-cli" apple_id { username = "jon@lessknown.co.uk" @@ -90,8 +90,15 @@ builds: - "-s -w -X main.version={{ .Version }} -X main.sha={{ .ShortCommit }} -X main.buildDate={{ .Date }} -X main.tag={{ .Tag }}" archives: - - name_template: "{{ .ProjectName }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}" - replacements: + - name_template: >- + {{ .ProjectName }}_ + {{- if eq .Os "linux" }}Linux_ + {{- else if eq .Os "windows" }}Windows_ + {{- else }}{{- tolower .Os }}_{{ end }} + {{- if eq .Arch "amd64" }}x86_64 + {{- else if eq .Arch "386" }}i386 + {{- else }}{{ .Arch }}{{ end }} + {{ if .Arm }}v{{ .Arm }}{{ end }} linux: Linux windows: Windows 386: i386 @@ -129,4 +136,4 @@ changelog: - ignore checksum: - name_template: 'checksums.txt' \ No newline at end of file + name_template: 'checksums.txt'