Permalink
Browse files

Only include marketmaker binary for the current platform (#124)

  • Loading branch information...
sindresorhus committed Apr 18, 2018
1 parent efc050a commit 6305f28c2a6a2d33dfdfc8a7242e146bb33857f2
@@ -1,14 +1,3 @@
node_modules
/dist
/app/renderer-dist
/app/marketmaker/bin/**/*
!/app/marketmaker/bin/darwin
!/app/marketmaker/bin/linux
!/app/marketmaker/bin/win32
!/app/marketmaker/bin/darwin/marketmaker
!/app/marketmaker/bin/linux/marketmaker
!/app/marketmaker/bin/win32/marketmaker.exe
!/app/marketmaker/bin/win32/libcurl.dll
!/app/marketmaker/bin/win32/nanomsg.dll
!/app/marketmaker/bin/win32/msvcp140.dll
!/app/marketmaker/bin/win32/vcruntime140.dll
@@ -10,7 +10,14 @@ const getPort = require('get-port');
const logger = require('electron-timber');
const makeDir = require('make-dir');
let binPath = path.join(__dirname, 'bin', process.platform, `marketmaker${util.is.windows ? '.exe' : ''}`);
// `electron-builder` uses different names
const platformMapping = new Map([
['darwin', 'mac'],
['linux', 'linux'],
['win32', 'win'],
]);
let binPath = path.join(__dirname, 'bin', platformMapping.get(process.platform), `marketmaker${util.is.windows ? '.exe' : ''}`);
binPath = util.fixPathForAsarUnpack(binPath);
const execFile = nodeUtil.promisify(childProcess.execFile);
@@ -108,7 +108,9 @@
"build": {
"files": [
"**/*",
"!renderer${/*}"
"!renderer${/*}",
"!marketmaker/bin/*",
"marketmaker/bin/${os}"
],
"asarUnpack": [
"marketmaker/bin"
Oops, something went wrong.

0 comments on commit 6305f28

Please sign in to comment.