function drush_backend_get_result

8.0.x drush_backend_get_result()
6.x drush_backend_get_result()
7.x drush_backend_get_result()
3.x drush_backend_get_result()
4.x drush_backend_get_result()
5.x drush_backend_get_result()
master drush_backend_get_result()

Retrieves the results from the last call to backend_invoke.

@returns array An associative array containing information from the last backend invoke. The keys in the array include:

  • output: This item contains the textual output of the command that was executed.
  • object: Contains the PHP object representation of the result of the command.
  • self: The self object contains the alias record that was used to select the bootstrapped site when the command was executed.
  • error_status: This item returns the error status for the command. Zero means "no error".
  • log: The log item contains an array of log messages from the command execution ordered chronologically. Each log entery is an associative array. A log entry contains following items: o type: The type of log entry, such as 'notice' or 'warning' o message: The log message o timestamp: The time that the message was logged o memory: Available memory at the time that the message was logged o error: The error code associated with the log message (only for log entries whose type is 'error')
  • error_log: The error_log item contains another representation of entries from the log. Only log entries whose 'error' item is set will appear in the error log. The error log is an associative array whose key is the error code, and whose value is an array of messages--one message for every log entry with the same error code.
  • context: The context item contains a representation of all option values that affected the operation of the command, including both the command line options, options set in a drushrc.php configuration files, and options set from the alias record used with the command.
2 calls to drush_backend_get_result()
drush_backend_output in includes/
_drush_invoke_args in includes/
Variant of drush_invoke_args that allows the commandfile to be specified correctly; this allows the hook functions to be correctly determined for commands that provide a 'callback' function.


includes/, line 106
Drush backend API


function drush_backend_get_result() {
  return drush_get_context('BACKEND_RESULT');