CLI_Alias_Command::list_()publicWP-CLI 1.0

Lists available WP-CLI aliases.

OPTIONS

[--format=<format>]
Render output in a particular format.
--- default: yaml options:
  • yaml
  • json
  • var_export

EXAMPLES

# List all available aliases.
$ wp cli alias list
---
@all: Run command against every registered alias.
@prod:
  ssh: [email protected]~/webapps/production
@dev:
  ssh: [email protected]/srv/www/runcommand.dev
@both:
  - @prod
  - @dev

Method of the class: CLI_Alias_Command{}

No Hooks.

Return

null. Nothing.

Usage

$CLI_Alias_Command = new CLI_Alias_Command();
$CLI_Alias_Command->list_( $args, $assoc_args );
$args (required)
-
$assoc_args (required)
-

CLI_Alias_Command::list_() code WP-CLI 2.7.0-alpha

public function list_( $args, $assoc_args ) {
	WP_CLI::print_value( WP_CLI::get_runner()->aliases, $assoc_args );
}