migration-planner

Generate ordered migration scripts and rollback plans from schema diffs.

Updated Mar 13, 2026
One-click install
npx skills add https://github.com/jtucker9/mystuff --skill migration-planner-jtucker9
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: migration-planner
Source: https://github.com/jtucker9/mystuff/tree/main/skills/development/migration-planner
Command: npx skills add https://github.com/jtucker9/mystuff --skill migration-planner-jtucker9

SYSTEM DOCUMENTATION & REQUIREMENTS

What problem does it solve?

Planning and executing database migrations is risky without a structured approach. This Skill analyzes schema diffs, generates safe migration scripts with up/down paths, and outlines zero-downtime deployment plans with rollback strategies.

Core Features & Use Cases

  • Analyze current vs desired schema to identify changes
  • Generate UP and DOWN migration scripts with optional data backfills
  • Plan phased deployments and rollback procedures for production environments

Quick Start

Plan a zero-downtime migration to add a nullable column with a default, backfill data, and switch reads.

Frequently Asked Questions about migration-planner

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I plan a zero-downtime database migration with a rollback strategy?

A zero-downtime database migration uses phased deployments and rollback strategies to apply schema changes without taking the application offline. This involves generating ordered migration scripts that handle data backfills and schema diffs safely across staging or production environments.

What is a schema diff and how is it used to generate migration scripts?

A schema diff identifies the differences between your current and desired database schemas. This diff is used to generate UP and DOWN migration scripts, allowing you to apply changes and safely revert them if needed during a database migration.

How do I backfill data when adding a nullable column to a production database?

To backfill data when adding a nullable column, you generate a migration script that adds the column with a default value, populates the existing rows, and switches reads. This phased deployment ensures zero-downtime during the database schema migration process.

Can I generate both UP and DOWN migration scripts for a schema change?

Yes, you can generate both UP and DOWN migration scripts by analyzing the schema diff. The DOWN script provides a rollback strategy to revert the schema change and any associated data backfills if the production deployment encounters issues.

What information do I need to generate a safe database migration plan?

You need the current schema, the desired schema, the database type, and your risk tolerance. This information is used to generate ordered migration scripts, data backfill procedures, and a rollback plan tailored to your production or staging environment.

When should I use a phased deployment for a database schema migration?

You should use a phased deployment for a database schema migration when you need zero-downtime updates in production. This approach safely applies schema diffs and data backfills incrementally, ensuring you can execute a rollback strategy if necessary.