unless the escape key was struck (thus the name) by the user. The domain was also expanded from only program names on the Berkeley system to both program names and files on Tenex. The Tenex descendant TOPS-20 moved command line completion from command interpreter to the operating system via the COMND JSYS system call, to make it available to other user applications. From there it was borrowed by Unix. Example To open the file with Firefox one would type: firefox introduction-to-command-line-completion.html This is a long command to type. Instead we can use command-line completion. Prompting completion The following example shows how command-line completion works in Bash. Other command line shells may perform slightly differently. First we type the first three letters of our command: fir Then we press and because the only command in our system that starts with "fir" is "firefox", it will be completed to: firefox Then we start typing the file name: firefox i But this time is not the only file in the current directory that starts with "i". The directory also contains files and . The system can't decide which of these filenames we wanted to type, but it does know that the file must begin with "introduction-to-", so the command will be completed to: firefox introduction-to- Now we type "c": firefox introduction-to-c After pressing it will be completed to the whole filename: firefox introduction-to-command-line-completion.html In short we typed: firic This is just eight keystrokes, which is considerably less than 52 keystrokes we would have needed to type without using command-line completion. Rotating completion The following example shows how command-line completion works with rotating completion, such as Windows's CMD uses. We follow the same procedure as for prompting completion until we have: firefox i We press once, with the result: firefox introduction-to-bash.html We press again, getting: firefox introduction-to-command-line-completion.html In short we typed: firi This is just seven keystrokes, comparable to prompting-style completion. This works best if we know what possibilities the interpreter will rotate through. Completion in different command line interfaces Unix shells, including Bash (the default shell in most Linux distributions) and ksh among many others, have a long-standing tradition of advanced and customizable completion capabilities. Bash programmable completion, complete and compgen commands have been available since the beta version of 2.04 in 2000 and offers at least Pathname and filename completion. For KornShell users, file name completion depends on the value of the