diff options
author | Andrey Lihatskiy <alihatskiy@productengine.com> | 2021-04-29 08:07:24 +0300 |
---|---|---|
committer | Andrey Lihatskiy <alihatskiy@productengine.com> | 2021-04-29 08:07:24 +0300 |
commit | 487685fef1ad4afdb1d6692a4ab6b2980205abd7 (patch) | |
tree | e8c15684eea6169ed1dee5974289663ccb6e0ff9 /indra/newview/installers | |
parent | 2f7e9aac00b0c76210154ca209cd83fac7b8086d (diff) |
DRTVWR-520 Safety check; remove temporary zip file
Diffstat (limited to 'indra/newview/installers')
-rwxr-xr-x | indra/newview/installers/darwin/apple-notarize.sh | 61 |
1 files changed, 30 insertions, 31 deletions
diff --git a/indra/newview/installers/darwin/apple-notarize.sh b/indra/newview/installers/darwin/apple-notarize.sh index a590f52e38..00d10b222a 100755 --- a/indra/newview/installers/darwin/apple-notarize.sh +++ b/indra/newview/installers/darwin/apple-notarize.sh @@ -1,42 +1,41 @@ #!/bin/sh - CONFIG_FILE="$build_secrets_checkout/code-signing-osx/notarize_creds.sh" if [ -f "$CONFIG_FILE" ]; then source $CONFIG_FILE - app_file="$1" zip_file=${app_file/app/zip} ditto -c -k --keepParent "$app_file" "$zip_file" - - - requestUUID=$(xcrun altool --notarize-app --primary-bundle-id "com.secondlife.viewer" \ - --username $USERNAME \ - --password $PASSWORD \ - --asc-provider $ASC_PROVIDER \ - --file "$zip_file" 2>&1 \ - | awk '/RequestUUID/ { print $NF; }') - - echo "Apple Notarization RequestUUID: $requestUUID" - - if [[ -n $requestUUID ]]; then - status="in progress" - while [[ "$status" == "in progress" ]]; do - sleep 30 - status=$(xcrun altool --notarization-info "$requestUUID" \ - --username $USERNAME \ - --password $PASSWORD 2>&1 \ - | awk -F ': ' '/Status:/ { print $2; }' ) - echo "$status" - done - - # log results - xcrun altool --notarization-info "$requestUUID" \ - --username $USERNAME \ - --password $PASSWORD - - if [["$status" == "success"]]; then - xcrun stapler staple "$app_file" + if [ -f "$zip_file" ]; then + requestUUID=$(xcrun altool --notarize-app --primary-bundle-id "com.secondlife.viewer" \ + --username $USERNAME \ + --password $PASSWORD \ + --asc-provider $ASC_PROVIDER \ + --file "$zip_file" 2>&1 \ + | awk '/RequestUUID/ { print $NF; }') + + echo "Apple Notarization RequestUUID: $requestUUID" + + if [[ -n $requestUUID ]]; then + status="in progress" + while [[ "$status" == "in progress" ]]; do + sleep 30 + status=$(xcrun altool --notarization-info "$requestUUID" \ + --username $USERNAME \ + --password $PASSWORD 2>&1 \ + | awk -F ': ' '/Status:/ { print $2; }' ) + echo "$status" + done + # log results + xcrun altool --notarization-info "$requestUUID" \ + --username $USERNAME \ + --password $PASSWORD + + if [["$status" == "success"]]; then + xcrun stapler staple "$app_file" + fi fi + #remove temporary file + rm "$zip_file" fi fi |