mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-17 11:24:29 -05:00
update regex for filename
This commit is contained in:
@@ -2056,7 +2056,7 @@
|
||||
"category": "Error",
|
||||
"code": 5054
|
||||
},
|
||||
"The project file name is not in 'tsconfig-*.json' format: '{0}'": {
|
||||
"The project file name is not in 'tsconfig(-*).json' format: '{0}'": {
|
||||
"category": "Error",
|
||||
"code": 5055
|
||||
},
|
||||
|
||||
@@ -186,11 +186,11 @@ namespace ts {
|
||||
}
|
||||
|
||||
let fileOrDirectory = normalizePath(commandLine.options.project);
|
||||
if (!fileOrDirectory || sys.directoryExists(fileOrDirectory)) {
|
||||
if (!fileOrDirectory /* current directory */ || sys.directoryExists(fileOrDirectory)) {
|
||||
configFileName = combinePaths(fileOrDirectory, "tsconfig.json");
|
||||
}
|
||||
else {
|
||||
if (!/^tsconfig.*\.json$/.test(getBaseFileName(fileOrDirectory))) {
|
||||
if (!/^tsconfig(?:-.*)?.json$/.test(getBaseFileName(fileOrDirectory))) {
|
||||
reportDiagnostic(createCompilerDiagnostic(Diagnostics.The_project_file_name_is_not_in_tsconfig_Asterisk_json_format_Colon_0, commandLine.options.project));
|
||||
return sys.exit(ExitStatus.DiagnosticsPresent_OutputsSkipped);
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user