From 785e55db8de2b852a50cf87bbe6c467524f9b1f1 Mon Sep 17 00:00:00 2001 From: Tingan Ho Date: Sat, 20 Feb 2016 10:25:16 +0800 Subject: [PATCH 1/2] Fixes outDir exclude --- src/compiler/tsc.ts | 11 +++++++---- 1 file changed, 7 insertions(+), 4 deletions(-) diff --git a/src/compiler/tsc.ts b/src/compiler/tsc.ts index e5b85a7391e..9f68809c389 100644 --- a/src/compiler/tsc.ts +++ b/src/compiler/tsc.ts @@ -710,16 +710,19 @@ namespace ts { else { const compilerOptions = extend(options, defaultInitCompilerOptions); const configurations: any = { - compilerOptions: serializeCompilerOptions(compilerOptions) + compilerOptions: serializeCompilerOptions(compilerOptions) }; if (fileNames && fileNames.length) { // only set the files property if we have at least one file configurations.files = fileNames; } - else { - configurations.exclude = ["node_modules"]; - } + else { + configurations.exclude = ["node_modules"]; + if (compilerOptions.outDir) { + configurations.exclude.push(compilerOptions.outDir); + } + } sys.writeFile(file, JSON.stringify(configurations, undefined, 4)); reportDiagnostic(createCompilerDiagnostic(Diagnostics.Successfully_created_a_tsconfig_json_file), /* compilerHost */ undefined); From 30294c7fc02ff78103307ae8c2608a84be205466 Mon Sep 17 00:00:00 2001 From: Tingan Ho Date: Sat, 20 Feb 2016 11:54:09 +0800 Subject: [PATCH 2/2] Fixes linting issues --- src/server/protocol.d.ts | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/server/protocol.d.ts b/src/server/protocol.d.ts index 3a669753323..b8207570ea2 100644 --- a/src/server/protocol.d.ts +++ b/src/server/protocol.d.ts @@ -469,7 +469,7 @@ declare namespace ts.server.protocol { placeOpenBraceOnNewLineForControlBlocks?: boolean; /** Index operator */ - [key: string] : string | number | boolean; + [key: string]: string | number | boolean; } /**