Created
May 23, 2019 07:09
-
-
Save daubac402/4190e74ce54dcac40a8cf309b831d053 to your computer and use it in GitHub Desktop.
Laravel - Generate models from the database automatically
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
1. composer require reliese/laravel | |
2. Add the service provider to your config/app.php file | |
Reliese\Coders\CodersServiceProvider::class | |
3. Publish the config file with | |
php artisan vendor:publish --tag=reliese-models | |
4. Make sure your database is correctly configured in config/database.php and .env files. | |
5. Finally run: | |
php artisan code:models | |
=> check the results in /app/Models/ |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment