Skip to content

Commit 9c15589

Browse files
byshingclaude
andcommitted
Add macOS notarization, revert pr-run-mode to plan, bump to 1.0.0-alpha.1
- Add APPLE_NOTARIZE_* secrets and notarize step to release workflow; step runs only on macOS targets and only on tag releases - Revert pr-run-mode from upload back to plan - Bump version to 1.0.0-alpha.1 for pre-release testing Co-Authored-By: Claude Sonnet 4.6 (1M context) <noreply@anthropic.com>
1 parent 72d76d0 commit 9c15589

3 files changed

Lines changed: 17 additions & 2 deletions

File tree

.github/workflows/release.yml

Lines changed: 15 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,9 @@ jobs:
115115
CODESIGN_CERTIFICATE: ${{ secrets.APPLE_CERTIFICATE }}
116116
CODESIGN_CERTIFICATE_PASSWORD: ${{ secrets.APPLE_CERTIFICATE_PASSWORD }}
117117
CODESIGN_IDENTITY: ${{ secrets.APPLE_CODESIGN_IDENTITY }}
118+
APPLE_NOTARIZE_ID: ${{ secrets.APPLE_NOTARIZE_ID }}
119+
APPLE_NOTARIZE_PASSWORD: ${{ secrets.APPLE_NOTARIZE_PASSWORD }}
120+
APPLE_NOTARIZE_TEAM_ID: ${{ secrets.APPLE_NOTARIZE_TEAM_ID }}
118121
permissions:
119122
"attestations": "write"
120123
"contents": "read"
@@ -155,6 +158,18 @@ jobs:
155158
# Actually do builds and make zips and whatnot
156159
dist build ${{ needs.plan.outputs.tag-flag }} --print=linkage --output-format=json ${{ matrix.dist_args }} > dist-manifest.json
157160
echo "dist ran successfully"
161+
- name: Notarize macOS binary
162+
if: ${{ contains(join(matrix.targets, ','), 'apple-darwin') && needs.plan.outputs.publishing == 'true' }}
163+
shell: bash
164+
run: |
165+
binary=$(find target/dist -name "bitmex" -not -path "*/build/*" -not -path "*/deps/*" | head -1)
166+
zip_path="${binary}.zip"
167+
ditto -c -k --keepParent "$binary" "$zip_path"
168+
xcrun notarytool submit "$zip_path" \
169+
--apple-id "$APPLE_NOTARIZE_ID" \
170+
--password "$APPLE_NOTARIZE_PASSWORD" \
171+
--team-id "$APPLE_NOTARIZE_TEAM_ID" \
172+
--wait
158173
- name: Attest
159174
uses: actions/attest-build-provenance@v3
160175
with:

Cargo.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,6 @@
11
[package]
22
name = "bitmex-cli"
3-
version = "1.0.0"
3+
version = "1.0.0-alpha.1"
44
edition = "2024"
55
description = "BitMEX CLI — trade, query, and manage your BitMEX account from the terminal"
66
license = "MIT"

dist-workspace.toml

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@ installers = ["shell", "powershell"]
1212
# Target platforms to build apps for (Rust target-triple syntax)
1313
targets = ["aarch64-apple-darwin", "aarch64-unknown-linux-gnu", "x86_64-apple-darwin", "x86_64-unknown-linux-gnu", "x86_64-pc-windows-msvc"]
1414
# Which actions to run on pull requests
15-
pr-run-mode = "upload"
15+
pr-run-mode = "plan"
1616
# The archive format to use for non-windows builds (defaults .tar.xz)
1717
unix-archive = ".tar.gz"
1818
# Whether to enable GitHub Attestations

0 commit comments

Comments
 (0)