@@ -1673,13 +1673,13 @@ namespace ts {
1673
1673
const files = map (
1674
1674
filter (
1675
1675
configParseResult . fileNames ,
1676
- ! configParseResult . configFileSpecs ? _ => false : matchesSpecs (
1676
+ ( ! configParseResult . configFileSpecs || ! configParseResult . configFileSpecs . validatedIncludeSpecs ) ? _ => true : matchesSpecs (
1677
1677
configFileName ,
1678
1678
configParseResult . configFileSpecs . validatedIncludeSpecs ,
1679
1679
configParseResult . configFileSpecs . validatedExcludeSpecs
1680
1680
)
1681
1681
) ,
1682
- f => getRelativePathFromFile ( getNormalizedAbsolutePath ( configFileName , host . getCurrentDirectory ( ) ) , f , getCanonicalFileName )
1682
+ f => getRelativePathFromFile ( getNormalizedAbsolutePath ( configFileName , host . getCurrentDirectory ( ) ) , getNormalizedAbsolutePath ( f , host . getCurrentDirectory ( ) ) , getCanonicalFileName )
1683
1683
) ;
1684
1684
const optionMap = serializeCompilerOptions ( configParseResult . options , { configFilePath : getNormalizedAbsolutePath ( configFileName , host . getCurrentDirectory ( ) ) , useCaseSensitiveFileNames : host . useCaseSensitiveFileNames } ) ;
1685
1685
const config = {
@@ -1713,20 +1713,20 @@ namespace ts {
1713
1713
}
1714
1714
1715
1715
function matchesSpecs ( path : string , includeSpecs : ReadonlyArray < string > | undefined , excludeSpecs : ReadonlyArray < string > | undefined ) : ( path : string ) => boolean {
1716
- if ( ! includeSpecs ) return _ => false ;
1716
+ if ( ! includeSpecs ) return _ => true ;
1717
1717
const patterns = getFileMatcherPatterns ( path , excludeSpecs , includeSpecs , sys . useCaseSensitiveFileNames , sys . getCurrentDirectory ( ) ) ;
1718
1718
const excludeRe = patterns . excludePattern && getRegexFromPattern ( patterns . excludePattern , sys . useCaseSensitiveFileNames ) ;
1719
1719
const includeRe = patterns . includeFilePattern && getRegexFromPattern ( patterns . includeFilePattern , sys . useCaseSensitiveFileNames ) ;
1720
1720
if ( includeRe ) {
1721
1721
if ( excludeRe ) {
1722
- return path => includeRe . test ( path ) && ! excludeRe . test ( path ) ;
1722
+ return path => ! ( includeRe . test ( path ) && ! excludeRe . test ( path ) ) ;
1723
1723
}
1724
- return path => includeRe . test ( path ) ;
1724
+ return path => ! includeRe . test ( path ) ;
1725
1725
}
1726
1726
if ( excludeRe ) {
1727
- return path => ! excludeRe . test ( path ) ;
1727
+ return path => excludeRe . test ( path ) ;
1728
1728
}
1729
- return _ => false ;
1729
+ return _ => true ;
1730
1730
}
1731
1731
1732
1732
function getCustomTypeMapOfCommandLineOption ( optionDefinition : CommandLineOption ) : Map < string | number > | undefined {
0 commit comments