From 227bafe95cda845c40dd2cccfaa1a48035148378 Mon Sep 17 00:00:00 2001 From: Michael Bleigh Date: Mon, 5 Oct 2015 18:54:35 -0700 Subject: [PATCH] Try to detect interactive mode using process.stdin.isTTY --- lib/command.js | 3 +++ 1 file changed, 3 insertions(+) diff --git a/lib/command.js b/lib/command.js index d13b9cb5..ca4fd5d8 100644 --- a/lib/command.js +++ b/lib/command.js @@ -86,6 +86,9 @@ Command.prototype.register = function(client) { }; Command.prototype._prepare = function(options) { + if (!process.stdin.isTTY) { + options.nonInteractive = true; + } if (utils.getInheritedOption(options, 'debug')) { logger.transports.console.level = 'debug'; }