diff --git a/lib/node-progress.js b/lib/node-progress.js index 8691327..638d919 100644 --- a/lib/node-progress.js +++ b/lib/node-progress.js @@ -102,6 +102,10 @@ ProgressBar.prototype.tick = function(len, tokens){ */ ProgressBar.prototype.render = function(tokens){ + if(!process.stdout.isTTY) { + return; + } + var percent = (this.curr >= this.total) ? 100 : this.curr / this.total * 100 , complete = Math.round(this.width * (this.curr / this.total)) , incomplete