复制 src/fonts/
文件到 dist/
中
gulp.task('watchcopy', function () { |
gulp.watch('src/fonts/**/*', function (event) { |
var paths = watchPath(event) |
gutil.log(gutil.colors.green(event.type) + ' ' + paths.srcPath) |
gutil.log('Dist ' + paths.distPath) |
gulp.src(paths.srcPath) |
.pipe(gulp.dest(paths.distDir)) |
}) |
}) |
gulp.task('copy', function () { |
gulp.src('src/fonts/**/*') |
.pipe(gulp.dest('dist/fonts/')) |
}) |
gulp.task('default', ['watchjs', 'watchcss', 'watchless', 'watchsass', 'watchimage', 'watchcopy']) |