You are here

function secure_permissions_drush_command in Secure Permissions 7

Same name and namespace in other branches
  1. 6 includes/secure_permissions.drush.inc \secure_permissions_drush_command()
  2. 7.2 secure_permissions.drush.inc \secure_permissions_drush_command()

Implements hook_drush_command().

File

./secure_permissions.drush.inc, line 11
Drush commands for Secure Permissions.

Code

function secure_permissions_drush_command() {
  $items['secure-permissions-rebuild'] = array(
    'callback' => 'secure_permissions_drush_rebuild',
    'description' => dt('Rebuild the site\'s roles and permissions with Secure Permissions.'),
    'arguments' => array(),
    'drupal dependencies' => array(
      'secure_permissions',
    ),
    'aliases' => array(
      'spr',
    ),
  );
  $items['secure-permissions'] = array(
    'callback' => 'secure_permissions_drush_toggle_active',
    'description' => dt('Control the settings of the Secure Permissions module from the command line.'),
    'examples' => array(
      'drush secure-permissions on' => 'Activates the Secure Permissions module from the command line, note this is distinct and different from enabling the module.',
      'drush secure-permissions off' => 'Deactivates the Secure Permissions module from the command line, note this is distinct and different from disabling the module.',
    ),
    'arguments' => array(
      'action' => 'Required. Currently has two states - set to "on" to activate Secure Permissions and "off" to deactivate.',
    ),
    'drupal dependencies' => array(
      'secure_permissions',
    ),
    'aliases' => array(
      'sp',
    ),
  );
  return $items;
}