You are here

function acsf_duplication_drush_command in Acquia Cloud Site Factory Connector 8

Implements hook_drush_command().

File

acsf_duplication/acsf_duplication.drush.inc, line 16
Provides drush commands necessary for site duplication.

Code

function acsf_duplication_drush_command() {
  $items = [];
  $items['acsf-duplication-scrub-batch'] = [
    'description' => dt('Runs one iteration of the batch scrubbing process on the duplicated site.'),
    'arguments' => [
      'site_name' => dt('The new name of the duplicated site.'),
      'standard_domain' => dt('The standard domain of the duplicated site.'),
    ],
    'options' => [
      'exact-copy' => dt('Indicates that the duplicated site is intended to be an exact copy of the source site (i.e. retain all content, users, and required configuration).'),
      'avoid-oom' => dt('The command should run just a single iteration of the batch process (the default is to loop until it runs out of memory). This is useful to keep the memory footprint low but you are expected to handle the looping externally.'),
      'batch' => dt('The number of items to process each iteration (defaults to 1000).'),
      'batch-comment' => dt('The number of comments to delete each iteration (defaults to --batch).'),
      'batch-node' => dt('The number of nodes to delete each iteration (defaults to --batch).'),
      'batch-user' => dt('The number of users to delete each iteration (defaults to --batch).'),
      'retain-content' => dt('Retain nodes and comments (defaults to --exact-copy).'),
      'retain-users' => dt('Retain users (defaults to --exact-copy).'),
    ],
  ];
  $items['acsf-duplication-scrub-progress'] = [
    'description' => dt('Returns status information about the progress of the batch scrubbing process.'),
    'options' => [
      'format' => [
        'description' => dt('Format to output the object. Use "var_export" for var_export (default), "print-r" for print_r and "json" for JSON.'),
        'example-value' => 'json',
      ],
    ],
  ];
  return $items;
}