mirror of
https://github.com/microsoft/TypeScript.git
synced 2026-05-15 04:43:37 -05:00
Support '/dev/stdout' as a valid '--out' parameter
This commit is contained in:
committed by
Martin Vseticka
parent
ae2faf83ba
commit
30499e7ee5
@@ -336,7 +336,17 @@ namespace ts {
|
||||
data = "\uFEFF" + data;
|
||||
}
|
||||
|
||||
_fs.writeFileSync(fileName, data, "utf8");
|
||||
let fd: number;
|
||||
|
||||
try {
|
||||
fd = _fs.openSync(fileName, "w");
|
||||
_fs.writeSync(fd, data, undefined, "utf8");
|
||||
}
|
||||
finally {
|
||||
if (fd !== undefined) {
|
||||
_fs.closeSync(fd);
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
function getCanonicalPath(path: string): string {
|
||||
|
||||
Reference in New Issue
Block a user