From 2ea3e9b29d6443364c168a7d05d45c2af3c8511a Mon Sep 17 00:00:00 2001 From: Bojan Rajkovic Date: Sun, 15 Feb 2026 08:53:28 -0500 Subject: [PATCH] build: produce universal macOS binary instead of separate arch builds Use GoReleaser's universal_binaries feature with replace:true to combine darwin/amd64 and darwin/arm64 into a single Mach-O universal binary. Users get one macOS download that works on both Intel and Apple Silicon. Archive naming uses "universal" instead of "all" for clarity. Co-Authored-By: Claude Opus 4.6 --- .goreleaser.yml | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/.goreleaser.yml b/.goreleaser.yml index 04338f5..bcea992 100644 --- a/.goreleaser.yml +++ b/.goreleaser.yml @@ -32,6 +32,13 @@ builds: - goos: windows goarch: arm64 +universal_binaries: + - id: cpm-universal + ids: + - cpm + replace: true + name_template: cpm + archives: - id: default formats: @@ -40,7 +47,10 @@ archives: - goos: windows formats: - zip - name_template: "{{ .ProjectName }}_{{ .Version }}_{{ .Os }}_{{ .Arch }}" + name_template: >- + {{ .ProjectName }}_{{ .Version }}_{{ .Os }}_ + {{- if eq .Arch "all" }}universal + {{- else }}{{ .Arch }}{{ end }} files: - LICENSE - README.md