listr-update-renderer

Listr update renderer

MIT 9 个版本
安装
npm install listr-update-renderer
yarn add listr-update-renderer
pnpm add listr-update-renderer
bun add listr-update-renderer
README

listr-update-renderer Build Status

Listr update renderer

Install

$ npm install --save listr-update-renderer

Usage

const UpdaterRenderer = require('listr-update-renderer');
const Listr = require('listr');

const list = new Listr([
    {
        title: 'foo',
        task: () => Promise.resolve('bar')
    }
], {
    renderer: UpdaterRenderer,
	collapse: false
});

list.run();

Note: This is the default renderer for Listr and doesn't need to be specified.

Options

These options should be provided in the Listr options object.

showSubtasks

Type: boolean
Default: true

Set to false if you want to disable the rendering of the subtasks. Subtasks will be rendered if an error occurred in one of them.

collapse

Type: boolean
Default: true

Set to false if you don't want subtasks to be hidden after the main task succeed.

clearOutput

Type: boolean
Default: false

Clear the output when all the tasks are executed succesfully.

License

MIT © Sam Verschueren

版本列表
0.5.0 2018-11-17
0.4.0 2017-04-07
0.3.0 2017-04-07
0.2.0 2017-01-27
0.1.4 2016-12-20
0.1.3 2016-12-19
0.1.2 2016-09-19
0.1.1 2016-09-15
0.1.0 2016-09-15