chore(lint): extend linting to all modules and tools
This commit is contained in:
parent
e9fd8645ed
commit
6f412bb449
14
gulpfile.js
14
gulpfile.js
|
@ -129,15 +129,23 @@ gulp.task('public-api:update', ['build.sh'], (done) => {
|
||||||
gulp.task('lint', ['format:enforce', 'tools:build'], () => {
|
gulp.task('lint', ['format:enforce', 'tools:build'], () => {
|
||||||
const tslint = require('gulp-tslint');
|
const tslint = require('gulp-tslint');
|
||||||
// Built-in rules are at
|
// Built-in rules are at
|
||||||
// https://github.com/palantir/tslint#supported-rules
|
// https://palantir.github.io/tslint/rules/
|
||||||
const tslintConfig = require('./tslint.json');
|
const tslintConfig = require('./tslint.json');
|
||||||
return gulp
|
return gulp
|
||||||
.src([
|
.src([
|
||||||
// todo(vicb): add .js files when supported
|
// todo(vicb): add .js files when supported
|
||||||
// see https://github.com/palantir/tslint/pull/1515
|
// see https://github.com/palantir/tslint/pull/1515
|
||||||
'modules/@angular/**/*.ts',
|
'./modules/**/*.ts',
|
||||||
'modules/benchpress/**/*.ts',
|
'./tools/**/*.ts',
|
||||||
'./*.ts',
|
'./*.ts',
|
||||||
|
|
||||||
|
// Ignore TypeScript mocks because it's not managed by us
|
||||||
|
'!./tools/@angular/tsc-wrapped/test/typescript.mocks.ts',
|
||||||
|
|
||||||
|
// Ignore generated files due to lack of copyright header
|
||||||
|
// todo(alfaproject): make generated files lintable
|
||||||
|
'!**/*.d.ts',
|
||||||
|
'!**/*.ngfactory.ts',
|
||||||
])
|
])
|
||||||
.pipe(tslint({
|
.pipe(tslint({
|
||||||
tslint: require('tslint').default,
|
tslint: require('tslint').default,
|
||||||
|
|
Loading…
Reference in New Issue