O'Reilly logo

Unix in a Nutshell, 4th Edition by Arnold Robbins

Stay ahead with the world's most comprehensive technology and business learning platform.

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, tutorials, and more.

Start Free Trial

No credit card required

Name

complete

Synopsis

    complete [options]command ...

Bash only. Specifies the way to complete arguments for each command. This is discussed in the section "Programmable Completion (Bash Only)," earlier in the chapter.

Options

-a

Same as -A alias.

-A type

Use type to specify a list of possible completions. The type may be one of the following.

alias

Alias names.

arrayvar

Array variable names.

binding

Bindings from the readline library.

builtin

Shell built-in command names.

command

Command names.

directory

Directory names.

disabled

Names of disabled shell built-in commands.

enabled

Names of enabled shell built-in commands.

export

Exported variables.

file

Filenames.

function

Names of shell functions.

group

Group names.

helptopic

Help topics as allowed by the help built-in command.

hostname

Hostnames, as found in the file named by $HOSTFILE.

job

Job names.

keyword

Shell reserved keywords.

running

Names of running jobs.

service

Service names (from /etc/services).

setopt

Valid arguments for set -o.

shopt

Valid option names for the shopt built-in command.

signal

Signal names.

stopped

Names of stopped jobs.

user

Usernames.

variable

Shell variable names.

-b

Same as -A builtin.

-c

Same as -A command.

-C command

Run command in a subshell and use its output as the list of completions.

-d

Same as -A directory.

-e

Same as -A export.

-f

Same as -A file.

-F function

Run shell function function in the current ...

With Safari, you learn the way you learn best. Get unlimited access to videos, live online training, learning paths, books, interactive tutorials, and more.

Start Free Trial

No credit card required