You are here

function drush_yamlform_libraries_download in YAML Form 8

Implements drush_hook_COMMAND().

File

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

Code

function drush_yamlform_libraries_download() {

  // Remove all existing libraries.
  if (drush_yamlform_libraries_remove(FALSE)) {
    drush_print(dt('Removing existing libraries...'));
  }

  // Download libraries using drush.
  $commandline_args = [
    DRUPAL_ROOT . '/' . drupal_get_path('module', 'yamlform') . '/yamlform.libraries.make.yml',
    DRUPAL_ROOT,
  ];
  $commandline_options = [
    'no-core' => 'no-core',
  ];
  drush_invoke_process('@self', 'make', $commandline_args, $commandline_options);
  drupal_flush_all_caches();
}