function drush_set_command

8.0.x context.inc drush_set_command($command)
6.x context.inc drush_set_command($command)
7.x context.inc drush_set_command($command)
3.x context.inc drush_set_command($command)
4.x context.inc drush_set_command($command)
5.x context.inc drush_set_command($command)
master context.inc drush_set_command($command)

Set the command being executed.

Drush_dispatch will set the correct command based on it's matching of the script arguments retrieved from drush_get_arguments to the implemented commands specified by drush_get_commands.

Parameters

A numerically indexed array of command components.:

3 calls to drush_set_command()
drush_complete_process_argv in includes/complete.inc
This function resets the raw arguments so that Drush can parse the command as if it was run directly. The shell complete command passes the full command line as an argument, and the --early and --complete-debug options have to come before that, and…
drush_dispatch in includes/command.inc
Given a command record, dispatch it as if it were the original command. Executes in the currently bootstrapped site using the current option contexts. Note that drush_dispatch will not bootstrap any further than the current command has already…
drush_parse_command in includes/command.inc
Matches a commands array, as returned by drush_get_arguments, with the current command table.

File

includes/context.inc, line 383
The Drush context API implementation.

Code

function drush_set_command($command) {
  drush_set_context('command', $command);
}