Skip to content

Commit fd13537

Browse files
committed
fix(mac-notifier): Manually install on darwin (for now)
1 parent 018ee4e commit fd13537

File tree

1 file changed

+17
-0
lines changed

1 file changed

+17
-0
lines changed

script/bootstrap

Lines changed: 17 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -25,6 +25,16 @@ function makeSqlite3Command() {
2525
return npmPath + " install https://github.com/bengotow/better-sqlite3/archive/a888061ad334c76d2db4c06554c90785cc6e7cce.tar.gz --ignore-scripts && cd node_modules/better-sqlite3 && "+nodeGypPath+" configure rebuild --msvs_version=2013 --target="+targetElectronVersion+" --arch="+targetArch+" --target_platform="+targetPlatform+" --dist-url=https://atom.io/download/atom-shell"
2626
}
2727

28+
function makeNodeMacNotifierCommand() {
29+
var nodeGypPath = '"' + path.resolve(__dirname, '..', 'build', 'node_modules', 'npm', 'node_modules', '.bin', 'node-gyp') + '"';
30+
var targetArch = require('os').arch();
31+
32+
// Use our local version of npm (npm 3x) to build sqlite
33+
var npmPath = '"' + path.resolve(__dirname, '..', 'build', 'node_modules', '.bin', 'npm') + '"';
34+
return npmPath + " install node-mac-notifier --ignore-scripts && cd node_modules/node-mac-notifier && "+nodeGypPath+" configure rebuild --msvs_version=2013 --target="+targetElectronVersion+" --arch="+targetArch+" --target_platform="+targetPlatform+" --dist-url=https://atom.io/download/atom-shell"
35+
}
36+
37+
2838

2939
// Executes an array of commands in series
3040
function executeCommands(commands, done, index) {
@@ -240,6 +250,13 @@ function bootstrap() {
240250
},
241251
]);
242252

253+
if (process.platform === 'darwin') {
254+
commands.push({
255+
command: makeNodeMacNotifierCommand(),
256+
message: "Building node-mac-notifier"
257+
});
258+
}
259+
243260
process.chdir(path.dirname(__dirname));
244261
executeCommands(commands, function() {
245262
console.log("---------------------------------------------");

0 commit comments

Comments
 (0)