making reading from stdin option if not a tty
This commit is contained in:
parent
025453e3a7
commit
46bc19ea1c
1 changed files with 3 additions and 1 deletions
|
@ -132,6 +132,8 @@ if (process.stdin.isTTY) {
|
|||
})
|
||||
|
||||
process.stdin.on('end', function () {
|
||||
processInputs(text, argv)
|
||||
// this process can be run as a command outside of a tty so if there was no
|
||||
// data on stdin read from argv
|
||||
processInputs(text.length?text:argv._.join(' '), argv)
|
||||
})
|
||||
}
|
||||
|
|
Loading…
Reference in a new issue