When developing tools for developers, it is advantageous because it is easier without a GUI to automate it. However, if you consider usability, it is better to have an indicator or interactive input.
This time I will introduce the Terminal Kit packed with functions that make such CLI tool convenient.
How to use Terminal Kit
It is a sample. It is a file selection function.
$ node sample/file-input-doc1.jsChoose a file: /path/to/saturn.txtYour file is '/path/to/saturn.txt '
Let me enter a command and get a demo of it.
$ node sample/input-field-doc4.jsshell> lsYour command is: 'ls'
You can also enter Yes / No.
$ node sample/yes-no-doc1.jsDo you like javascript? [Y|n]'Yes' detected! Good bye!
You can also select files interactively.
A lot of coloring is also prepared.
indicator.
And you can draw such graphics.
Move the hull with the keyboard.
Besides this, the Terminal Kit has many functions such as adding a menu, allowing you to select from multiple items, input completion, drawing images. Using these functions should make the CLI tool much more convenient.
Terminal Kit is open source software (MIT License) made by node / JavaScript.
No comments:
Post a Comment