db-migrations

Generate and manage database migration files with idempotent SQL.

Updated Aug 23, 2026
One-click install
npx skills add https://github.com/dodevproject/lobe-chat --skill db-migrations
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: db-migrations
Source: https://github.com/dodevproject/lobe-chat/tree/main/.agents/skills/db-migrations
Command: npx skills add https://github.com/dodevproject/lobe-chat --skill db-migrations

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes references (resource) components.

What problem does it solve?

This Skill provides a structured and safe way to manage database schema changes and migrations, ensuring data integrity and consistency.

Core Features & Use Cases

  • Generate Migrations: Automatically create migration files based on schema definitions.
  • Custom Migrations: Support for non-schema-related SQL commands like creating extensions.
  • Idempotent SQL: Guides users to write safe, re-runnable SQL statements for robust migrations.
  • Use Case: When adding a new column to the 'users' table, use this Skill to generate the migration, ensure the SQL is safe to re-run, and update the database client.

Quick Start

Use the db-migrations skill to generate a new database migration.

Frequently Asked Questions about db-migrations

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

FAQPage Schema
How do I generate database migrations from a schema definition?

To generate database migrations, this Skill automatically creates migration files based on your existing schema definitions, ensuring data integrity and consistency during schema evolution.

What is an idempotent SQL migration and why do I need it?

An idempotent SQL migration consists of safe, re-runnable SQL statements. You need it to ensure robust schema modifications and maintain database integrity during repeated deployment cycles.

Can I write custom SQL statements for non-schema related database changes?

Yes, you can write custom SQL statements for non-schema related database changes, such as creating extensions, ensuring all database modifications are handled through a guided migration process.

How do I manage database schema changes safely during development?

To manage database schema changes safely during development, this Skill provides a structured migration process that facilitates schema evolution while ensuring data integrity and consistency across deployment cycles.

Does this Skill support Drizzle ORM for schema evolution?

Yes, this Skill supports Drizzle for schema evolution and management, guiding you through generating new migration files and handling custom SQL statements for safe schema modifications.

What is the best way to add a new column to an existing SQL database table?

The best way to add a new column to an existing SQL database table is using this Skill to generate the migration, ensure the SQL is idempotent, and safely update the database client.