Command-line Completion - Completion in Different Command Line Interfaces

Completion in Different Command Line Interfaces

  • Unix shells, including Bash (the default shell in Linux and Mac OS X) and ksh among many others, have a long-standing tradition of advanced and customizable completion capabilities (see the external links section below for some examples).
    • For Korn shell users, file name completion depends on the value of the EDITOR variable. If EDITOR is set to vi, you type part of the name, and then Escape,\. If EDITOR is set to Emacs, you type part of the name, and then Escape,Escape.
    • The Z shell (zsh) pioneered the support for fully programmable completion, allowing users to have the shell automatically complete the parameters of various commands unrelated to the shell itself, which is accomplished by priming the shell with definitions of all known switches as well as appropriate parameter types. This allows the user to e.g. type tar xzf Tab ↹ and have the shell complete only tarred gzip archives from the actual filesystem, skipping files which are incompatible with the input parameters. A modern zsh installation comes with completion definitions for over five hundred commands.
  • Windows PowerShell, the extensible command shell from Microsoft, which is based on object-oriented programming and the Microsoft .NET framework provides powerful and customizable completion capabilities similar to those of traditional Unix shells.
  • The cmd.exe command processor of Windows NT-based systems supports basic completion. It is possible to use a separate key-binding for matching directory names only.
  • cmd.exe /F:ON enables file and directory name completion characters (^F and ^D by default). Use cmd.exe /? for more information.
  • TweakUI can be used to configure the keys used for file name and directory name completion.
  • The MS-DOS command processor COMMAND.COM did not have command-line completion: pressing the tab key would just advance the cursor. Before the release of Windows however, various enhanced shells for MS-DOS, such as 4DOS, or the FreeDOS version of COMMAND.COM, featured Unix-style tab completion.

Read more about this topic:  Command-line Completion

Famous quotes containing the words command and/or line:

    There are confessable agonies, sufferings of which one can positively be proud. Of bereavement, of parting, of the sense of sin and the fear of death the poets have eloquently spoken. They command the world’s sympathy. But there are also discreditable anguishes, no less excruciating than the others, but of which the sufferer dare not, cannot speak. The anguish of thwarted desire, for example.
    Aldous Huxley (1894–1963)

    As for conforming outwardly, and living your own life inwardly, I do not think much of that. Let not your right hand know what your left hand does in that line of business. It will prove a failure.... It is a greater strain than any soul can long endure. When you get God to pulling one way, and the devil the other, each having his feet well braced,—to say nothing of the conscience sawing transversely,—almost any timber will give way.
    Henry David Thoreau (1817–1862)