Commands
========
Use the provided commands to manage users in your application. Some commands
may require a specific number of arguments and support options, add `-h` to
get help on a specific command.

activate_user
-------------
Activate a specific user:

```
bin/cake users activate_user the.target.username
```

add_superuser
-------------
This command creates a user with field `$user->is_superuser = true;`.

Quick usage: add a superuser with autogenerated data:

```
bin/cake users add_superuser
```
**This will output the id, username, email, role and password of the new user.**

Add a superuser with specific data:

```
bin/cake users add_superuser --username=my.new.superuser --email=some.email@example.com --role=my-custom-role --password=my-custom.password-example
```
**Please use a strong password.**

add_user
--------
This command creates a user with field `$user->is_superuser = false;`.

Quick usage: add a user with autogenerated data:

```
bin/cake users add_user
```
**This will output the id, username, email, role and password of the new user.**

Add a user with specific data:

```
bin/cake users add_user --username=my.new.user --email=some.email.user@example.com --role=my-custom-role --password=my-custom.password-example
```
**Please use a strong password.**

change_api_token
----------------
Change the api token for a specific user:

```
bin/cake users change_api_token the.target.username the-new-hash-token
```

change_role
-----------
Change the role for a specific user:

```
bin/cake users change_api_token the.tagert.user.name my-custom-role
```

deactivate_user
---------------
Deactivate a specific user:

```
bin/cake users deactivate_user the.target.username
```

delete_user
-----------
Delete a specific user:

***Warning: You can't undo this action.***

```
bin/cake users delete_user the.target.username
```

password_email
--------------
Request password reset via e-mail:

```
bin/cake users password_email the.target.username
```

A link to reset the password is sent to the user.

reset_all_passwords
-------------------
Reset the password for all users:

***Warning: This command is normally useful on development environment,
you probably WON'T use it on production.***

```
bin/cake users reset_all_passwords a-new-safe-password
```

reset_password
--------------
Reset the password for a specific user:

***Warning: This command is normally useful on development environment,
you probably WON'T use it on production.***

```
bin/cake users reset_password  the.target.username a-new-safe-password
```

