def delete_user(query):
    """
    Delete a user.
    """
    user = _query_to_user(query)
    if click.confirm(f'Are you sure you want to delete {user!r}?'):
        user_manager.delete(user, commit=True)
        click.echo(f'Successfully deleted {user!r}')
    else:
        click.echo('Cancelled.')
Delete a user.