-
Notifications
You must be signed in to change notification settings - Fork 35
Expand file tree
/
Copy pathgulpfile.js
More file actions
35 lines (29 loc) · 710 Bytes
/
gulpfile.js
File metadata and controls
35 lines (29 loc) · 710 Bytes
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
/* eslint-disable no-console */
'use strict';
var gulp = require('gulp');
var childProcess = require('child_process');
var eslint = require('gulp-eslint');
var realCodePaths = [
'**/*.{js,jsx,coffee}',
'!node_modules/**',
'!lib/route/compiled-grammar.js',
'!coverage/**',
'!docs/**'
];
gulp.task('lint', function () {
gulp.src(realCodePaths)
.pipe(eslint())
.pipe(eslint.format());
});
gulp.task('jsdoc', function () {
childProcess.exec(
'./node_modules/.bin/jsdoc -c jsdoc.json',
function (error, stdout, stderr) {
console.log(stdout);
console.error(stderr);
}
);
});
gulp.task('default', function () {
gulp.watch(realCodePaths, ['lint', 'jsdoc']);
});