Skip to content

Commit

Permalink
test with win gh action
Browse files Browse the repository at this point in the history
  • Loading branch information
marcopiraccini committed Dec 3, 2023
1 parent a1f2e5f commit a6ebcc4
Showing 1 changed file with 13 additions and 8 deletions.
21 changes: 13 additions & 8 deletions sign-win/sign-win.js
Original file line number Diff line number Diff line change
@@ -1,10 +1,15 @@
// This is a callback that can be used to sign the executable on Windows.
// See: https://www.electron.build/configuration/win
// We are using this callback instead of the electron-builder built-in mechanism
// because we want to use the DigiCert signing tool to sign the executable.
// See also: https://docs.digicert.com/en/digicert-keylocker/sign-with-digicert-signing-tools/sign-with-smctl.html
exports.default = async function (configuration) {
console.log('@@ CONFIGURATION @@', configuration)

// require('child_process').execSync(
// `java -jar ./sign-win/jsign-5.0.jar --keystore hardwareToken.cfg --storepass "${TOKEN_PASSWORD}" --storetype PKCS11 --tsaurl http://timestamp.digicert.com --alias "${CERTIFICATE_NAME}" "${configuration.path}"`,
// {
// stdio: 'inherit'
// }
// )
console.log('@@ Signing for windows', configuration.path)
const execPath = configuration.path
require('child_process').execSync(
`smctl sign --fingerprint "${configuration.fingerprint}" --input "${execPath}"`,
{
stdio: 'inherit'
}
)
}

0 comments on commit a6ebcc4

Please sign in to comment.