Skip to content

Commit

Permalink
fix(win): use resultOutputPath to sign custom location for windows (e…
Browse files Browse the repository at this point in the history
…lectron-userland#7919)

* fix: pull `resultOutputPath` from `CustomWindowsSignTaskConfiguration` (fixes: electron-userland#7910)
  • Loading branch information
mmaietta authored Dec 4, 2023
1 parent 8b91d31 commit 4e930a7
Show file tree
Hide file tree
Showing 2 changed files with 12 additions and 11 deletions.
5 changes: 5 additions & 0 deletions .changeset/forty-teachers-run.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
---
"app-builder-lib": patch
---

fix: pull `resultOutputPath` from `CustomWindowsSignTaskConfiguration` (fixes: #7910)
18 changes: 7 additions & 11 deletions packages/app-builder-lib/src/codeSign/windowsCodeSign.ts
Original file line number Diff line number Diff line change
Expand Up @@ -56,18 +56,14 @@ export async function sign(options: WindowsSignOptions, packager: WinPackager):
let isNest = false
for (const hash of hashes) {
const taskConfiguration: WindowsSignTaskConfiguration = { ...options, hash, isNest }
await Promise.resolve(
executor(
{
...taskConfiguration,
computeSignToolArgs: isWin => computeSignToolArgs(taskConfiguration, isWin),
},
packager
)
)
const config: CustomWindowsSignTaskConfiguration = {
...taskConfiguration,
computeSignToolArgs: isWin => computeSignToolArgs(taskConfiguration, isWin),
}
await Promise.resolve(executor(config, packager))
isNest = true
if (taskConfiguration.resultOutputPath != null) {
await rename(taskConfiguration.resultOutputPath, options.path)
if (config.resultOutputPath != null) {
await rename(config.resultOutputPath, options.path)
}
}

Expand Down

0 comments on commit 4e930a7

Please sign in to comment.