Skip to content

Instantly share code, notes, and snippets.

@cognitom
Created October 5, 2014 02:22
Show Gist options
  • Save cognitom/f85932e8bca48194efe8 to your computer and use it in GitHub Desktop.
Save cognitom/f85932e8bca48194efe8 to your computer and use it in GitHub Desktop.
$ npm install -g gulp
$ npm install -g gulp-straw
$ straw setup
$ straw install gulpfile
$ straw install task/css
$ straw install cognitom:gulpfile
$ straw install cognitom:task/css
var gulp = require('gulp');
var del = require('del');
var runSequence = require('run-sequence');
var requireDir = require('require-dir');
var dir = requireDir('./task');
gulp.task('default', function (cb){
runSequence('clean', 'icon', 'build', cb); // gulp.js 3.xでの書き方
});
gulp.task('clean', function(cb){
del(['./dist'], cb);
});
gulp.task('watch', function(){
gulp.watch(['src/icon/*.svg'], { debounceDelay: 1000 }, ['icon']);
});
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment