From 16db4b4c1c8352cd7d94d0ec0df79fec8721f7cf Mon Sep 17 00:00:00 2001 From: anseki Date: Fri, 27 Mar 2015 21:12:00 +0900 Subject: [PATCH] encode arg for cscript --- lib/read.cs.js | 4 ++-- lib/readline-sync.js | 1 + 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/lib/read.cs.js b/lib/read.cs.js index c7bff07..11113d6 100644 --- a/lib/read.cs.js +++ b/lib/read.cs.js @@ -2,8 +2,8 @@ var FSO_ForReading = 1, FSO_ForWriting = 2, - PS_MSG = 'Microsoft Windows PowerShell is required.\n' + - 'https://technet.microsoft.com/en-us/library/hh847837.aspx', + PS_MSG = 'Microsoft Windows PowerShell is required.' + + ' https://technet.microsoft.com/en-us/library/hh847837.aspx', input, fso, tty, options = (function(conf) { diff --git a/lib/readline-sync.js b/lib/readline-sync.js index a7d7084..dbf8232 100644 --- a/lib/readline-sync.js +++ b/lib/readline-sync.js @@ -212,6 +212,7 @@ function readlineExt(options) { } } if (IS_WIN && !process.env.PSModulePath) { // Windows Script Host + options.encoded = true; // Parsing args is DOS? // ScriptPW (Win XP and Server2003) needs TTY stream as STDIN. // In this case, If STDIN isn't TTY, an error is thrown. execOptions.stdio = [process.stdin];