Log message for all commands

The first time you bootstrap, all the build modules and apm are
installed. Previously this was showing no output so it was unclear
whether things are hung or now.

This will also help easily identify which stage of the build
npm and node-gyp errors are occurring.
This commit is contained in:
Kevin Sawicki
2014-06-13 10:06:45 -07:00
parent fb0a15b1b3
commit 34be92b5b0

View File

@@ -10,6 +10,8 @@ function executeCommands(commands, done, index) {
index = (index == undefined ? 0 : index);
if (index < commands.length) {
var command = commands[index];
if (command.message)
console.log(command.message);
var options = null;
if (typeof command !== 'string') {
options = command.options;
@@ -36,12 +38,10 @@ function bootstrap() {
var npmFlags = ' --userconfig=' + path.resolve('.npmrc') + ' ';
var packagesToDedupe = ['fs-plus', 'humanize-plus', 'oniguruma', 'roaster', 'season', 'grim'];
var echoNewLine = process.platform == 'win32' ? 'echo.' : 'echo';
var commands = [
{command: initialNpmCommand + npmFlags + 'install --quiet', options: {cwd: path.resolve(__dirname, '..', 'build'), ignoreStdout: true}},
{command: npmPath + npmFlags + 'install --quiet', options: {cwd: apmInstallPath, ignoreStdout: true}},
echoNewLine,
{command: initialNpmCommand + npmFlags + 'install --quiet', message: 'Installing build modules...', options: {cwd: path.resolve(__dirname, '..', 'build'), ignoreStdout: true}},
{command: npmPath + npmFlags + 'install --quiet', message: 'Installing apm...', options: {cwd: apmInstallPath, ignoreStdout: true}},
apmPath + ' clean ' + apmFlags,
apmPath + ' install --quiet ' + apmFlags,
apmPath + ' dedupe --quiet ' + apmFlags + ' ' + packagesToDedupe.join(' '),