thinkphp 6.0 phinx 数据迁移
phinx: ~0.11.1
composer require nhzex/think-phinx
migrate
migrate:breakpoint Manage breakpoints
migrate:create Create a new migration
migrate:rollback Rollback the last or to a specific migration
migrate:run Migrate the database
migrate:status Show migration status
migrate:test Verify the configuration file
seed
seed:create Create a new database seeder
seed:run Run database seeders
<?php
return [
'paths' => [
'migrations' => [
'DbMigrations' => './.phinx/migrations',
],
'seeds' => [
'DbSeeds' => './.phinx/seeds'
]
],
'environments' => [
'default_migration_table' => '_phinxlog',
],
'version_order' => 'creation'
];