-
Notifications
You must be signed in to change notification settings - Fork 1
Expand file tree
/
Copy pathgulpfile.js
More file actions
30 lines (25 loc) · 718 Bytes
/
gulpfile.js
File metadata and controls
30 lines (25 loc) · 718 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
// Load Gulp
var gulp = require('gulp'),
gutil = require('gulp-util'),
plugins = require('gulp-load-plugins')({
rename: {
'gulp-live-server': 'serve'
}
});
// Start Watching: Run "gulp"
gulp.task('default', ['serve']);
// Run "gulp server"
gulp.task('server', ['serve', 'watch']);
// Default task
gulp.task('watch', function () {
gulp.watch('*.php', [""]);
});
// Folder "/" serving at http://localhost:8888
// Should use Livereload (http://livereload.com/extensions/)
gulp.task('serve', function () {
var server = plugins.serve.static('/', 8888);
server.start();
gulp.watch(['*'], function (file) {
server.notify.apply(server, [file]);
});
});