neo-neo-bblessed
Version:
A fork of neo-blessed (which is a fork of blessed) with bug fixes and maintenance.
19 lines (14 loc) • 425 B
text/typescript
const blessed = require('../index.js');
const argv = process.argv.slice(2);
const cmd = argv.shift();
const tput = blessed.tput({
terminal: process.env['TERM'],
termcap: !!process.env['USE_TERMCAP'],
extended: true,
});
if (cmd && typeof tput[cmd] === 'function') {
process.stdout.write(tput[cmd].apply(tput, argv));
} else if (cmd && tput[cmd]) {
process.stdout.write(String(tput[cmd]));
}