database-migration

Generate up and down database migration scripts for Knex, Prisma, and TypeORM.

32|3|Updated Jan 21, 2026
One-click install
npx skills add https://github.com/dkyazzentwatwa/SuperNavigator --skill database-migration-dkyazzentwatwa
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: database-migration
Source: https://github.com/dkyazzentwatwa/SuperNavigator/tree/main/navigator-main/skills/database-migration
Command: npx skills add https://github.com/dkyazzentwatwa/SuperNavigator --skill database-migration-dkyazzentwatwa

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill automates the creation of database migration files, ensuring schema changes are applied safely and can be rolled back if necessary.

Core Features & Use Cases

  • Automated Migration Generation: Creates up and down migration scripts for various frameworks (Knex, Prisma, TypeORM).
  • Framework Detection: Automatically identifies the project's migration framework.
  • ToM Verification: Includes a mandatory "Theory of Mind" checkpoint to verify understanding before executing critical database changes.
  • Use Case: When you need to add a new column to the users table, this skill will generate the necessary migration files for both applying the change and rolling it back, after confirming your intent.

Quick Start

Use the database-migration skill to create a migration for adding a new column named 'email' to the 'users' table.

Frequently Asked Questions about database-migration

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

FAQPage Schema
How do I generate safe database migration scripts with rollback support?

To generate database migration files, the skill automatically detects your framework and creates paired up and down scripts for schema changes. It includes validation checks to prevent common issues like adding NOT NULL columns without defaults.

How do I create a migration for adding a NOT NULL column without breaking existing rows?

When adding a NOT NULL column, the skill performs validation checks to detect missing defaults and warns you before generating the migration. This prevents constraint violations and broken rows during the schema update.

Can I use this to generate Prisma migrations alongside TypeORM and Knex?

Yes, Prisma migrations are supported alongside TypeORM and Knex. The skill automatically detects your project's migration framework and generates the corresponding up and down scripts tailored to that environment.

What is Theory of Mind verification in database schema migrations?

Theory of Mind verification is a mandatory checkpoint that confirms your intent before executing critical database changes. It ensures the system correctly understands the schema modification to prevent unintended data loss or unsafe operations.

How do I automatically detect which migration framework my project is using?

Framework detection is handled automatically by scanning your project for Knex, Prisma, or TypeORM configurations. Once identified, the system generates migration files matching the detected framework's specific syntax and structure.