-
Notifications
You must be signed in to change notification settings - Fork 0
Open
Description
Problem
The macOS GUI is currently being built twice in our release workflows:
- First build: In the
build-guijob matrix (build-and-package.yml), macOS GUI is built onmacos-latestand uploaded as an artifact - Second build: In the
packagejob, GoReleaser runs with abefore.hooksthat calls./scripts/build-wails.sh, which defaults to building macOS GUI again
Only the second build is actually used - the first build artifact is never downloaded by the package job.
Proposed Solution
Remove macOS from the build-gui matrix and rely on the GoReleaser hook to build it.
This makes the build flow:
- Linux/Windows GUI: Built on native platforms via build-gui job (required due to CGO + system libraries)
- macOS GUI: Built by GoReleaser hook on the macOS runner (where signing/notarization happens)
Rationale
- Consistency with existing design: The signing/notarization hooks in
.goreleaser.yamlalready expect GoReleaser to build macOS - Simpler artifact handling: No need to coordinate downloading macOS artifacts
- Performance: Saves ~10-15 minutes by eliminating duplicate macOS build
- Clarity: Makes it obvious where each platform is built
Implementation
File: .github/workflows/build-and-package.yml
Remove the macOS entry from the build-gui matrix:
strategy:
matrix:
include:
- name: linux-amd64
os: ubuntu-22.04
platforms: linux/amd64
cc: gcc
artifact-name: gui-linux-amd64
- name: linux-arm64
os: ubuntu-22.04-arm
platforms: linux/arm64
cc: gcc
artifact-name: gui-linux-arm64
# Remove this entry:
# - name: macos
# os: macos-latest
# platforms: darwin/amd64,darwin/arm64
# cc: ""
# artifact-name: gui-macos
- name: windows
os: windows-latest
platforms: windows/amd64
cc: ""
artifact-name: gui-windowsNo changes needed to .goreleaser.yaml - it already has the build hook configured correctly.
Benefits
- 🚀 Faster CI (eliminates duplicate build)
- 🧹 Cleaner artifact handling
- ✅ No functional changes (same binaries produced)
- 📦 Maintains existing signing/notarization flow
Related Files
.github/workflows/build-and-package.yml(build-gui matrix).goreleaser.yaml(before.hooks that builds macOS)scripts/build-wails.sh(defaults to darwin platforms)
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels