/
gulpfile.js
65 lines (59 loc) · 2.18 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
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
const gulp = require( 'gulp' ),
nicePageBuilder = require( './index.js' );
gulp.task( 'tutorial_1', function(){
return gulp.src( [ './tutorial/1/source/**/*.html', '!./tutorial/1/source/templete.html' ]
).pipe(
nicePageBuilder( {
srcRootPath : './tutorial/1/source'
} )
).pipe( gulp.dest( './tutorial/1/output' ) );
}
);
gulp.task( 'tutorial_2', function(){
return gulp.src( [ './tutorial/2/source/**/*.html', '!templete.html' ]
).pipe(
nicePageBuilder( {
srcRootPath : './tutorial/2/source'
} )
).pipe( gulp.dest( './tutorial/2/output' ) );
}
);
gulp.task( 'tutorial_3', function(){
return gulp.src( [ './tutorial/3/source/**/*.html', '!templete.html' ]
).pipe(
nicePageBuilder( {
srcRootPath : './tutorial/3/source'
} )
).pipe( gulp.dest( './tutorial/3/output' ) );
}
);
gulp.task( 'tutorial_4', function(){
return gulp.src( [ './tutorial/4/source/**/*.html', '!templete.html' ]
).pipe(
nicePageBuilder( {
srcRootPath : './tutorial/4/source'
} )
).pipe( gulp.dest( './tutorial/4/output' ) );
}
);
gulp.task( 'tutorial_5', function(){
return gulp.src( [ './tutorial/5/source/**/*.html', '!templete.html' ]
).pipe(
nicePageBuilder( {
srcRootPath : './tutorial/5/source'
} )
).pipe( gulp.dest( './tutorial/5/output' ) );
}
);
gulp.task( 'tutorial_6', function(){
return gulp.src( [ './tutorial/6/source/**/*.html', '!templete.html' ]
).pipe(
nicePageBuilder( {
srcRootPath : './tutorial/6/source',
json : {
favorites : './tutorial/json/favorites.json'
}
} )
).pipe( gulp.dest( './tutorial/6/output' ) );
}
);