user1404963
user1404963

Reputation: 445

Laravel 5.0 php artisan make:model ModelName auto creating migration class

Laravel's command: php artisan make:model ModelName

automatically creating creating migration class with the Model Name. Is there are way that we could pass additional parameters to the make:model command so that it ignores creating migration class?

Upvotes: 6

Views: 15153

Answers (1)

Jad Joubran
Jad Joubran

Reputation: 2579

You should write this command:
php artisan make:model modelName --no-migration

Artisan CLI providers a help message for all commands.
For instance php artisan help make:model shows a list of available cli arguments for the make:model command.

UPDATE [2015]:
Starting 5.1, migrations are not automatically created anymore. You can use the flag --migration to generate one.

Upvotes: 14

Related Questions