function default_content_drush_command in Default Content for D8 8
Same name and namespace in other branches
- 2.0.x drush/default_content.drush.inc \default_content_drush_command()
Implements hook_drush_command().
File
- drush/
default_content.drush.inc, line 11 - Drush integration for the default_content module.
Code
function default_content_drush_command() {
$items['default-content-export'] = [
'description' => dt('Exports a single entity'),
'arguments' => [
'entity_type' => dt('The entity type to export.'),
'entity_id' => dt('The ID of the entity to export.'),
],
'options' => [
'file' => dt('Write out the exported content to a file instead of stdout'),
],
'aliases' => [
'dce',
],
'required-arguments' => 2,
];
$items['default-content-export-references'] = [
'description' => dt('Exports an entity and all its referenced entities.'),
'arguments' => [
'entity_type' => dt('The entity type to export.'),
'entity_id' => dt('The ID of the entity to export.'),
],
'options' => [
'folder' => dt('Folder to export to, entities are grouped by entity type into directories.'),
],
'aliases' => [
'dcer',
],
'required-arguments' => 1,
];
$items['default-content-export-module'] = [
'description' => dt('Exports all the content defined in a module info file.'),
'arguments' => [
'module' => dt('The name of the module.'),
],
'aliases' => [
'dcem',
],
'required-arguments' => 1,
];
return $items;
}