function drush_core_status

8.0.x core.drush.inc drush_core_status()
6.x core.drush.inc drush_core_status()
7.x core.drush.inc drush_core_status()
3.x core.drush.inc drush_core_status()
4.x core.drush.inc drush_core_status()
5.x core.drush.inc drush_core_status()
master core.drush.inc drush_core_status()

Command callback. Provides a birds-eye view of the current Drupal installation.

File

commands/core/core.drush.inc, line 832
Core drush commands.

Code

function drush_core_status() {
  $status_table = _core_site_status_table(drush_get_option('project', ''));
  // If args are specified, filter out any entry that is not named
  // (in other words, only show lines named by one of the arg values)
  $args = func_get_args();
  if (!empty($args)) {
    $field_list = $args;
    $metadata = drush_get_command_format_metadata('core-status');
    foreach ($metadata['field-labels'] as $field_key => $field_label) {
      if (_drush_core_is_named_in_array($field_label, $args)) {
        $field_list[] = $field_key;
      }
    }
    foreach ($status_table as $key => $value) {
      if (!_drush_core_is_named_in_array($key, $field_list)) {
        unset($status_table[$key]);
      }
    }
  }
  return $status_table;
}