gulp plugin for command line notification
Install with npm
npm install gulp-msg
var msg = require('gulp-msg');
msg.Info('--', 'Notice!', '*');
msg.Info ('style: <%= name %>', {name: 'info'});
msg.Success('style: <%= name %>', {name: 'success'});
msg.Warning('style: <%= name %>', {name: 'warning'});
msg.Error ('style: <%= name %>', {name: 'error'});
msg.Note ('style: <%= name %>', {name: 'note'});
msg.Time ('style: <%= name %>', {name: 'time'});
For example info
Use msg.info
for each file into the stream
gulp.src('src/**/*')
.pipe(msg.info('Notice!')); //'Notice!' for each file
Use msg.flush.info
at the and of the stream
gulp.src('src/**/*')
.pipe(msg.flush.info('Notice!')); //'Notice!' at the and of stream
Use msg.Info
from the outside of the stream
msg.Info('Notice!'); //'Notice!' in node.js application
Show message
Type: String
Delimiter before/after the message. Each character is repeated 40 times
msg.Info('--', 'Notice!', '*')
Type: Object
Data for message. Inherited values:
env - process.env file - vinyl file file.relative - relative path (extra field) file.basename - basename (extra field) duration - duration of streaming totalDuration - duration from gulpfile start
Type: String
Lodash template.
msg.Info('Enviroment: <%= env.NODE_ENV %>. Foo: <%= foo %>', {foo: bar})
//Enviroment: dev. Foo: bar
Copyright (c) 2014-2015 Oleg Istomin Released under the MIT license