m19c / gulp-run

Pipe to shell commands in gulp
ISC License
151 stars 25 forks source link

Received a non-Vinyl object #56

Open SET001 opened 5 years ago

SET001 commented 5 years ago

the example code:

gulp.task('hello-world', function() {
  return run('echo Hello World').exec()    // prints "Hello World\n".
    .pipe(gulp.dest('output'))      // writes "Hello World\n" to output/echo.
  ;
})

currently return error

[15:04:29] Error: Received a non-Vinyl object in dest() at DestroyableTransform.normalize [as _transform] (/home/set/www/cloudbeds/jarvis/node_modules/vinyl-fs/lib/dest/prepare.js:16:17) at DestroyableTransform.Transform._read (/home/set/www/cloudbeds/jarvis/node_modules/readable-stream/lib/_stream_transform.js:184:10) at DestroyableTransform.Transform._write (/home/set/www/cloudbeds/jarvis/node_modules/readable-stream/lib/_stream_transform.js:172:83) at doWrite (/home/set/www/cloudbeds/jarvis/node_modules/readable-stream/lib/_stream_writable.js:428:64) at writeOrBuffer (/home/set/www/cloudbeds/jarvis/node_modules/readable-stream/lib/_stream_writable.js:417:5) at DestroyableTransform.Writable.write (/home/set/www/cloudbeds/jarvis/node_modules/readable-stream/lib/_stream_writable.js:334:11) at Pumpify.Duplexify._write (/home/set/www/cloudbeds/jarvis/node_modules/duplexify/index.js:208:22) at doWrite (/home/set/www/cloudbeds/jarvis/node_modules/readable-stream/lib/_stream_writable.js:428:64) at writeOrBuffer (/home/set/www/cloudbeds/jarvis/node_modules/readable-stream/lib/_stream_writable.js:417:5) at Pumpify.Writable.write (/home/set/www/cloudbeds/jarvis/node_modules/readable-stream/lib/_stream_writable.js:334:11)

what I need is to write output of running command in file.

mig82 commented 4 years ago

Same problem here. I tried it with Gulp 4.0.2 and I got this. Went down to Gulp 3.9.1 and it works. So it seems there's been a breaking change somewhere in Gulp or Vinyl.

ITFO commented 4 years ago

No updates to fix this one up? We cannot stay to gulp 3.9.1 forever