Skip to content

Commit 8f7d01f

Browse files
committed
fix: notarize macOS binaries before publishing release
Split goreleaser into build (--skip=publish) and publish (continue --merge) phases. Notarization runs between the two, ensuring the zip files in the GitHub release are already notarized.
1 parent 292566d commit 8f7d01f

1 file changed

Lines changed: 13 additions & 3 deletions

File tree

.github/workflows/release.yml

Lines changed: 13 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -45,17 +45,17 @@ jobs:
4545
-k "$KEYCHAIN_PASSWORD" "$KEYCHAIN_PATH"
4646
security list-keychains -d user -s "$KEYCHAIN_PATH" login.keychain
4747
48-
# Build, sign, and create release
48+
# Build, sign, and archive — but don't publish yet
4949
- uses: goreleaser/goreleaser-action@v6
5050
with:
5151
version: "~> v2"
52-
args: release --clean
52+
args: release --clean --skip=publish
5353
env:
5454
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
5555
HOMEBREW_TAP_TOKEN: ${{ secrets.HOMEBREW_TAP_TOKEN }}
5656
APPLE_SIGNING_IDENTITY: ${{ secrets.APPLE_SIGNING_IDENTITY }}
5757

58-
# Notarize macOS archives
58+
# Notarize macOS archives before publishing
5959
- name: Notarize macOS binaries
6060
env:
6161
APPLE_ID: ${{ secrets.APPLE_ID }}
@@ -72,6 +72,16 @@ jobs:
7272
echo "Notarized: $archive"
7373
done
7474
75+
# Now publish: create GitHub release and upload all artifacts
76+
- name: Publish release
77+
uses: goreleaser/goreleaser-action@v6
78+
with:
79+
version: "~> v2"
80+
args: continue --merge
81+
env:
82+
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
83+
HOMEBREW_TAP_TOKEN: ${{ secrets.HOMEBREW_TAP_TOKEN }}
84+
7585
# Clean up keychain
7686
- name: Clean up keychain
7787
if: always()

0 commit comments

Comments
 (0)