I've recently shipped two updates to my Laravel Migration Generator project β focusing on database normalization, architecture cleanup, and future extensibility.
π v8.1.0 β Schema Normalization
You can now normalize legacy schemas using the new --normalizer=pivot
option:
- Replaces composite primary keys with a synthetic
$table->id()
column - Preserves the original compound key as a
UNIQUE
constraint - Improves compatibility with Eloquent models
Ideal if you're working with databases that were not designed for Laravel-style ORM!
π§± v8.2.0 β Refactored Execution Flow
This release introduces the SchemaMigrationExecutor
and its interface to decouple execution logic from the console command:
- Implements the Separation of Concerns principle (SoC)
- Executor is now resolved via Laravel's service container
- Optionally injects the
SchemaNormalizationManagerInterface
only when needed
Cleaner, more testable, and easier to extend.
π Up Next
I'm currently working on:
- Caching β to improve performance for repeated runs
- Model Generation β automatic Eloquent model scaffolding based on the schema
π οΈ Try it out!
π GitHub: https://github.com/N3XT0R/laravel-migration-generator
If you're migrating legacy databases or want to generate clean Laravel-compatible migrations β this tool might save you hours.
Thanks for reading β feel free to drop feedback or ideas for upcoming versions!
Top comments (0)