Skip to content

Commit 6261c9a

Browse files
authored
feat(pkg): support notarizing pkg for macos archives (#8834)
1 parent 198551a commit 6261c9a

File tree

3 files changed

+9
-4
lines changed

3 files changed

+9
-4
lines changed

.changeset/slimy-masks-collect.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,5 @@
1+
---
2+
"app-builder-lib": patch
3+
---
4+
5+
feat(pkg): support notarizing pkg for macos archives

packages/app-builder-lib/src/macPackager.ts

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -361,7 +361,7 @@ export class MacPackager extends PlatformPackager<MacConfiguration> {
361361
}
362362

363363
if (!isMas) {
364-
await this.notarizeIfProvided(appPath, options)
364+
await this.notarizeIfProvided(appPath)
365365
}
366366
return true
367367
}
@@ -527,8 +527,8 @@ export class MacPackager extends PlatformPackager<MacConfiguration> {
527527
return true
528528
}
529529

530-
private async notarizeIfProvided(appPath: string, buildOptions: MacConfiguration) {
531-
const notarizeOptions = buildOptions.notarize
530+
async notarizeIfProvided(appPath: string) {
531+
const notarizeOptions = this.platformSpecificBuildOptions.notarize
532532
if (notarizeOptions === false) {
533533
log.info({ reason: "`notarize` options were set explicitly `false`" }, "skipped macOS notarization")
534534
return

packages/app-builder-lib/src/targets/pkg.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ export class PkgTarget extends Target {
8585
cwd: appOutDir,
8686
})
8787
await Promise.all([unlink(innerPackageFile), unlink(distInfoFile)])
88-
88+
await packager.notarizeIfProvided(artifactPath)
8989
await packager.dispatchArtifactCreated(artifactPath, this, arch, packager.computeSafeArtifactName(artifactName, "pkg", arch))
9090
}
9191

0 commit comments

Comments
 (0)