-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #45 from cannam/main
All the packaging updates!
- Loading branch information
Showing
18 changed files
with
222 additions
and
169 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,15 +1,10 @@ | ||
#!/bin/bash | ||
|
||
## The following assumes we have generated an app password at | ||
## appleid.apple.com and then stored it to keychain id "altool" using | ||
## e.g. | ||
## security add-generic-password -a "[email protected]" \ | ||
## -w "generated-app-password" -s "altool" | ||
|
||
## NB to verify: | ||
# spctl -a -v "/Applications/Application.app" | ||
|
||
user="[email protected]" | ||
team_id="73F996B92S" | ||
|
||
set -eu | ||
|
||
|
@@ -21,60 +16,12 @@ dmg="$full_dmg" | |
echo | ||
echo "Uploading for notarization..." | ||
|
||
uuidfile=.notarization-uuid | ||
statfile=.notarization-status | ||
rm -f "$uuidfile" "$statfile" | ||
|
||
# At some point we need to switch to... | ||
#xcrun notarytool submit \ | ||
# "$dmg" \ | ||
# --apple-id "$user" \ | ||
# --keychain-profile altool \ | ||
# --wait --progress | ||
|
||
xcrun altool --notarize-app \ | ||
-f "$dmg" \ | ||
--primary-bundle-id "$bundleid" \ | ||
-u "$user" \ | ||
-p @keychain:altool 2>&1 | tee "$uuidfile" | ||
|
||
uuid=$(cat "$uuidfile" | grep RequestUUID | awk '{ print $3; }') | ||
|
||
if [ -z "$uuid" ]; then | ||
echo | ||
echo "Failed (no UUID returned, check output)" | ||
exit 1 | ||
fi | ||
|
||
echo "Done, UUID is $uuid" | ||
|
||
echo | ||
echo "Waiting and checking for completion..." | ||
|
||
while true ; do | ||
sleep 30 | ||
|
||
xcrun altool --notarization-info \ | ||
"$uuid" \ | ||
-u "$user" \ | ||
-p @keychain:altool 2>&1 | tee "$statfile" | ||
if grep -q 'Package Approved' "$statfile"; then | ||
echo | ||
echo "Approved! Status output is:" | ||
cat "$statfile" | ||
break | ||
elif grep -q 'in progress' "$statfile" ; then | ||
echo | ||
echo "Still in progress... Status output is:" | ||
cat "$statfile" | ||
echo "Waiting..." | ||
else | ||
echo | ||
echo "Failure or unknown status in output:" | ||
cat "$statfile" | ||
exit 2 | ||
fi | ||
done | ||
xcrun notarytool submit \ | ||
"$dmg" \ | ||
--apple-id "$user" \ | ||
--team-id "$team_id" \ | ||
--keychain-profile notarytool-cannam \ | ||
--wait --progress | ||
|
||
echo | ||
echo "Stapling to package..." | ||
|
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.