function drush_hide_output_fields

8.0.x outputformat.drush.inc drush_hide_output_fields($fields_to_hide = array())
6.x outputformat.drush.inc drush_hide_output_fields($fields_to_hide = array())
7.x outputformat.drush.inc drush_hide_output_fields($fields_to_hide = array())
master outputformat.drush.inc drush_hide_output_fields($fields_to_hide = array())

Specify that certain fields should not appear in the resulting output.

4 calls to drush_hide_output_fields()
drush_field_info in commands/core/field.drush.inc
drush_outputformat::process in commands/core/outputformat.drush.inc
Perform pre-processing and then format() the $input.
drush_pm_list in commands/pm/pm.drush.inc
Command callback. Show a list of extensions with type and status.
drush_role_list in commands/core/role.drush.inc
Displays a list of roles

File

commands/core/outputformat.drush.inc, line 462
Core drush output formats.

Code

function drush_hide_output_fields($fields_to_hide = array()) {
  $already_hidden = drush_get_context('DRUSH_HIDDEN_OUTPUT_FIELDS');
  if (!is_array($fields_to_hide)) {
    $fields_to_hide = array($fields_to_hide);
  }
  $result = array_merge($already_hidden, $fields_to_hide);
  drush_set_context('DRUSH_HIDDEN_OUTPUT_FIELDS', $result);
  return $result;
}