Want to take your software engineering career to the next level? Join the mailing list for career tips & advice Click here


Generate migrations based on existing tables

Subscribe to updates I use laravel-migration-generator

Statistics on laravel-migration-generator

Number of watchers on Github 223
Number of open issues 5
Average time to close an issue 3 days
Main language PHP
Average time to merge a PR about 5 hours
Open pull requests 0+
Closed pull requests 1+
Last commit almost 6 years ago
Repo Created about 7 years ago
Repo Last Updated over 2 years ago
Size 244 KB
Organization / Authorbarryvdh
Page Updated
Do you use laravel-migration-generator? Leave a review!
View open issues (5)
View laravel-migration-generator activity
View on github
Fresh, new opensource launches 🚀🚀🚀
Software engineers: It's time to get promoted. Starting NOW! Subscribe to my mailing list and I will equip you with tools, tips and actionable advice to grow in your career.
Evaluating laravel-migration-generator for your project? Score Explanation
Commits Score (?)
Issues & PR Score (?)

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

Require this package in your composer.json:

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

And update dependencies using composer:

composer update

And add the ServiceProvider to the providers array in app/config/app.php


You can now generate the migration by running the command, followed by the tables you want to generate

php artisan migration-generate posts,users

Your migrations will be created in app/database/migrations

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.

laravel-migration-generator open issues Ask a question     (View All Issues)
  • about 5 years Is this work with Laravel 5?
  • about 6 years Minor issues with field types on Laravel 4.1
  • over 6 years Support For Way Generators 2.*
  • over 6 years Enum
  • over 6 years Incorrect types
laravel-migration-generator list of languages used
Other projects in PHP