File tree Expand file tree Collapse file tree 7 files changed +20
-14
lines changed
Expand file tree Collapse file tree 7 files changed +20
-14
lines changed Original file line number Diff line number Diff line change @@ -334,13 +334,17 @@ task("run-eslint-rules-tests").description = "Runs the eslint rule tests";
334334const lintFoldStart = async ( ) => { if ( fold . isTravis ( ) ) console . log ( fold . start ( "lint" ) ) ; } ;
335335const lintFoldEnd = async ( ) => { if ( fold . isTravis ( ) ) console . log ( fold . end ( "lint" ) ) ; } ;
336336const eslint = ( folder ) => async ( ) => {
337+ const ESLINTRC_CI = ".eslintrc.ci.json" ;
338+ const ESLINTRC = ".eslintrc.json" ;
339+ const isCIEnv = process . env . CI === "true" ;
340+ const config = isCIEnv && fs . existsSync ( path . resolve ( folder , ESLINTRC_CI ) ) ? ESLINTRC_CI : ESLINTRC ;
341+
337342 const args = [
338343 "node_modules/eslint/bin/eslint" ,
339- "--config" , `${ folder } /.eslintrc.json ` ,
344+ "--config" , `${ folder } /${ config } ` ,
340345 "--format" , "autolinkable-stylish" ,
341346 "--rulesdir" , "scripts/eslint/built/rules" ,
342- "--ext" , ".ts" ,
343- `${ folder } ` ,
347+ "--ext" , ".ts" , folder ,
344348 ] ;
345349
346350 if ( cmdLineOptions . fix ) {
Original file line number Diff line number Diff line change 55 "project" : [
66 " ./importDefinitelyTypedTests/tsconfig.json" ,
77 " ./eslint/tsconfig.json" ,
8- " ./tsconfig.json"
8+ " ./tsconfig.eslint. json"
99 ]
1010 }
1111}
Original file line number Diff line number Diff line change 1+ {
2+ "extends" : " ./tsconfig.json" ,
3+ "include" : [" *.ts" , " types" ]
4+ }
Original file line number Diff line number Diff line change 1111 "lib" : [" es6" , " scripthost" ],
1212 },
1313
14- "includes " : [
14+ "include " : [
1515 " generateLocalizedDiagnosticMessages.ts" ,
1616 " processDiagnosticMessages.ts" ,
1717 " configurePrerelease.ts" ,
18- " failed-tests.d.ts" ,
1918 " buildProtocol.ts" ,
2019 " produceLKG.ts" ,
2120 " word2md.ts"
22- ],
23-
24- "exclude" : [
25- " ambient.d.ts"
2621 ]
2722}
Original file line number Diff line number Diff line change 1+ {
2+ "extends" : " ./.eslintrc.json" ,
3+ "rules" : {
4+ "@typescript-eslint/no-unnecessary-qualifier" : " error" ,
5+ "@typescript-eslint/no-unnecessary-type-assertion" : " error"
6+ }
7+ }
Original file line number Diff line number Diff line change @@ -1342,11 +1342,9 @@ namespace ts {
13421342 rawTextScanner . setText ( "`" + rawText + "`" ) ;
13431343 break ;
13441344 case SyntaxKind . TemplateHead :
1345- // tslint:disable-next-line no-invalid-template-strings
13461345 rawTextScanner . setText ( "`" + rawText + "${" ) ;
13471346 break ;
13481347 case SyntaxKind . TemplateMiddle :
1349- // tslint:disable-next-line no-invalid-template-strings
13501348 rawTextScanner . setText ( "}" + rawText + "${" ) ;
13511349 break ;
13521350 case SyntaxKind . TemplateTail :
Original file line number Diff line number Diff line change @@ -599,10 +599,8 @@ namespace ts {
599599 case SyntaxKind . NoSubstitutionTemplateLiteral :
600600 return "`" + rawText + "`" ;
601601 case SyntaxKind . TemplateHead :
602- // tslint:disable-next-line no-invalid-template-strings
603602 return "`" + rawText + "${" ;
604603 case SyntaxKind . TemplateMiddle :
605- // tslint:disable-next-line no-invalid-template-strings
606604 return "}" + rawText + "${" ;
607605 case SyntaxKind . TemplateTail :
608606 return "}" + rawText + "`" ;
You can’t perform that action at this time.
0 commit comments