https://github.com/angular/angular
Raw File
Tip revision: f815aa19914a8cd55dc8db2a41254248ee0b83c8 authored by Joey Perrott on 28 August 2020, 22:45:48 UTC
build: add configuration for the caretaker command (#38601)
Tip revision: f815aa1
check-node-modules
#!/usr/bin/env node

var checkNpm = require('./check-node-modules.js');

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
var nodeModulesOK = checkNpm(true, purgeIfStale);

process.exit( nodeModulesOK ? 0 : 1);

back to top