-
Notifications
You must be signed in to change notification settings - Fork 10
Expand file tree
/
Copy pathgulpfile.js
More file actions
35 lines (31 loc) · 872 Bytes
/
gulpfile.js
File metadata and controls
35 lines (31 loc) · 872 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
var autoprefixer = require('gulp-autoprefixer');
var csslint = require('gulp-csslint');
var gulp = require('gulp');
var jshint = require('gulp-jshint');
var umd = require('gulp-umd');
gulp.task('jsbuild', function() {
return gulp.src('src/*.js')
.pipe(jshint())
.pipe(jshint.reporter('default'))
.pipe(umd({
exports: function(file) {
return 'materialDesignHamburger';
},
namespace: function(file) {
return 'materialDesignHamburger';
}
}))
.pipe(gulp.dest('dist'));
});
gulp.task('cssbuild', function() {
return gulp.src('src/*.css')
.pipe(csslint())
.pipe(csslint.reporter())
.pipe(autoprefixer())
.pipe(gulp.dest('dist'));
});
gulp.task('watch', function() {
gulp.watch('src/*.css', ['cssbuild']);
gulp.watch('src/*.js', ['jsbuild']);
});
gulp.task('build', ['cssbuild', 'jsbuild']);