macOS Notarization: correct Team ID

This commit is contained in:
Casper Jeukendrup 2023-10-14 17:04:49 +02:00
parent 641898e325
commit 3d6610eba3
No known key found for this signature in database
GPG key ID: 6C571BEF59E722DD

View file

@ -25,6 +25,9 @@ ARTIFACTS_DIR="build.artifacts"
APPLE_USERNAME=""
APPLE_PASSWORD=""
# This information is public and can be extracted by anyone from the final .app file
APPLE_TEAM_ID="6EPAF2X3PR"
while [[ "$#" -gt 0 ]]; do
case $1 in
-u|--user) APPLE_USERNAME="$2"; shift ;;
@ -37,20 +40,14 @@ done
if [ -z "$APPLE_USERNAME" ]; then echo "error: not set APPLE_USERNAME"; exit 1; fi
if [ -z "$APPLE_PASSWORD" ]; then echo "error: not set APPLE_PASSWORD"; exit 1; fi
echo "APPLE_USERNAME: $APPLE_USERNAME"
echo "APPLE_PASSWORD: $APPLE_PASSWORD"
ARTIFACT_NAME="$(cat $ARTIFACTS_DIR/env/artifact_name.env)"
echo "ARTIFACT_NAME: $ARTIFACT_NAME"
echo "Uploading to Apple to notarize..."
success=0
xcrun notarytool submit --apple-id $APPLE_USERNAME --team-id MuseScore --password $APPLE_PASSWORD --wait $ARTIFACTS_DIR/$ARTIFACT_NAME && success=1
xcrun notarytool submit --apple-id $APPLE_USERNAME --team-id $APPLE_TEAM_ID --password $APPLE_PASSWORD --wait $ARTIFACTS_DIR/$ARTIFACT_NAME
if [ $success -eq 1 ] ; then
echo "Stapling and running packaging up"
xcrun stapler staple $ARTIFACTS_DIR/$ARTIFACT_NAME
echo "Staple finished!"
xcrun stapler validate $ARTIFACTS_DIR/$ARTIFACT_NAME
fi
echo "Stapling and running packaging up"
xcrun stapler staple $ARTIFACTS_DIR/$ARTIFACT_NAME
echo "Staple finished!"
xcrun stapler validate $ARTIFACTS_DIR/$ARTIFACT_NAME