Skip to content

Commit

Permalink
fix(mac): remove internet-enable from macOS 10.15 (#4405) (#4531)
Browse files Browse the repository at this point in the history
* fix(mac): remove internet-enable from macOS 10.15 (#4405)

Prevent the internet-verb from being used with hdiutil on macOS 10.15
"Catalina" or newer, since it was removed

Fixes #4405

* fix: add radix to parseInt
  • Loading branch information
migliorinie authored and develar committed Jan 16, 2020
1 parent 24018dd commit 8dd587f
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion packages/dmg-builder/src/dmg.ts
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,7 @@ export class DmgTarget extends Target {
args.push("-imagekey", `zlib-level=${process.env.ELECTRON_BUILDER_COMPRESSION_LEVEL || "9"}`)
}
await spawn("hdiutil", addLogLevel(args))
if (this.options.internetEnabled) {
if (this.options.internetEnabled && parseInt(require("os").split(".")[0], 10) < 19) {
await exec("hdiutil", addLogLevel(["internet-enable"]).concat(artifactPath))
}

Expand Down

0 comments on commit 8dd587f

Please sign in to comment.