Comparing version 2.2.14 to 2.2.15
var colors = require('./colors'); | ||
var date = require('./date'); | ||
module.exports = function(){ | ||
var sig = '['+colors.green('gulp')+']'; | ||
var time = '['+colors.grey(date(new Date(), 'HH:MM:ss'))+']'; | ||
var args = Array.prototype.slice.call(arguments); | ||
args.unshift(time); | ||
args.unshift(sig); | ||
console.log.apply(console, args); | ||
return this; | ||
}; | ||
}; |
{ | ||
"name": "gulp-util", | ||
"description": "Utility functions for gulp plugins", | ||
"version": "2.2.14", | ||
"version": "2.2.15", | ||
"homepage": "http://github.com/wearefractal/gulp-util", | ||
@@ -10,22 +10,22 @@ "repository": "git://github.com/wearefractal/gulp-util.git", | ||
"dependencies": { | ||
"chalk": "~0.4.0", | ||
"lodash.template": "~2.4.1", | ||
"lodash._reinterpolate": "~2.4.1", | ||
"vinyl": "~0.2.1", | ||
"through2": "~0.4.0", | ||
"dateformat": "~1.0.7-1.2.3", | ||
"multipipe": "~0.0.1", | ||
"minimist": "~0.0.5" | ||
"chalk": "^0.4.0", | ||
"lodash.template": "^2.4.1", | ||
"lodash._reinterpolate": "^2.4.1", | ||
"vinyl": "^0.2.1", | ||
"through2": "^0.4.0", | ||
"dateformat": "^1.0.7-1.2.3", | ||
"multipipe": "^0.1.0", | ||
"minimist": "^0.1.0" | ||
}, | ||
"devDependencies": { | ||
"mocha": "~1.17.0", | ||
"should": "~3.1.2", | ||
"mocha-lcov-reporter": "~0.0.1", | ||
"coveralls": "~2.7.0", | ||
"istanbul": "~0.2.3", | ||
"rimraf": "~2.2.5", | ||
"jshint": "~2.4.1", | ||
"buffer-equal": "0.0.0", | ||
"lodash.templatesettings": "~2.4.1", | ||
"event-stream": "~3.1.0" | ||
"mocha": "^1.17.0", | ||
"should": "^4.0.0", | ||
"mocha-lcov-reporter": "^0.0.1", | ||
"coveralls": "^2.7.0", | ||
"istanbul": "^0.2.3", | ||
"rimraf": "^2.2.5", | ||
"jshint": "^2.4.1", | ||
"buffer-equal": "~0.0.1", | ||
"lodash.templatesettings": "^2.4.1", | ||
"event-stream": "^3.1.0" | ||
}, | ||
@@ -32,0 +32,0 @@ "scripts": { |
@@ -1,2 +0,2 @@ | ||
# gulp-util [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Coveralls Status][coveralls-image]][coveralls-url] [![Dependency Status](https://david-dm.org/gulpjs/gulp-util.png?theme=shields.io)](https://david-dm.org/gulpjs/gulp-util) | ||
# gulp-util [![NPM version][npm-image]][npm-url] [![Build Status][travis-image]][travis-url] [![Coveralls Status][coveralls-image]][coveralls-url] [![Dependency Status][depstat-image]][depstat-url] | ||
@@ -45,14 +45,2 @@ ## Information | ||
### colors | ||
This is an instance of [chalk](https://github.com/sindresorhus/chalk) | ||
### date | ||
This is an instance of [node-dateformat](https://github.com/felixge/node-dateformat). | ||
### linefeed | ||
Just `\n`. Use this. | ||
### replaceExtension(path, newExtension) | ||
@@ -94,3 +82,3 @@ | ||
.pipe(concat('script.js')) | ||
.pipe(gulp.env.production ? uglify() : gutil.noop()) | ||
.pipe(gutil.env.type === 'production' ? uglify() : gutil.noop()) | ||
.pipe(gulp.dest('dist/'); | ||
@@ -100,19 +88,2 @@ }); | ||
## combine(streams...) | ||
Argument may also be an array of streams. Returns a function that returns the combined stream. Useful for keeping things DRY. This is a simple wrapper around event-stream's `.pipeline` | ||
```javascript | ||
var scripts = gutil.combine( | ||
coffee({bare: true}), | ||
uglify(), | ||
concat('script.js'), | ||
gulp.dest('dist/') | ||
); | ||
gulp.task('default', function() { | ||
gulp.src('*.coffee').pipe(scripts()); | ||
}); | ||
``` | ||
## buffer(cb) | ||
@@ -163,8 +134,8 @@ | ||
[npm-url]: https://npmjs.org/package/gulp-util | ||
[npm-image]: https://badge.fury.io/js/gulp-util.png | ||
[npm-image]: https://badge.fury.io/js/gulp-util.svg | ||
[travis-url]: https://travis-ci.org/gulpjs/gulp-util | ||
[travis-image]: https://travis-ci.org/gulpjs/gulp-util.png?branch=master | ||
[travis-image]: https://travis-ci.org/gulpjs/gulp-util.svg?branch=master | ||
[coveralls-url]: https://coveralls.io/r/gulpjs/gulp-util | ||
[coveralls-image]: https://coveralls.io/repos/gulpjs/gulp-util/badge.png | ||
[depstat-url]: https://david-dm.org/gulpjs/gulp-util | ||
[depstat-image]: https://david-dm.org/gulpjs/gulp-util.png | ||
[depstat-image]: https://david-dm.org/gulpjs/gulp-util.svg |
@@ -17,3 +17,4 @@ var util = require('../'); | ||
util.log(1, 2, 3, 4, 'five'); | ||
writtenValue.should.eql('['+util.colors.green('gulp')+'] 1 2 3 4 five\n'); | ||
var time = util.date(new Date(), 'HH:MM:ss'); | ||
writtenValue.should.eql('['+util.colors.green('gulp')+'] [' + util.colors.grey(time) + '] 1 2 3 4 five\n'); | ||
@@ -24,2 +25,2 @@ // Restore process.stdout.write | ||
}); | ||
}); | ||
}); |
573
24881
138
+ Addedduplexer2@0.0.2(transitive)
+ Addedminimist@0.1.0(transitive)
+ Addedmultipipe@0.1.2(transitive)
+ Addedreadable-stream@1.1.14(transitive)
- Removedduplexer2@0.0.1(transitive)
- Removedminimist@0.0.10(transitive)
- Removedmultipipe@0.0.2(transitive)
Updatedchalk@^0.4.0
Updateddateformat@^1.0.7-1.2.3
Updatedlodash._reinterpolate@^2.4.1
Updatedlodash.template@^2.4.1
Updatedminimist@^0.1.0
Updatedmultipipe@^0.1.0
Updatedthrough2@^0.4.0
Updatedvinyl@^0.2.1