electron-notarize
Advanced tools
Comparing version 0.1.0 to 0.1.1
@@ -133,3 +133,3 @@ var __awaiter = (this && this.__awaiter) || function (thisArg, _arguments, P, generator) { | ||
d('still in progress, waiting 30 seconds'); | ||
return [4 /*yield*/, new Promise(function (r) { return setTimeout(r, 30000); })]; | ||
return [4 /*yield*/, delay(30000)]; | ||
case 2: | ||
@@ -196,8 +196,21 @@ _a.sent(); | ||
uuid = (_b.sent()).uuid; | ||
return [4 /*yield*/, waitForNotarize({ uuid: uuid, appleId: appleId, appleIdPassword: appleIdPassword })]; | ||
/** | ||
* Wait for Apples API to initialize the status UUID | ||
* | ||
* If we start checking too quickly the UUID is not ready yet | ||
* and this step will fail. It takes apple a number of minutes | ||
* to actually complete the job so an extra 10 second delay here | ||
* is not a big deal | ||
*/ | ||
d('notarization started, waiting for 10 seconds before pinging apple for status'); | ||
return [4 /*yield*/, delay(10000)]; | ||
case 2: | ||
_b.sent(); | ||
return [4 /*yield*/, stapleApp({ appPath: appPath })]; | ||
d('starting to poll for notarization status'); | ||
return [4 /*yield*/, waitForNotarize({ uuid: uuid, appleId: appleId, appleIdPassword: appleIdPassword })]; | ||
case 3: | ||
_b.sent(); | ||
return [4 /*yield*/, stapleApp({ appPath: appPath })]; | ||
case 4: | ||
_b.sent(); | ||
return [2 /*return*/]; | ||
@@ -209,2 +222,5 @@ } | ||
exports.notarize = notarize; | ||
function delay(ms) { | ||
return new Promise(function (resolve) { return setTimeout(resolve, ms); }); | ||
} | ||
//# sourceMappingURL=index.js.map |
{ | ||
"name": "electron-notarize", | ||
"version": "0.1.0", | ||
"version": "0.1.1", | ||
"description": "Notarize your Electron app", | ||
@@ -5,0 +5,0 @@ "main": "lib/index.js", |
@@ -38,2 +38,11 @@ Electron Notarize | ||
#### Prerequisites | ||
For notarization, you need the following things: | ||
1. Xcode 10 or later installed on your Mac. | ||
2. An [Apple Developer](https://developer.apple.com/) account. | ||
3. [An app-specific password for your ADC account’s Apple ID](https://support.apple.com/HT204397). | ||
#### Safety when using `appleIdPassword` | ||
@@ -43,3 +52,4 @@ | ||
variable at a minimum. | ||
2. It is possible to provide a keychain reference instead of your actual password. E.g. | ||
2. It is possible to provide a keychain reference instead of your actual password (assuming that you have already logged into | ||
the Application Loader from Xcode). For example: | ||
@@ -50,2 +60,14 @@ ```js | ||
Another option is that you can add a new keychain item using either the Keychain Access app or from the command line using the `security` utility: | ||
```shell | ||
security add-generic-password -a "AC_USERNAME" -w <app_specific_password> -s "AC_PASSWORD" | ||
``` | ||
where `AC_USERNAME` should be replaced with your Apple ID, and then in your code you can use: | ||
```js | ||
const password = `@keychain:AC_PASSWORD`; | ||
``` | ||
#### Example Usage | ||
@@ -52,0 +74,0 @@ |
Sorry, the diff of this file is not supported yet
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
30684
402
86