From bfa2a08f030820aecf0991d3f288eb8cea798b48 Mon Sep 17 00:00:00 2001 From: jom Date: Wed, 23 Mar 2022 16:30:07 +0100 Subject: [PATCH] [build] workaround to fix windows native module build --- Desktop.Jenkinsfile | 11 +++-------- 1 file changed, 3 insertions(+), 8 deletions(-) diff --git a/Desktop.Jenkinsfile b/Desktop.Jenkinsfile index 570c78a6653c..bef114eab230 100644 --- a/Desktop.Jenkinsfile +++ b/Desktop.Jenkinsfile @@ -3,9 +3,6 @@ pipeline { NODE_PATH = '/opt/node-v16.3.0-linux-x64/bin' NODE_MAC_PATH = '/usr/local/opt/node@16/bin/' VERSION = sh(returnStdout: true, script: "${NODE_PATH}/node -p -e \"require('./package.json').version\" | tr -d \"\n\"") - - // Needed for our workaround for the windows build - BETTER_SQLITE3_VERSION = sh(returnStdout: true, script: "${NODE_PATH}/node -p -e \"require('./package.json').dependencies['better-sqlite3']\" | tr -d '\n'") } options { preserveStashes() @@ -58,11 +55,9 @@ pipeline { // FIXME this is a workaround for https://github.com/tutao/tutanota/issues/3982 // The hash generated by npm on windows is different to the one - // So we just install better-sqlite3 using the version referenced in package.json - // And then run npm ci - - bat "npm install -S ${BETTER_SQLITE3_VERSION}" - bat 'npm ci' + // So we just don't install with npm ci + bat 'del package-lock.json' + bat "npm install" bat "node buildSrc\\nativeLibraryProvider.js keytar --force-rebuild --root-dir ${WORKSPACE}" bat "node buildSrc\\nativeLibraryProvider.js better-sqlite3 --copy-target better_sqlite3 --force-rebuild --root-dir ${WORKSPACE}"