You are here

function drush_yamlform_libraries_status in YAML Form 8

Implements drush_hook_COMMAND().

File

drush/yamlform.drush.inc, line 422
YAML Form module drush commands.

Code

function drush_yamlform_libraries_status() {
  module_load_include('install', 'yamlform');

  /** @var \Drupal\yamlform\YamlFormLibrariesManagerInterface $libraries_manager */
  $libraries_manager = \Drupal::service('yamlform.libraries_manager');
  $requirements = $libraries_manager
    ->requirements();
  foreach ($requirements as $requirement) {
    $library = $requirement['library'];
    drush_print($library['title'] . ' (' . $library['name'] . ') ' . $requirement['value']);

    // drush_print();
    drush_print(strip_tags($requirement['description']));
    drush_print();
  }
}