function drush_invoke_sitealias_args

4.x command.inc drush_invoke_sitealias_args($site_alias_record, $command_name, $commandline_args, $commandline_options = array(), $integrate = FALSE)

Invoke a command in a new process, targeting the site specified by the provided site alias record.

@deprecated;

Parameters

array $site_alias_record: The site record to execute the command on.

string $command_name: The command to invoke.

array $commandline_args: The arguments to pass to the command.

array $commandline_options: The options (e.g. --select) to provide to the command.

integrate: @see drush_backend_invoke

Return value

If the command could not be completed successfully, FALSE. If the command was completed, this will return an associative array containing the results of the API call. @see drush_backend_get_result()

See also

drush_invoke_process($site_alias_record, $command_name, $commandline_args, $commandline_options) for a better option

Related topics

9 calls to drush_invoke_sitealias_args()
drush_archive_dump in commands/core/archive.drush.inc
Command callback. Generate site archive file.
drush_archive_restore in commands/core/archive.drush.inc
Command callback. Restore web site(s) from a site archive file.
drush_invoke_process in includes/command.inc
Invoke a command in a new process, targeting the site specified by the provided site alias record.
drush_invoke_sitealias in includes/command.inc
Invoke a command in a new process, targeting the site specified by the provided site alias record.
drush_sitealias_add_db_settings in includes/sitealias.inc
If the alias record does not contain a 'databases' or 'db-url' entry, then use backend invoke to look up the settings value from the remote or local site. The 'databases' form is preferred; 'db_url' will be…

... See full list

File

includes/command.inc, line 349
The drush command engine.

Code

function drush_invoke_sitealias_args($site_alias_record, $command_name, $commandline_args, $commandline_options = array(), $integrate = FALSE) {
  // If the first parameter is not a site alias record,
  // then presume it is an alias name, and try to look up
  // the alias record.
  if (!is_array($site_alias_record)) {
    $site_alias_record = drush_sitealias_get_record($site_alias_record);
  }
  return drush_do_site_command($site_alias_record, $command_name, $commandline_args, $commandline_options, $integrate);
}