File tree Expand file tree Collapse file tree 2 files changed +10
-7
lines changed Expand file tree Collapse file tree 2 files changed +10
-7
lines changed Original file line number Diff line number Diff line change @@ -335,22 +335,28 @@ const lintFoldStart = async () => { if (fold.isTravis()) console.log(fold.start(
335
335
const lintFoldEnd = async ( ) => { if ( fold . isTravis ( ) ) console . log ( fold . end ( "lint" ) ) ; } ;
336
336
const eslint = ( folder ) => async ( ) => {
337
337
const ESLINTRC_CI = ".eslintrc.ci.json" ;
338
- const ESLINTRC = ".eslintrc.json" ;
339
338
const isCIEnv = cmdLineOptions . ci || process . env . CI === "true" ;
340
- const config = isCIEnv && fs . existsSync ( path . resolve ( folder , ESLINTRC_CI ) ) ? ESLINTRC_CI : ESLINTRC ;
341
339
342
340
const args = [
343
341
"node_modules/eslint/bin/eslint" ,
344
- "--config" , `${ folder } /${ config } ` ,
345
342
"--format" , "autolinkable-stylish" ,
346
343
"--rulesdir" , "scripts/eslint/built/rules" ,
347
- "--ext" , ".ts" , folder ,
344
+ "--ext" , ".ts" ,
348
345
] ;
349
346
347
+ if (
348
+ isCIEnv &&
349
+ fs . existsSync ( path . resolve ( folder , ESLINTRC_CI ) )
350
+ ) {
351
+ args . push ( "--config" , path . resolve ( folder , ESLINTRC_CI ) ) ;
352
+ }
353
+
350
354
if ( cmdLineOptions . fix ) {
351
355
args . push ( "--fix" ) ;
352
356
}
353
357
358
+ args . push ( folder ) ;
359
+
354
360
log ( `Linting: ${ args . join ( " " ) } ` ) ;
355
361
return exec ( process . execPath , args ) ;
356
362
}
Load Diff This file was deleted.
You can’t perform that action at this time.
0 commit comments