-
Notifications
You must be signed in to change notification settings - Fork 1
/
gulpfile.js
42 lines (31 loc) · 861 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
33
34
35
36
37
38
39
40
41
42
var gulp = require("gulp");
var concat = require("gulp-concat");
var uglify = require("gulp-uglify");
var plumber = require("gulp-plumber");
var webserver = require("gulp-webserver");
var sass = require("gulp-sass");
gulp.task("build", function(){
gulp.src("./src/*.html")
.pipe(gulp.dest("./dist"));
gulp.src("./src/*.tag")
.pipe(gulp.dest("./dist"));
gulp.src("./src/js/*.js")
.pipe(uglify())
.pipe(gulp.dest("./dist/js"));
gulp.src("./src/sass/*.scss")
.pipe(sass())
.pipe(gulp.dest("./dist/css"));
});
gulp.task("watch", function(){
gulp.watch('./src/*.html', ["html"])
gulp.watch('./src/sass/*.scss', ["sass"])
gulp.watch('./src/*.tag', ["tag"])
gulp.src("./dist")
.pipe(
webserver({
host: "192.168.33.10",
livereload: true
})
);
});
gulp.task("default", ["build", "watch", "watch"]);