Command-line completion

The tab-completion, also called tab completion is a special form of autocompletion. It facilitates and speeds up the handling of a command line interpreter, such as bash on Unix / Linux or Windows PowerShell in Windows. It is, depending on the setting, triggered by the tab key or the Escape key. Also escape backslash is widespread.

Example on Unix / Linux

If, for example, in the directory / etc are changed, it is sufficient cd / typing e and then press the key supplements - the rest of the name will be added automatically.

/ # Cd / e [ Tab] / # Cd / etc / etc # However this only works if no other directory exists here with a e at the beginning. Exist in the current directory number of subdirectories that begin with e, the various appropriate directories are offered sequentially, or it is required (such as a tone ) another sign, depending on the command line interpreter and its configuration.

/ # Cd / s [ tab ] will hear a beep. / # Cd / sb [Tab ] / # Cd / sbin / sbin # Tab-completion in Windows

The Windows command line interpreter cmd.exe also dominated Tabcompletion. This has to be activated only in Windows 2000 (cmd.exe / F: ON). In the following, Windows versions, this is standard.

Alternative additional programs (eg 4DOS/4NT ) as a command line interpreter support tab-completion for Windows for years.

Context-specific supplement

Besides the simple tab-completion for programs and files some command line interpreter support such as bash and Windows PowerShell called the Programmable Completion for context- dependent complement to the possible arguments for the program.

The complete includes path, file, variable, host and user name completion up to the programmable completion, as it is found since version 2.04 in the spread in the Unix environment bash and already in the Z- Shell previously ( zsh ) and TENEX C shell ( tcsh ) found.

Pictures of Command-line completion

111917
de