From 5eb10afe856cded141575f17604767d610ba974e Mon Sep 17 00:00:00 2001 From: Joseph Flinn Date: Wed, 6 Jan 2021 19:33:43 +0000 Subject: [PATCH] changing over to a value based boolean flag --- .github/workflows/build-and-sign.yml | 2 +- .github/workflows/build.yml | 2 +- sign.js | 8 +++++++- 3 files changed, 9 insertions(+), 3 deletions(-) diff --git a/.github/workflows/build-and-sign.yml b/.github/workflows/build-and-sign.yml index 7956f683..dae775b2 100644 --- a/.github/workflows/build-and-sign.yml +++ b/.github/workflows/build-and-sign.yml @@ -71,7 +71,7 @@ jobs: npm run build npm run pack:win env: - ELECTRON_BUILDER_SIGN: true + ELECTRON_BUILDER_SIGN: 1 SIGNING_VAULT_URL: ${{ secrets.SIGNING_VAULT_URL }} SIGNING_CLIENT_ID: ${{ secrets.SIGNING_CLIENT_ID }} SIGNING_TENANT_ID: ${{ secrets.SIGNING_TENANT_ID }} diff --git a/.github/workflows/build.yml b/.github/workflows/build.yml index b90b69fc..d0fe4686 100644 --- a/.github/workflows/build.yml +++ b/.github/workflows/build.yml @@ -164,7 +164,7 @@ jobs: shell: pwsh run: npm run dist:win:ci env: - ELECTRON_BUILDER_SIGN: false + ELECTRON_BUILDER_SIGN: 0 - name: Rename appx files for store shell: pwsh diff --git a/sign.js b/sign.js index f3969c37..b5ba6816 100644 --- a/sign.js +++ b/sign.js @@ -1,5 +1,11 @@ exports.default = async function(configuration) { - if (process.env.ELECTRON_BUILDER_SIGN) { + + console.log('+++++++++++++++++++++++++++++++++++++++++++++++++++') + console.log(`ELECTRON_BUILDER_SIGN: ${process.env.ELECTRON_BUILDER_SIGN}`) + console.log(`Type: ${typeof process.env.ELECTRON_BUILDER_SIGN}`) + console.log('+++++++++++++++++++++++++++++++++++++++++++++++++++') + + if (process.env.ELECTRON_BUILDER_SIGN === 1) { require("child_process").execSync( `azuresigntool sign ` + `-kvu ${process.env.SIGNING_VAULT_URL} ` +