PHP code example of boaideas / laravel-cli-create-user

1. Go to this page and download the library: Download boaideas/laravel-cli-create-user library. Choose the download type require.

2. Extract the ZIP file and open the index.php.

3. Add this code to the index.php.
    
        
<?php
require_once('vendor/autoload.php');

/* Start to develop here. Best regards https://php-download.com/ */

    

boaideas / laravel-cli-create-user example snippets


// config/app.php

'providers' => [
    ...
    BOAIdeas\CreateUser\CreateUserServiceProvider::class,
];

// config/createuser.php

return [
    /*
    * The class name of the user model to be used.
    */
    'model' => 'App\User',

    /*
    * The validation rules to check for user model input.
    */
    'validation_rules' => [
    	'name' => 'string|max:255',
    	'email' => 'string|email|max:255|unique:users',
    	'password' => 'string|min:6',
    ],

];
bash
php artisan user:create
bash
php artisan user:list
bash
php artisan user:remove {user_id}
bash
php artisan vendor:publish --provider="BOAIdeas\CreateUser\CreateUserServiceProvider"