-
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.
- Loading branch information
Showing
6 changed files
with
3,993 additions
and
1,922 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
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,5 +1,7 @@ | ||
node_modules | ||
dist | ||
|
||
prod-env.sh | ||
|
||
# emacs | ||
.#* | ||
.#* |
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 |
---|---|---|
@@ -0,0 +1,39 @@ | ||
const fs = require("fs"); | ||
const path = require("path"); | ||
|
||
var electron_notarize = require("electron-notarize"); | ||
|
||
require("dotenv").config(); | ||
|
||
module.exports = async function (params) { | ||
// Only notarize the app on Mac OS only. | ||
if (process.platform !== "darwin") { | ||
return; | ||
} | ||
console.log("afterSign hook triggered", params); | ||
// Same appId in electron-builder. | ||
let appId = "network.marker.Designer"; | ||
let appPath = path.join( | ||
params.appOutDir, | ||
`${params.packager.appInfo.productFilename}.app` | ||
); | ||
if (!fs.existsSync(appPath)) { | ||
throw new Error(`Cannot find application at: ${appPath}`); | ||
} | ||
console.log(`Notarizing ${appId} found at ${appPath}`); | ||
try { | ||
await electron_notarize.notarize({ | ||
appBundleId: appId, | ||
appPath: appPath, | ||
appleId: process.env.APPLE_ID, // this is your apple ID it should be stored in an .env file | ||
appleIdPassword: process.env.APPLE_ID_PASS, // this is NOT your apple ID password. You need to | ||
//create an application specific password from https://appleid.apple.com under "security" you can generate | ||
//such a password | ||
// ascProvider: process.env.appleIdProvider // this is only needed if you have multiple developer | ||
// profiles linked to your apple ID. | ||
}); | ||
} catch (error) { | ||
console.error(error); | ||
} | ||
console.log(`Done notarizing ${appId}`); | ||
}; |
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 |
---|---|---|
@@ -0,0 +1,14 @@ | ||
<?xml version="1.0" encoding="UTF-8"?> | ||
<!DOCTYPE plist PUBLIC "-//Apple//DTD PLIST 1.0//EN" "http://www.apple.com/DTDs/PropertyList-1.0.dtd"> | ||
<plist version="1.0"> | ||
<dict> | ||
<key>com.apple.security.cs.allow-jit</key> | ||
<true/> | ||
<key>com.apple.security.cs.allow-unsigned-executable-memory</key> | ||
<true/> | ||
<key>com.apple.security.cs.allow-dyld-environment-variables</key> | ||
<true/> | ||
<key>com.apple.security.cs.disable-library-validation</key> | ||
<true/> | ||
</dict> | ||
</plist> |
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Oops, something went wrong.