-
Notifications
You must be signed in to change notification settings - Fork 1
/
gulpfile.js
29 lines (25 loc) · 851 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
var fs = require('fs');
var yaml = require('js-yaml');
// var _ = require('lodash');
var gulp = require('gulp');
// var proxy = require('proxy-middleware');
// var url = require('url');
var browserSync = require('browser-sync');
try {
var options = yaml.safeLoad(fs.readFileSync('./config.yaml', 'utf-8'));
} catch (error) {
throw new Error(error);
}
var taskDependencies = (function() {
gulp.task('server', function() {
// var proxyMiddleware = proxy(
// _.assign(url.parse(options.proxyURL), options.proxyOptions)
// );
// options.browserSync.server.middleware.push(proxyMiddleware);
browserSync(options.browserSync);
});
return ['server'];
}());
gulp.task('default', taskDependencies, function() {
// Default Task Denifition
});