xshell 1.1.14 → 1.1.15
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/stdin.js +4 -2
package/package.json
CHANGED
package/stdin.js
CHANGED
|
@@ -5,8 +5,10 @@ import process from 'process';
|
|
|
5
5
|
export function process_stdin(on_key, on_exit) {
|
|
6
6
|
// https://stackoverflow.com/a/12506613/7609214
|
|
7
7
|
let { stdin } = process;
|
|
8
|
-
stdin.
|
|
9
|
-
|
|
8
|
+
if (stdin.isTTY) {
|
|
9
|
+
stdin.setRawMode(true);
|
|
10
|
+
stdin.resume();
|
|
11
|
+
}
|
|
10
12
|
stdin.setEncoding('utf-8');
|
|
11
13
|
// on any data into stdin
|
|
12
14
|
stdin.on('data', async (key) => {
|