function GenerateTermsCommand::configure
File
-
devel_generate/src/Drush/Commands/GenerateTermsCommand.php, line 33
Class
- GenerateTermsCommand
- #[AsCommand(name: 'devel-generate:terms', description: 'Create terms in specified vocabulary.', aliases: [
'gent',
'devel-generate-terms',
])]
Namespace
Drupal\devel_generate\Drush\Commands
Code
protected function configure() : void {
$this->addArgument('num', InputArgument::OPTIONAL, 'Number of terms to generate.', '50')
->addOption('kill', NULL, InputOption::VALUE_NONE, 'Delete all terms in these vocabularies before generating new ones.')
->addOption('bundles', NULL, InputOption::VALUE_REQUIRED, 'A comma-delimited list of machine names for the vocabularies where terms will be created.')
->addOption('feedback', NULL, InputOption::VALUE_REQUIRED, 'An integer representing interval for insertion rate logging.', '1000')
->addOption('languages', NULL, InputOption::VALUE_REQUIRED, 'A comma-separated list of language codes')
->addOption('translations', NULL, InputOption::VALUE_REQUIRED, 'A comma-separated list of language codes for translations.')
->addOption('min-depth', NULL, InputOption::VALUE_REQUIRED, 'The minimum depth of hierarchy for the new terms.', '1')
->addOption('max-depth', NULL, InputOption::VALUE_REQUIRED, 'The maximum depth of hierarchy for the new terms.', '4');
}