ts-progress
Advanced tools
Comparing version 0.0.7 to 0.0.8
{ | ||
"name": "ts-progress", | ||
"version": "0.0.7", | ||
"description": "Flexible node progress bar.", | ||
"version": "0.0.8", | ||
"description": "Flexible node progress bar for Windows/macOS/Linux.", | ||
"main": "progress.js", | ||
@@ -6,0 +6,0 @@ "scripts": { |
@@ -28,2 +28,3 @@ 'use strict'; | ||
this.start = function () { | ||
charm.erase('line').write("\r"); | ||
_this._start = new Date().getTime(); | ||
@@ -41,6 +42,5 @@ _this._now = new Date().getTime(); | ||
_this.write(); | ||
charm.write("\n"); | ||
}; | ||
this.write = function () { | ||
charm.erase('line').write("\r"); | ||
//charm.up(1).erase('line').write("\r"); | ||
var match; | ||
@@ -54,3 +54,3 @@ while (match = _this._regex.exec(_this._pattern)) { | ||
var tokens = match[2].split('.'); | ||
if (tokens.length == 4 && tokens[0] === 'bar') { | ||
if (tokens.length == 4 && tokens[0] == 'bar') { | ||
_this.renderBar(tokens[1], tokens[2], tokens[3]); | ||
@@ -63,2 +63,3 @@ } | ||
} | ||
charm.write("\r\n"); | ||
}; | ||
@@ -150,2 +151,3 @@ this.renderElapsed = function (color) { | ||
this._now = new Date().getTime(); | ||
charm.up(1).erase('line').write("\r"); | ||
if (this._current === this._total - 1) { | ||
@@ -152,0 +154,0 @@ this.stop(); |
# ts-progress | ||
> Flexible node progress bar | ||
> Flexible node progress bar for Windows/macOS/Linux | ||
@@ -5,0 +5,0 @@ ![image](https://github.com/agracio/ts-progress/raw/master/screenshot.gif) |
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
License Policy Violation
LicenseThis package is not allowed per your license policy. Review the package's license to ensure compliance.
Found 1 instance in 1 package
12806
5