pipe
pipe copied to clipboard
doesn't work with gulp?
I'm trying to use this with gulp
Expected behavior:
With gulpfile.js:
var gulp = require('gulp');
var print = require('gulp-print');
gulp.task('test', function() {
return gulp.src('./**/*.*')
.pipe(print(p => 'file:' + p))
.pipe(gulp.dest('.'));
});
doing gulp test
:
$ gulp test
Starting 'test'...
file:gulpfile.js
Finished 'test' after 82 ms
It correctly shows "finished".
But using this pipe library it doesn't work:
gulpfile.js:
var gulp = require('gulp');
var print = require('gulp-print');
require('pipe').install();
gulp.task('test', function() {
return gulp.src('./**/*.*') |
print(p => 'file:' + p) |
gulp.dest('.');
});
$ gulp test
Starting 'test'...
file:gulpfile.js
The following tasks did not complete: test
Did you forget to signal async completion?
it doesn't finish.
gulp.src()
pipes to print()
correctly it seems, which means it's at least partially working.
Does gulp.dest()
not get piped for some reason?