WP_CLI::addCommand()public staticWP-CLI 1.0

back-compat

{} It's a method of the class: WP_CLI{}

No Hooks.

Return

null. Nothing.

Usage

$result = WP_CLI::addCommand( $name, $class );
$name (required)
-
$class (required)
-

Code of WP_CLI::addCommand() WP-CLI 2.7.0-alpha

public static function addCommand( $name, $class ) {
	trigger_error(
		sprintf(
			'wp %s: %s is deprecated. use WP_CLI::add_command() instead.',
			$name,
			__FUNCTION__
		),
		E_USER_WARNING
	);
	self::add_command( $name, $class );
}