Skip to content

Commit 80075b3

Browse files
committed
fix(workflow): enhance signing and notarization process for CloudSync.xcframework
1 parent efba6be commit 80075b3

File tree

1 file changed

+6
-2
lines changed

1 file changed

+6
-2
lines changed

.github/workflows/main.yml

Lines changed: 6 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -125,8 +125,12 @@ jobs:
125125
security unlock-keychain -p "${{ secrets.KEYCHAIN_PASSWORD }}" build.keychain
126126
security import certificate.p12 -k build.keychain -P "${{ secrets.CERTIFICATE_PASSWORD }}" -T /usr/bin/codesign
127127
security set-key-partition-list -S apple-tool:,apple:,codesign: -s -k "${{ secrets.KEYCHAIN_PASSWORD }}" build.keychain
128-
codesign --sign "${{ secrets.APPLE_TEAM_ID }}" --timestamp --options runtime dist/CloudSync.xcframework
129-
rm certificate.p12
128+
find dist/CloudSync.xcframework -name "*.framework" -exec echo "Signing: {}" \; -exec codesign --sign "${{ secrets.APPLE_TEAM_ID }}" --timestamp --options runtime {} \; # Sign each individual framework FIRST
129+
codesign --sign "${{ secrets.APPLE_TEAM_ID }}" --timestamp --options runtime dist/CloudSync.xcframework # Then sign the xcframework wrapper
130+
ditto -c -k --keepParent dist/CloudSync.xcframework dist/CloudSync.xcframework.zip
131+
xcrun notarytool submit dist/CloudSync.xcframework.zip --apple-id "${{ secrets.APPLE_ID }}" --password "${{ secrets.APPLE_PASSWORD }}" --team-id "${{ secrets.APPLE_TEAM_ID }}" --wait
132+
find dist/CloudSync.xcframework -name "*.framework" -exec echo "Stapling: {}" \; -exec xcrun stapler staple {} \; # Staple each individual framework
133+
rm dist/CloudSync.xcframework.zip certificate.p12
130134
security delete-keychain build.keychain
131135
132136
- name: android setup test environment

0 commit comments

Comments
 (0)