From 49f4003b7e490e39033d2dd7e45a9dde5217c2b7 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Mislav=20Marohni=C4=87?= Date: Fri, 8 Nov 2019 15:57:57 +0100 Subject: [PATCH] Configure goreleaser.yml --- .gitignore | 1 + .goreleaser.yml | 15 ++++++++++++++- 2 files changed, 15 insertions(+), 1 deletion(-) diff --git a/.gitignore b/.gitignore index 2b35ac2cb..bb5b6b266 100644 --- a/.gitignore +++ b/.gitignore @@ -1,3 +1,4 @@ bin/gh /gh-cli .envrc +/dist diff --git a/.goreleaser.yml b/.goreleaser.yml index 76449b88b..52496693a 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -1,14 +1,27 @@ # Make sure to check the documentation at http://goreleaser.com +project_name: gh before: hooks: - go mod tidy builds: - - binary: gh + - binary: bin/gh + ldflags: + - -s -w -X github.com/github/gh-cli/command.Version={{.Version}} -X github.com/github/gh-cli/command.BuildDate={{.Date}} goos: - linux - darwin + - windows goarch: - amd64 +archives: + - name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}{{ if .Arm }}v{{ .Arm }}{{ end }}" + wrap_in_directory: true + replacements: + darwin: macOS + format: tar.gz + format_overrides: + - goos: windows + format: zip changelog: sort: asc filters: