UNPKG

mlts-experiment-data

Version:

Machine learning experiment data downloader.

25 lines 848 B
"use strict"; Object.defineProperty(exports, "__esModule", { value: true }); var tslib_1 = require("tslib"); var rl = require("readline"); var print = function (data) { rl.clearLine(process.stdout, 0); rl.cursorTo(process.stdout, 0); process.stdout.write(data.toString()); }; function printProgressAsync(f) { return tslib_1.__awaiter(this, void 0, void 0, function () { var res; return tslib_1.__generator(this, function (_a) { switch (_a.label) { case 0: return [4 /*yield*/, f(print)]; case 1: res = _a.sent(); console.log(''); // tslint:disable-line no-console return [2 /*return*/, res]; } }); }); } exports.printProgressAsync = printProgressAsync; //# sourceMappingURL=printer.js.map