2017 © Pedro Peláez
 

library laravel-migration-generator

Generate migrations based on existing database

image

barryvdh/laravel-migration-generator

Generate migrations based on existing database

  • Wednesday, July 23, 2014
  • by Barryvdh
  • Repository
  • 14 Watchers
  • 224 Stars
  • 19,036 Installations
  • PHP
  • 0 Dependents
  • 0 Suggesters
  • 30 Forks
  • 5 Open issues
  • 1 Versions
  • 1 % Grown

The README.md

Laravel4 Migration Generator

Generate migrations based on existing tables

You might want to checkout https://github.com/Xethron/migrations-generator which is similar to this package, but is developed more recently and is using way/generators version 2.x. My package is still on 1.x and I'll have to see when/if I can upgrade. This package does still work, but isn't actively supported currently, (*1)

Require this package in your composer.json:, (*2)

"barryvdh/laravel-migration-generator": "dev-master"

And update dependencies using composer:, (*3)

composer update

And add the ServiceProvider to the providers array in app/config/app.php, (*4)

'Barryvdh\MigrationGenerator\MigrationGeneratorServiceProvider',

You can now generate the migration by running the command, followed by the tables you want to generate, (*5)

php artisan migration-generate posts,users

Your migrations will be created in app/database/migrations, (*6)

Migrations are generated by https://github.com/JeffreyWay/Laravel-4-Generators This assumes the key is 'id' and timestamps (created_at/updated_at) are generated by default., (*7)

The Versions

23/07 2014

dev-master

9999999-dev

Generate migrations based on existing database

  Sources   Download

MIT

The Requires

 

laravel generator migration artisan