-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathgulpfile.js
executable file
·44 lines (37 loc) · 933 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
43
44
var gulp = require('gulp');
var hologram = require('gulp-hologram');
var copy = require('gulp-copy');
var sync = require('run-sequence');
var browser = require('browser-sync');
/*
map of paths for using with the tasks below
*/
var paths = {
copyFiles: ['app/assets/images/**/*', 'app/index.html']
};
gulp.task('copyimages', function() {
return gulp.src(paths.copyFiles)
.pipe(gulp.dest('dist/images'));
});
gulp.task('copyindex', function() {
return gulp.src('app/index.html')
.pipe(gulp.dest('dist'));
});
gulp.task('copy', ['copyindex', 'copyimages']);
gulp.task('hologram', function() {
gulp.src('hologram_config.yml')
.pipe(hologram({logging:true}));
});
gulp.task('serve', function() {
browser({
port: process.env.PORT || 4500,
open: false,
ghostMode: false,
server: {
baseDir: 'dist'
}
});
});
gulp.task('default', function() {
sync('copy');
});