build(npm): upgrade to npm v3

Closes #3193
This commit is contained in:
Brian Ford
2015-12-21 14:50:56 -08:00
committed by Igor Minar
parent 47a3b4d56b
commit 6cfc6f5bb2
12 changed files with 5162 additions and 5122 deletions

View File

@ -2,6 +2,9 @@
var checkNpm = require('./check-node-modules.js');
var purgeIfStale = (process.argv.indexOf('--purge') !== -1)
var purgeIfStale = (process.argv.indexOf('--purge') !== -1);
// check-node-modules will exit(1) if we don't need to install to short-circuit `npm install`
// see .travis.yml's `install` block to see the reason for this
process.exit(checkNpm(true, purgeIfStale) ? 1 : 0);
checkNpm(true, purgeIfStale);

View File

@ -4,7 +4,7 @@ var fs = require('fs');
var path = require('path');
var NPM_SHRINKWRAP_FILE = 'npm-shrinkwrap.json';
var NPM_SHRINKWRAP_CACHED_FILE = 'node_modules/npm-shrinkwrap.cached.json';
var NPM_SHRINKWRAP_CACHED_FILE = 'node_modules/.npm-shrinkwrap.cached.json';
var FS_OPTS = {encoding: 'utf-8'};
var PROJECT_ROOT = path.join(__dirname, '../../');

View File

@ -4,7 +4,7 @@ var fse = require('fs-extra');
var path = require('path');
var NPM_SHRINKWRAP_FILE = 'npm-shrinkwrap.json';
var NPM_SHRINKWRAP_CACHED_FILE = 'node_modules/npm-shrinkwrap.cached.json';
var NPM_SHRINKWRAP_CACHED_FILE = 'node_modules/.npm-shrinkwrap.cached.json';
var PROJECT_ROOT = path.join(__dirname, '../../');
process.chdir(PROJECT_ROOT);