Currently I've got:
var gulp = require('gulp');
var $ = require('gulp-load-plugins')();
gulp.task('copyFolderOne', function () {
return gulp.src('folderOne/**')
.pipe(gulp.dest('dist/'))
.pipe($.size());
});
gulp.task('copyFolderTwo', function () {
return gulp.src('folderTwo/**')
.pipe(gulp.dest('dist/sub_folder/'))
.pipe($.size());
});
gulp.task('default', ['copyFolderOne', 'copyFolderTwo'], function () {
return gulp.src('dist/**')
.pipe($.zip('my_zip.zip'))
.pipe(gulp.dest('dist'))
.pipe($.size());
});
to copy two folders to a folder with sub a folder and zip them up using gulp.
This works. But I have to create two extra tasks and I'm not sure if I take advantages of streams. Thanks in advance.