Run DCLI Commands in
Interactive Mode
DCLI supports
interactive shell mode which you can activate by using
dcli +interactive
.
Interactive mode supports
drop-down autocompletion of namespaces, commands, command options, and option
values in case of enumeration values. With DCLI interactive mode, you can also
pass a short command if it is uniquely resolvable. For example,
dcli> com vmware vmc vm list
can also be run as
dcli> vm list
.
Interactive mode is also a
quicker way to browse various namespaces and commands, as DCLI caches the list
of namespaces and commands available on the server for faster access. DCLI
interactive mode provides specific shell commands which can be accessed by
running
dcli> help
.
You can change the prompt for
DCLI interactive mode by using
dcli +interactive +prompt <user-prompt>
when
entering interactive mode.
- From the command line, navigate to the location of the DCLI binary.
- Enable interactive mode../dcli +vmc +iDCLI connects to theVMware Cloud on AWSserver in interactive mode.
- List all SDDCs in a specified organization.
- Provide the full interactive mode command.dcli> com vmware vmc orgs sddcs list --org orgID
- Provide the short interactive mode command.dcli> orgs sddcs list --org orgID
Both commands should return the same result.