quantick/deploy-migrations
最新稳定版本:v1.0.13
Composer 安装命令:
composer require quantick/deploy-migrations
包简介
Deploy migration commands
README 文档
README
Installation
You can install the package via composer:
composer require quantick/deploy-migrations
The package will automatically register itself.
You can publish config and migration with:
php artisan vendor:publish --provider="Quantick\DeployMigration\DeployMigrationServiceProvider"
In config/deploy-migration.php сonfigure the path to the directory with migrations. By default it will be deploy/migrations
How to use
- Generate migration via command:
php artisan make:deploy-migration
It will create migration class in your project.
- Next configure getCommands method:
<?php class Version20190211093348 extends \Quantick\DeployMigration\Lib\DeployMigration { public function getCommands(): array { return [ \App\Console\Commands\TestCommandWithArguments::class => ['arg' => 'value', '--option' => true], \App\Console\Commands\TestCommandWithoutArguments::class => [], function (SomeService $service) { return $service->doTheWork(); } ]; } }
- Run
php artisan deploy:migrate
统计信息
- 总下载量: 366
- 月度下载量: 0
- 日度下载量: 0
- 收藏数: 4
- 点击次数: 1
- 依赖项目数: 0
- 推荐数: 0
其他信息
- 授权协议: MIT
- 更新时间: 2019-02-11