-
Notifications
You must be signed in to change notification settings - Fork 0
/
Gulpfile.js
43 lines (35 loc) · 1.04 KB
/
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
'use strict';
var gulp = require('gulp'),
nodemon = require('gulp-nodemon'),
bs = require('browser-sync'),
reload = bs.reload,
when = require('gulp-if'),
shell = require('gulp-shell');
// the paths to our app files
var paths = {
// all our client app js files, not including 3rd party js files
scripts: ['client/app/**/*.js'],
html: ['client/app/**/*.html', 'client/index.html'],
styles: ['client/styles/style.css'],
test: ['specs/**/*.js']
};
// any changes made to your
// client side code will automagically refresh your page
// with the new changes
gulp.task('start', ['serve'],function () {
bs({
notify: true,
// address for server,
injectChanges: true,
files: paths.scripts.concat(paths.html, paths.styles),
proxy: 'localhost:8000'
});
});
gulp.task('karma', shell.task([
'karma start'
]));
// start our node server using nodemon
gulp.task('serve', function() {
nodemon({script: './server/server.js', ignore: 'node_modules/**/*.js'});
});
gulp.task('default', ['start']);