diff --git a/src/compiler/tsc.ts b/src/compiler/tsc.ts index 245d5c2219cf3..3a340f049f862 100644 --- a/src/compiler/tsc.ts +++ b/src/compiler/tsc.ts @@ -399,4 +399,8 @@ if (ts.Debug.isDebugging) { if (ts.sys.tryEnableSourceMapsForHost && /^development$/i.test(ts.sys.getEnvironmentVariable("NODE_ENV"))) { ts.sys.tryEnableSourceMapsForHost(); } +declare var process: any; +if (process && process.stdout && process.stdout._handle && process.stdout._handle.setBlocking) { + process.stdout._handle.setBlocking(true); +} ts.executeCommandLine(ts.sys.args); diff --git a/src/server/server.ts b/src/server/server.ts index f70280c34a3de..2529008c1656b 100644 --- a/src/server/server.ts +++ b/src/server/server.ts @@ -991,6 +991,7 @@ namespace ts.server { ioSession.logError(err, "unknown"); }); // See https://github.com/Microsoft/TypeScript/issues/11348 + // tslint:disable-next-line no-unnecessary-type-assertion-2 (process as any).noAsar = true; // Start listening ioSession.listen();