version: 2 builds: - main: ./... env: - CGO_ENABLED=0 goos: - linux - windows - darwin goarch: - arm64 - amd64 - "386" dir: cmd archives: - formats: [tar.gz] # this name template makes the OS and Arch compatible with the results of `uname`. name_template: >- {{ .ProjectName }}_ {{- title .Os }}_ {{- if eq .Arch "amd64" }}x86_64 {{- else if eq .Arch "386" }}i386 {{- else }}{{ .Arch }}{{ end }} {{- if .Arm }}v{{ .Arm }}{{ end }} # use zip for windows archives format_overrides: - goos: windows formats: [zip] changelog: sort: asc filters: exclude: - "^docs:" - "^test:" upx: - # Templates: allowed. enabled: true # Filter by build ID. ids: [build1, build2] # Filter by GOOS. goos: [linux, darwin] # Filter by GOARCH. goarch: [arm, amd64] # Filter by GOARM. goarm: [8] # Filter by GOAMD64. goamd64: [v1] # Compress argument. # Valid options are from '1' (faster) to '9' (better), and 'best'. compress: best # Whether to try LZMA (slower). lzma: true # Whether to try all methods and filters (slow). brute: true