Mods/node_modules/gulp-print/lib/gulp-print.js
oitsjustjose 6b60015c02 --
2017-02-26 17:06:42 -05:00

31 lines
677 B
JavaScript

// Generated by CoffeeScript 1.10.0
var colors, green, log, magenta, map, path, print, ref;
map = require('map-stream');
path = require('path');
ref = require('gulp-util'), log = ref.log, colors = ref.colors;
green = colors.green, magenta = colors.magenta;
print = function(format) {
if (format == null) {
format = function(filepath) {
return filepath;
};
}
return map(function(file, cb) {
var filepath, formatted;
filepath = magenta(path.relative(process.cwd(), file.path));
formatted = format(filepath);
if (formatted) {
print.log(formatted);
}
return cb(null, file);
});
};
print.log = log;
module.exports = print;