Use anticipated 'echoIsTTY' member for ChakraCore host.

This commit is contained in:
Daniel Rosenwasser
2018-04-27 17:04:31 -07:00
parent 5d67f8ef68
commit 31c90ecf45
+4
View File
@@ -500,6 +500,7 @@ namespace ts {
executingFile: string;
newLine?: string;
useCaseSensitiveFileNames?: boolean;
echoIsTTY?: boolean;
echo(s: string): void;
quit(exitCode?: number): void;
fileExists(path: string): boolean;
@@ -1085,6 +1086,9 @@ namespace ts {
newLine: ChakraHost.newLine || "\r\n",
args: ChakraHost.args,
useCaseSensitiveFileNames: !!ChakraHost.useCaseSensitiveFileNames,
writeOutputIsTTY() {
return !!ChakraHost.echoIsTTY;
},
write: ChakraHost.echo,
readFile(path: string, _encoding?: string) {
// encoding is automatically handled by the implementation in ChakraHost