🐔 I made a PHP Library "Conv-Laravel": Auto-generate MySQL migration queries. 🤖

howyi

howyi

Posted on March 19, 2019

🐔 I made a PHP Library "Conv-Laravel": Auto-generate MySQL migration queries. 🤖

thumbnail
full size

GitHub logo howyi / conv-laravel

MySQL migration query auto generate on Laravel/Lumen

conv-laravel

MySQL migration query auto generate on Laravel/Lumen

Install

  1. require library (Laravel/Lumen)
composer require "howyi/conv-laravel" --dev
  1. publish config (only Laravel)
php artisan vendor:publish --provider="Howyi\ConvLaravel\ConvServiceProvider"
  1. schema initialize (Laravel/Lumen)
php artisan conv:reflect

generate CREATE queries on database/schemas

Usage

  1. edit CREATE query (in schema directory)
  2. php artisan conv:generate to generate migrations from actual Database - CREATE queries
  3. php artisan migrate to migration





feature

Generate MySQL migration queries from actual DB (\PDO) and DDLs (CREATE queries)

motivation

I'm tired of writing migration queries ... 😌

install

  1. require library (Laravel/Lumen)
composer require "howyi/conv-laravel" --dev
Enter fullscreen mode Exit fullscreen mode
  1. publish config (only Laravel)
php artisan vendor:publish --provider="Howyi\ConvLaravel\ConvServiceProvider"
Enter fullscreen mode Exit fullscreen mode
  1. schema initialize (Laravel/Lumen)
php artisan conv:reflect
Enter fullscreen mode Exit fullscreen mode

generate CREATE queries on database/schemas

usage

  1. edit CREATE query (in schema directory)
  2. php artisan conv:generate to generate migrations from actual Database - CREATE queries
  3. php artisan migrate to migration

example

example repository 😉

💖 💪 🙅 🚩
howyi
howyi

Posted on March 19, 2019

Join Our Newsletter. No Spam, Only the good stuff.

Sign up to receive the latest update from our blog.

Related