A Command Line Interface (CLI) refers to a user interface that can be implemented by a program such as a command line interpreter or shell. A CLI can be used to enable a user to interact with a computer operating system or system software by typing commands to perform particular tasks. When a user interacts with a CLI, the user can enter a text command and the system waits for the user to conclude submission of the text command by the user pressing the Enter key. Responsively, the command line interpreter receives the command, analyzes the command and then launches the entered command. When the command is completed, the launched command usually returns output to the user in the form of text lines on the CLI.
One of the problems associated with CLIs stems from terminal settings which can cause unwanted or distracting characters to appear on a user's screen during entry of text commands. Terminal settings refer to specific characteristics of text-based interface terminal programs for enabling a user to type commands. Depending on the characteristics or settings of a terminal being used to enter commands, unwanted characters can appear differently. For example, the table just below includes an example Output column that illustrates unwanted characters for corresponding keyed input.
OutputKey“{circumflex over ( )}]]A”<ARROW-UP>“{circumflex over ( )}]]B”<ARROW-DOWN>“{circumflex over ( )}]]C”<ARROW-LEFT>“{circumflex over ( )}]]D”<ARROW-RIGHT>“{circumflex over ( )}[0Q”<F2>“{circumflex over ( )}[[19~”<F8>“{circumflex over ( )}?”<DELETE>
The problem is that the raw keycode of special keys like the <DELETE> key is actually a sequence of multiple bytes that terminal emulation is not able to correctly handle. Having unwanted or distracting characters appear on the user's screen provides an undesirable user experience.
Further, many CLIs only allow the user to review and edit a single, current command. Such CLIs do not provide an opportunity for a user to review or edit previous commands or to reuse previously-entered commands.