-
Notifications
You must be signed in to change notification settings - Fork 0
/
gulpfile.js
33 lines (31 loc) · 1.08 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
const gulp = require('gulp'),
gulpMerge = require('gulp-merge'),
concat = require('gulp-concat')
removeEmptyLines = require('gulp-remove-empty-lines');;
gulp.task('swagger', function () {
return gulpMerge(
gulp.src([
'api/swagger/info/info.yaml',
'api/swagger/tag/index.yaml',
'api/swagger/tag/category.yaml',
'api/swagger/tag/customer.yaml',
'api/swagger/tag/user.yaml',
'api/swagger/tag/image.yaml',
'api/swagger/path/index.yaml',
'api/swagger/path/category.yaml',
'api/swagger/path/customer.yaml',
'api/swagger/path/user.yaml',
'api/swagger/path/image.yaml',
'api/swagger/path/swagger.yaml',
'api/swagger/definition/index.yaml',
'api/swagger/definition/error_response.yaml',
'api/swagger/definition/category.yaml',
'api/swagger/definition/customer.yaml',
'api/swagger/definition/user.yaml',
])
)
.pipe(concat('swagger.yaml'))
.pipe(removeEmptyLines())
.pipe(gulp.dest('api/swagger/'));
});
gulp.task('build', ['swagger']);