public function DevelGenerateCommands::users in Devel 4.x
Same name and namespace in other branches
- 8.3 devel_generate/src/Commands/DevelGenerateCommands.php \Drupal\devel_generate\Commands\DevelGenerateCommands::users()
- 8 devel_generate/src/Commands/DevelGenerateCommands.php \Drupal\devel_generate\Commands\DevelGenerateCommands::users()
- 8.2 devel_generate/src/Commands/DevelGenerateCommands.php \Drupal\devel_generate\Commands\DevelGenerateCommands::users()
Create users.
@command devel-generate:users @aliases genu, devel-generate-users @pluginId user
@option kill Delete all users before generating new ones. @option roles A comma delimited list of role IDs for new users. Don't specify 'authenticated'. @option pass Specify a password to be set for all generated users.
Parameters
int $num: Number of users to generate.
array $options: Array of options as described below.
File
- devel_generate/
src/ Commands/ DevelGenerateCommands.php, line 133
Class
- DevelGenerateCommands
- Provide Drush commands for all the Devel Generate processes.
Namespace
Drupal\devel_generate\CommandsCode
public function users($num = 50, array $options = [
'kill' => FALSE,
'roles' => '',
]) {
// @todo pass $options to the plugins.
$this
->generate();
}