Weave Code
Code Weaver
Helps Laravel developers discover, compare, and choose open-source packages. See popularity, security, maintainers, and scores at a glance to make better decisions.
Feedback
Share your thoughts, report bugs, or suggest improvements.
Subject
Message

Laravel Migrations Generator Laravel Package

kitloong/laravel-migrations-generator

Generate Laravel migration files from an existing database schema, including columns, indexes, and foreign keys. Works with MariaDB/MySQL, PostgreSQL, SQL Server, and SQLite. Generate all tables or target/ignore specific tables via Artisan.

View on GitHub
Deep Wiki
Context7

Log With Batch

--log-with-batch[=LOG-WITH-BATCH]

By default, the command will ask for the batch number to log the generated migrations.

Do you want to log these migrations in the migrations table? (yes/no) [yes]:
 > yes

 Next Batch Number is: 11. We recommend using Batch Number 0 so that it becomes the "first" migration. [Default: 0] [0]:

The --log-with-batch option allows you to specify the batch number for logging the generated migrations.

By using --log-with-batch, you can skip the prompt for the batch number and directly log the migrations with the specified batch number.

Example

php artisan migrate:generate --log-with-batch=0

Will generate the migration files and log them in the migrations table with 0 as the batch number.

SELECT migration FROM `migrations` WHERE batch = 0;

+----------------------------------------------------------+
| migration                                                |
+----------------------------------------------------------+
| 2024_10_08_083231_create_users_table.php                 |
| 2024_10_08_083231_create_comments_table.php              |
| 2024_10_08_083232_add_foreign_keys_to_comments_table.php |
+----------------------------------------------------------+
Weaver

How can I help you explore Laravel packages today?

Conversation history is not saved when not logged in.
Prompt
Add packages to context
No packages found.
codifyo/ts-generator-bundle
andydefer/laravel-cluster
testo/fiber
mintobit/jobqueue
a4sex/maintenance-bundle
a4sex/entity-date-update
a4sex/client-identifier
a4sex/base-utilites
a4sex/key-value-storage
a4sex/micro-status
chilldev/dependency-injection-extra
datinglibre/datinglibre-app-api
biberltd/corebundle
bricre/symfony-bundle-test
biberltd/logbundle
dominium/http-adapter-bundle
dominium/google-analytics
a4sex/auto-clean-entity
christhompsontldr/laravel-inky
spatie/mailcoach-vapor