mirror of
https://gitflic.ru/project/openide/openide.git
synced 2026-09-27 10:03:11 +07:00
updated signbin.sh
IDEA-171989 Signing of IDEA Mac OS application sometimes fail with "A timestamp was expected but was not found" error
This commit is contained in:
@@ -1,8 +1,5 @@
|
||||
#!/bin/bash
|
||||
|
||||
#immediately exit script with an error if a command fails
|
||||
set -euo pipefail
|
||||
|
||||
FILENAME=$1
|
||||
USERNAME=$2
|
||||
PASSWORD=$3
|
||||
@@ -12,9 +9,24 @@ FILEPATH=$(dirname $0)/$FILENAME
|
||||
# Make sure *.p12 is imported into local KeyChain
|
||||
security unlock-keychain -p ${PASSWORD} /Users/${USERNAME}/Library/Keychains/login.keychain
|
||||
|
||||
echo "signing ${FILEPATH}"
|
||||
codesign -v --deep --force -s "${CODESIGN_STRING}" ${FILEPATH}
|
||||
echo "signing is done"
|
||||
echo "check sign"
|
||||
codesign -v ${FILEPATH} -vvvvv
|
||||
echo "check sign done"
|
||||
attemp=1
|
||||
limit=3
|
||||
while [ $attemp -le $limit ]
|
||||
do
|
||||
echo "signing (attemp $attemp) ${FILEPATH}"
|
||||
codesign -v --deep --force -s "${CODESIGN_STRING}" ${FILEPATH}
|
||||
echo "signing done"
|
||||
codesign -v ${FILEPATH} -vvvvv
|
||||
echo "check sign done"
|
||||
if [ "$?" != "0" ]; then
|
||||
let "attemp += 1"
|
||||
if [ $attemp -eq $limit ]; then
|
||||
#immediately exit script with an error if a command fails
|
||||
set -euo pipefail
|
||||
fi
|
||||
echo "wait for 30 sec and try to sign again"
|
||||
sleep 30;
|
||||
else
|
||||
let "attemp += $limit"
|
||||
fi
|
||||
done
|
||||
|
||||
Reference in New Issue
Block a user