forked from superhawk610/multicast
-
Notifications
You must be signed in to change notification settings - Fork 0
/
gulpfile.js
32 lines (28 loc) · 940 Bytes
/
gulpfile.js
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
const gulp = require('gulp')
const uglify = require('gulp-uglify-es').default
const cleanCSS = require('gulp-clean-css')
gulp.task('js', () => {
return gulp
.src('build/js/*')
.pipe(uglify().on('error', err => console.log(err)))
.pipe(gulp.dest('public/js'))
})
gulp.task('css', () => {
return gulp
.src('build/css/*')
.pipe(cleanCSS())
.pipe(gulp.dest('public/css'))
})
gulp.task('vendor', () => {
gulp
.src('node_modules/jquery/dist/jquery.min.js')
.pipe(gulp.dest('public/js'))
gulp
.src('node_modules/spectre.css/dist/spectre.min.css')
.pipe(gulp.dest('public/css'))
gulp.src('node_modules/font-awesome/css/*').pipe(gulp.dest('public/css'))
gulp.src('node_modules/font-awesome/fonts/*').pipe(gulp.dest('public/fonts'))
gulp.src('node_modules/bowser/bowser.min.js').pipe(gulp.dest('public/js'))
})
gulp.task('default', ['js', 'css', 'vendor'])
gulp.task('minify', ['js', 'css'])