Laravel create migration file in specific folder

后端 未结 3 1657
鱼传尺愫
鱼传尺愫 2021-01-04 01:18

I\'ve created Payment package for my laravel project

I want to make migration files inside migrations folder of my package. How can create it using artisan command?

3条回答
  •  礼貌的吻别
    2021-01-04 01:48

    For specific directories:

    php artisan make:migration create_users_table --path=/packages/Payment/src/Database
    

    The new migration will be placed in your packages/Payment/src/Database directory.

    For Running Migrations: php artisan migrate --path=/packages/Payment/src/Database


    Generating a migration using the inbuilt framework feature:

    php artisan make:migration create_users_table
    

    The new migration will be placed in your database/migrations directory.

    For Running Migrations: php artisan migrate

提交回复
热议问题