diff --git a/.goreleaser.yml b/.goreleaser.yml index 7eb064c5..52c770d4 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -23,6 +23,8 @@ builds: - 5 - 6 - 7 + hooks: + post: ./build-darwin-cgo.sh archive: name_template: "{{ .Binary }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}{{ .Arm }}{{ end }}" replacements: diff --git a/build-darwin-cgo.sh b/build-darwin-cgo.sh new file mode 100755 index 00000000..0d257797 --- /dev/null +++ b/build-darwin-cgo.sh @@ -0,0 +1,5 @@ +#!/usr/bin/env bash + +xgo --targets="darwin/386,darwin/amd64" $PWD +mv gotop-darwin-10.6-386 dist/darwin_386/gotop +mv gotop-darwin-10.6-amd64 dist/darwin_amd64/gotop