codesign apps and dmg in macos

This commit is contained in:
Luis Ángel San Martín 2019-09-01 14:57:45 +02:00
parent 09d2266c9f
commit 7d67a79e26
4 changed files with 14 additions and 1 deletions

View File

@ -45,6 +45,10 @@ jobs:
find . \( -name '*.h' -or -name '*.cpp' -or -name '*.c' -or -name '*.mm' -or -name '*.m' \) -print0 | xargs -0 clang-format -style=file -i
if [ "$(git diff $(Build.SourceVersion))" != "" ]; then exit 1; fi
displayName: 'Check format'
- task: InstallAppleCertificate@2
inputs:
certSecureFile: 'developerID_application.p12'
certPwd: $(P12Password)
- script: |
cd $(Build.SourcesDirectory)
VERSION="$(cat common/yacreader_global.h | grep '#define VERSION "' | tr -d '#define VERSION' | tr -d '"' )"

View File

@ -61,4 +61,6 @@ sed -i'' -e "s/#VERSION#/$VERSION/g" dmg.json
sed -i'' -e "s/#BUILD_NUMBER#/$BUILD_NUMBER/g" dmg.json
appdmg dmg.json "$dest.dmg"
codesign --force --deep --sign "Developer ID Application: LUIS ANGEL SAN MARTIN ROD (9B6KKVW3WM)" "./${dest}.dmg"
echo "Done!"

View File

@ -26,5 +26,7 @@ cp -R release/languages YACReader.app/Contents/MacOS/
cp -R release/languages YACReaderLibrary.app/Contents/MacOS/
cp -R release/languages YACReaderLibraryServer.app/Contents/MacOS/
./signapps.sh
echo "Done."
#./signapps.sh

5
signapps.sh Executable file
View File

@ -0,0 +1,5 @@
#!/bin/bash
codesign --force --deep --sign "Developer ID Application: LUIS ANGEL SAN MARTIN ROD (9B6KKVW3WM)" ./YACReader.app
codesign --force --deep --sign "Developer ID Application: LUIS ANGEL SAN MARTIN ROD (9B6KKVW3WM)" ./YACReaderLibrary.app
codesign --force --deep --sign "Developer ID Application: LUIS ANGEL SAN MARTIN ROD (9B6KKVW3WM)" ./YACReaderLibraryServer.app