Skip to content

Conversation

@jasonmccreary
Copy link
Contributor

This is a retry of #35536 after getting some love on Twitter. It avoids the breaking change by preserving the current --class option and adding a class argument which will be used if set. Otherwise, existing behavior ensues.

For example, all of the following may be used to run the DatabaseSeeder.

php artisan db:seed --class=DatabaseSeeder
php artisan db:seed DatabaseSeeder
php artisan db:seed

For a specific seeder, you may run:

php artisan db:seed --class=UsersTableSeeder
php artisan db:seed UsersTableSeeder

@GrahamCampbell GrahamCampbell changed the title Add class argument [8.x] Add class argument Mar 9, 2021
@taylorotwell taylorotwell merged commit 0443f1c into laravel:8.x Mar 9, 2021
This was referenced Mar 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants