Created
September 20, 2015 12:09
-
-
Save mikezhuyuan/7a9fc9ca365caa4aed10 to your computer and use it in GitHub Desktop.
This file contains 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
var map = require('map-stream'); | |
var gulp = require('gulp'); | |
var htmlsrc = require('./htmlsrc.js'); | |
gulp.task('default', function() { | |
//gulp.src('src/**/*.js') | |
// .pipe(map(function(file, next) { | |
// console.dir(file); | |
// next(null, file); | |
// })) | |
htmlsrc('index.html', function($) { | |
var files = []; | |
$('script').each(function() { | |
files.push($(this).attr('src')); | |
}); | |
return files; | |
}, {read: true}) | |
.pipe(gulp.dest('dist')); | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment