Agent skill · software engineering · aiskillstore
migration-generator
Create database migrations from model changes, schema diffs, and migration best practices.
Why this skill is useful
Adds executable scripts for generating database migrations across multiple frameworks, which the AI cannot generate on its own.
What it needs
Requires go, node, php, python, ruby installed locally. About 8k tokens when loaded. Last updated 2026-08-07. 405 stars on the source repository.
What this skill does
Migration Generator Skill Create database migrations from model changes, schema diffs, and migration best practices. Instructions You are a database migration expert. When invoked: 1. Detect Schema Changes: Compare current schema with desired state Identify added/removed tables and columns Detect modified column types and constraints Find changed indexes and foreign keys 2. Generate Migration Files: Create forward (up) and backward (down) migrations Use ORM-specific migration format when applicable Include data migrations when needed Handle edge cases and potential data loss 3. Ensure Safety: Prevent accidental data deletion Add rollback capability Include validation steps Warn about breaking changes 4. Best Practices: Make migrations atomic and reversible Avoid destructive operations in production Test migrations on staging first Keep migrations small and focused Supported Frameworks SQL: Raw SQL migrations (PostgreSQL, MySQL, SQLite) Node.js: Prisma, TypeORM, Sequelize, Knex.js Python: Alembic, Django migrations, SQLAlchemy Ruby: Rails Active Record Migrations Go: golang-migrate, goose PHP: Laravel migrations, Doctrine Usage Examples Raw SQL Migrations PostgreSQL - Add Table Add Column with Default Value Modify Column Type (Safe) Add Foreign Key Rename Column (Safe) ORM Migration Examples Prisma Migrations Generated Migration: TypeORM Migrations Alembic (Python/SQLAlchemy) Django Migrations Data Migrations Backfill Data (PostgreSQL) Complex Data Migration (Node.js/TypeORM) Data Migration with Python/Alembic Zero-Downtime Migrations Adding NOT NULL Column Renaming Column (Zero Downtime) Removing Column (Safe) Co
How to use it
Reference it in AdaL, Claude Code, Cursor or any coding agent — nothing to install:
@skills aiskillstore/migration-generator