Created
January 11, 2015 18:00
-
-
Save mbildner/b904c09515089d37135b to your computer and use it in GitHub Desktop.
merge gulp streams *IN ORDER*
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* jshint node: true */ | |
'use strict'; | |
var gulp = require('gulp'); | |
var mainBowerFiles = require('main-bower-files'); | |
var concat = require('gulp-concat'); | |
var merge = require('gulp-merge'); | |
gulp.task('all', function () { | |
var bower = gulp.src(mainBowerFiles()); | |
var app = gulp.src(['app.js']); | |
return merge(bower, app) | |
.pipe(concat('all.js')) | |
.pipe(gulp.dest('dist')); | |
}); | |
gulp.task('default', ['all']); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
@mkstix6 I solved this issue by using gulp-order. In this gist example you'd need gulp-rename as well:
I use this technique to merge css from vendors and my own
Hope it helps