|
| 1 | +diff --git a/lib/check-signature.js b/lib/check-signature.js |
| 2 | +index 324568af71bcc4372c9f959131ecd24122848c86..677348e0a138ff608b2ac41f592d813b15ee4956 100644 |
| 3 | +--- a/lib/check-signature.js |
| 4 | ++++ b/lib/check-signature.js |
| 5 | +@@ -41,16 +41,12 @@ const spawn_1 = require("./spawn"); |
| 6 | + const debug_1 = __importDefault(require("debug")); |
| 7 | + const d = (0, debug_1.default)('electron-notarize'); |
| 8 | + const codesignDisplay = (opts) => __awaiter(void 0, void 0, void 0, function* () { |
| 9 | +- const result = yield (0, spawn_1.spawn)('codesign', ['-dv', '-vvvv', '--deep', path.basename(opts.appPath)], { |
| 10 | +- cwd: path.dirname(opts.appPath), |
| 11 | +- }); |
| 12 | ++ const result = yield (0, spawn_1.spawn)('codesign', ['-dv', '-vvvv', '--deep', opts.appPath]); |
| 13 | + return result; |
| 14 | + }); |
| 15 | + const codesign = (opts) => __awaiter(void 0, void 0, void 0, function* () { |
| 16 | + d('attempting to check codesign of app:', opts.appPath); |
| 17 | +- const result = yield (0, spawn_1.spawn)('codesign', ['-vvv', '--deep', '--strict', path.basename(opts.appPath)], { |
| 18 | +- cwd: path.dirname(opts.appPath), |
| 19 | +- }); |
| 20 | ++ const result = yield (0, spawn_1.spawn)('codesign', ['-vvv', '--deep', '--strict', opts.appPath]); |
| 21 | + return result; |
| 22 | + }); |
| 23 | + function checkSignatures(opts) { |
| 24 | +diff --git a/lib/notarytool.js b/lib/notarytool.js |
| 25 | +index 1ab090efb2101fc8bee5553445e0349c54474421..a5ddfd922197449fc56078e4a7e9a2ee5d8d207d 100644 |
| 26 | +--- a/lib/notarytool.js |
| 27 | ++++ b/lib/notarytool.js |
| 28 | +@@ -92,9 +92,7 @@ function notarizeAndWaitForNotaryTool(opts) { |
| 29 | + else { |
| 30 | + filePath = path.resolve(dir, `${path.parse(opts.appPath).name}.zip`); |
| 31 | + d('zipping application to:', filePath); |
| 32 | +- const zipResult = yield (0, spawn_1.spawn)('ditto', ['-c', '-k', '--sequesterRsrc', '--keepParent', path.basename(opts.appPath), filePath], { |
| 33 | +- cwd: path.dirname(opts.appPath), |
| 34 | +- }); |
| 35 | ++ const zipResult = yield (0, spawn_1.spawn)('ditto', ['-c', '-k', '--sequesterRsrc', '--keepParent', opts.appPath, filePath]); |
| 36 | + if (zipResult.code !== 0) { |
| 37 | + throw new Error(`Failed to zip application, exited with code: ${zipResult.code}\n\n${zipResult.output}`); |
| 38 | + } |
| 39 | +diff --git a/lib/staple.js b/lib/staple.js |
| 40 | +index 47dbd85b2fc279d999b57f47fb8171e1cc674436..f8829e6ac54fcd630a730d12d75acc1591b953b6 100644 |
| 41 | +--- a/lib/staple.js |
| 42 | ++++ b/lib/staple.js |
| 43 | +@@ -43,9 +43,7 @@ const d = (0, debug_1.default)('electron-notarize:staple'); |
| 44 | + function stapleApp(opts) { |
| 45 | + return __awaiter(this, void 0, void 0, function* () { |
| 46 | + d('attempting to staple app:', opts.appPath); |
| 47 | +- const result = yield (0, spawn_1.spawn)('xcrun', ['stapler', 'staple', '-v', path.basename(opts.appPath)], { |
| 48 | +- cwd: path.dirname(opts.appPath), |
| 49 | +- }); |
| 50 | ++ const result = yield (0, spawn_1.spawn)('xcrun', ['stapler', 'staple', '-v', opts.appPath]); |
| 51 | + if (result.code !== 0) { |
| 52 | + throw new Error(`Failed to staple your application with code: ${result.code}\n\n${result.output}`); |
| 53 | + } |
0 commit comments