Add production dependencies
This commit is contained in:
parent
5a0114f3e2
commit
579ccdc29f
12113 changed files with 978046 additions and 3 deletions
41
node_modules/gulp-cli/lib/shared/ansi.js
generated
vendored
Normal file
41
node_modules/gulp-cli/lib/shared/ansi.js
generated
vendored
Normal file
|
@ -0,0 +1,41 @@
|
|||
'use strict';
|
||||
|
||||
var colors = require('ansi-colors');
|
||||
var supportsColor = require('color-support');
|
||||
|
||||
var hasColors = colorize();
|
||||
|
||||
/* istanbul ignore next */
|
||||
module.exports = {
|
||||
red: hasColors ? colors.red : noColor,
|
||||
green: hasColors ? colors.green : noColor,
|
||||
blue: hasColors ? colors.blue : noColor,
|
||||
magenta: hasColors ? colors.magenta : noColor,
|
||||
cyan: hasColors ? colors.cyan : noColor,
|
||||
white: hasColors ? colors.white : noColor,
|
||||
gray: hasColors ? colors.gray : noColor,
|
||||
bgred: hasColors ? colors.bgred : noColor,
|
||||
bold: hasColors ? colors.bold : noColor,
|
||||
yellow: hasColors ? colors.yellow : noColor,
|
||||
};
|
||||
|
||||
function noColor(message) {
|
||||
return message;
|
||||
}
|
||||
|
||||
function hasFlag(flag) {
|
||||
return (process.argv.indexOf('--' + flag) !== -1);
|
||||
}
|
||||
|
||||
function colorize() {
|
||||
if (hasFlag('no-color')) {
|
||||
return false;
|
||||
}
|
||||
|
||||
/* istanbul ignore if */
|
||||
if (hasFlag('color')) {
|
||||
return true;
|
||||
}
|
||||
|
||||
return supportsColor();
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue