-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathsign.bash
More file actions
executable file
·30 lines (26 loc) · 1.83 KB
/
sign.bash
File metadata and controls
executable file
·30 lines (26 loc) · 1.83 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
#!/bin/bash
# Name of your app.
APP="Dropsi"
# The path of your app to sign.
APP_PATH="$PWD/dist/mas/Dropsi.app"
# The path to the location you want to put the signed package.
RESULT_PATH="$PWD/signed/$APP.pkg"
# The name of certificates you requested.
APP_KEY="3rd Party Mac Developer Application: Adam Pietrasiak (SXF593CX2N)"
INSTALLER_KEY="3rd Party Mac Developer Installer: Adam Pietrasiak (SXF593CX2N)"
# The path of your plist files.
CHILD_PLIST="$PWD/build/child.plist"
PARENT_PLIST="$PWD/build/parent.plist"
LOGINHELPER_PLIST="$PWD/build/loginhelper.plist"
FRAMEWORKS_PATH="$APP_PATH/Contents/Frameworks"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Electron Framework"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Libraries/libffmpeg.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework/Versions/A/Libraries/libnode.dylib"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/Electron Framework.framework"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper.app/Contents/MacOS/$APP Helper"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$FRAMEWORKS_PATH/$APP Helper.app/"
codesign -s "$APP_KEY" -f --entitlements "$LOGINHELPER_PLIST" "$APP_PATH/Contents/Library/LoginItems/$APP Login Helper.app/Contents/MacOS/$APP Login Helper"
codesign -s "$APP_KEY" -f --entitlements "$LOGINHELPER_PLIST" "$APP_PATH/Contents/Library/LoginItems/$APP Login Helper.app/"
codesign -s "$APP_KEY" -f --entitlements "$CHILD_PLIST" "$APP_PATH/Contents/MacOS/$APP"
codesign -s "$APP_KEY" -f --entitlements "$PARENT_PLIST" "$APP_PATH"
productbuild --component "$APP_PATH" /Applications --sign "$INSTALLER_KEY" "$RESULT_PATH"