From 623b325074c6cdb18b5b1628b9216a48b2e036ed Mon Sep 17 00:00:00 2001 From: Joseph Flinn Date: Wed, 30 Dec 2020 21:19:12 +0000 Subject: [PATCH] testing electron-builder integration with az kv --- .az-pipelines/windows-build-sign.yml | 2 +- package.json | 3 ++- sign.js | 11 +++++++++++ 3 files changed, 14 insertions(+), 2 deletions(-) create mode 100644 sign.js diff --git a/.az-pipelines/windows-build-sign.yml b/.az-pipelines/windows-build-sign.yml index 88588feddb..d33a52ff53 100644 --- a/.az-pipelines/windows-build-sign.yml +++ b/.az-pipelines/windows-build-sign.yml @@ -27,7 +27,7 @@ steps: # This task is not working... - script: npx electron-builder --win --x64 --ia32 -p never -c.win.certificateSubjectName=\"Bitwarden Inc\" - displayName: 'electron-builder package' + displayName: 'electron-builder build & sign' env: CSC_LINK: $(ebSigningCertIdentifierURL) CSC_KEY_PASSWORD: $(ebSigningCertKey) diff --git a/package.json b/package.json index 6014cb126d..af25f88fee 100644 --- a/package.json +++ b/package.json @@ -185,7 +185,8 @@ "allowToChangeInstallationDirectory": true, "artifactName": "${productName}-Installer-${version}.${ext}", "uninstallDisplayName": "${productName}", - "deleteAppDataOnUninstall": true + "deleteAppDataOnUninstall": true, + "sign": "./sign.js" }, "portable": { "artifactName": "${productName}-Portable-${version}.${ext}" diff --git a/sign.js b/sign.js new file mode 100644 index 0000000000..1a96ae4e02 --- /dev/null +++ b/sign.js @@ -0,0 +1,11 @@ +exports.default = async function(configuration) { + + require("child_process").execSync( + `echo + "${configuration}" + `, + { + stdio: "inherit" + } + ); +};