You are here

function services_client_drush_command in Services Client 7

Same name and namespace in other branches
  1. 7.2 services_client.drush.inc \services_client_drush_command()

Implementation of hook_drush_commands()

File

./services_client.drush.inc, line 11
Services client drush integration

Code

function services_client_drush_command() {
  $items = array();
  $items['services-client-entity-mapping'] = array(
    'description' => "Creates entity mapping",
    'arguments' => array(
      'entity_type' => 'Type of the entity',
      'entity_bundle' => '',
    ),
    'options' => array(
      'mirror' => '',
      'language' => '',
    ),
    'examples' => array(
      'drush sc-em node page' => 'Cretae mapping for node',
    ),
    'aliases' => array(
      'sc-em',
    ),
  );
  $items['services-client-process-queue'] = array(
    'description' => "Process entries from queue",
    'options' => array(
      'time' => '',
    ),
    'examples' => array(
      'drush sc-pq' => 'Process queued synchronizations',
    ),
    'aliases' => array(
      'sc-pq',
    ),
  );
  $items['services-client-sync-users'] = array(
    'description' => "Sync user references",
    'options' => array(
      'min' => 'Min uid of user',
      'max' => 'Max uid of user',
      'hook' => 'Hook name',
    ),
    'examples' => array(
      'drush sc-su --hook=docs_user --min=1 --max=5000' => 'Sync all users',
    ),
    'aliases' => array(
      'sc-su',
    ),
  );
  $items['services-client-sync-nodes'] = array(
    'description' => "Sync nodes",
    'options' => array(
      'min' => 'Min nid of node',
      'max' => 'Max nid of node',
      'type' => 'Node type',
      'hook' => 'Hook name',
    ),
    'examples' => array(
      'drush sc-su --hook=insight_node --min=1 --max=5000' => 'Sync all users',
    ),
    'aliases' => array(
      'sc-sn',
    ),
  );
  return $items;
}