Skip to content

Commit 405890b

Browse files
committed
🤖 Fix: Use shell parallelism for macOS builds
Changed from Make dependency parallelism to explicit shell parallelism: - dist-mac now runs both architectures with '&' and 'wait' - This ensures true parallel execution (not sequential) - dist-mac-x64/arm64 still available for individual builds Previous approach didn't work because Make doesn't parallelize prerequisites that all depend on 'build' - it ran them sequentially to be safe.
1 parent f1bbaa9 commit 405890b

File tree

2 files changed

+10
-5
lines changed

2 files changed

+10
-5
lines changed

.github/workflows/build.yml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@ jobs:
2929
AC_APIKEY_ISSUER_ID: ${{ secrets.AC_APIKEY_ISSUER_ID }}
3030

3131
- name: Package for macOS
32-
run: make -j dist-mac
32+
run: make dist-mac
3333

3434
- name: Upload macOS DMG (x64)
3535
uses: actions/upload-artifact@v4

Makefile

Lines changed: 9 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -162,13 +162,18 @@ dist: build ## Build distributable packages
162162
@bun x electron-builder --publish never
163163

164164
# Parallel macOS builds - notarization happens concurrently
165-
dist-mac: build dist-mac-x64 dist-mac-arm64 ## Build macOS distributables (x64 + arm64)
166-
167-
dist-mac-x64: ## Build macOS x64 distributable (use via dist-mac)
165+
dist-mac: build ## Build macOS distributables (x64 + arm64 in parallel)
166+
@echo "Building macOS architectures in parallel..."
167+
@bun x electron-builder --mac --x64 --publish never & \
168+
bun x electron-builder --mac --arm64 --publish never & \
169+
wait
170+
@echo "✅ Both architectures built successfully"
171+
172+
dist-mac-x64: build ## Build macOS x64 distributable only
168173
@echo "Building macOS x64..."
169174
@bun x electron-builder --mac --x64 --publish never
170175

171-
dist-mac-arm64: ## Build macOS arm64 distributable (use via dist-mac)
176+
dist-mac-arm64: build ## Build macOS arm64 distributable only
172177
@echo "Building macOS arm64..."
173178
@bun x electron-builder --mac --arm64 --publish never
174179

0 commit comments

Comments
 (0)