Skip to content

Instantly share code, notes, and snippets.

@rorhug
Created February 9, 2014 17:12
Show Gist options
  • Save rorhug/8902316 to your computer and use it in GitHub Desktop.
Save rorhug/8902316 to your computer and use it in GitHub Desktop.
merging streams
// Sass and css libs
gulp.task('css', function () {
var sassStream = gulp.src('./assets/*.scss').pipe(sass());
var cssFiles = gulp.src('./assets/csslib/*.css');
var queue = new StreamQueue();
queue.queue(
cssFiles,
sassStream
);
queue.done();
queue.pipe(concat('comp.css'))
.pipe(gulp.dest('./public/css'));
});
@nfroidure
Copy link

// Sass and css libs
gulp.task('css', function () {
  var sassStream = gulp.src('./assets/*.scss').pipe(sass());
  var cssFiles = gulp.src('./assets/csslib/*.css');
  new StreamQueue({objectMode: true},
    cssFiles,
    sassStream
  ).pipe(concat('comp.css'))
    .pipe(gulp.dest('./public/css'));
});

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment