db-migrate

Automate Drizzle ORM database migrations for Neon Postgres with validation and drift detection.

5|1|Updated Feb 11, 2026
One-click install
npx skills add https://github.com/Tristan578/project-forge --skill db-migrate-tristan578
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: db-migrate
Source: https://github.com/Tristan578/project-forge/tree/main/.claude/skills/db-migrate
Command: npx skills add https://github.com/Tristan578/project-forge --skill db-migrate-tristan578

SYSTEM DOCUMENTATION & REQUIREMENTS

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

What problem does it solve?

Drizzle schema changes and Neon Postgres migrations are risky without a repeatable, auditable workflow. This workflow guides developers to validate changes, generate proper migration files, and apply them safely across environments.

Core Features & Use Cases

  • Schema-change workflow for SpawnForge using Drizzle ORM and Neon Postgres
  • Generate, validate, and apply migrations with built-in safety checks
  • Automates detection of drift between schema.ts and migrations and enforces cascade rules

Quick Start

Modify web/src/lib/db/schema.ts, then run the generate command to create a migration, review it, and apply it with migrate in staging before production.

Frequently Asked Questions about db-migrate

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

FAQPage Schema
How do I automate database migrations with Drizzle ORM and Neon Postgres?

Automating database migrations with Drizzle ORM and Neon Postgres involves modifying schema.ts, running the generate command to create migration files, reviewing them, and applying changes via the migrate action with validation and Neon-specific cascade checks.

What is database schema drift and how do I validate it before pushing migrations?

Database schema drift happens when schema.ts and existing migrations fall out of sync. Use the validate and status actions to detect drift and enforce Neon-specific constraints before applying changes to production environments.

Can I push Drizzle schema changes directly to Neon Postgres without generating migration files?

Yes, the push action applies Drizzle schema changes directly to Neon Postgres. However, generating migration files first via the generate action is recommended to maintain a repeatable, auditable deployment workflow across environments.

Does this database migration workflow enforce Neon Postgres specific constraints?

Yes, the workflow enforces Neon-specific constraints during database migrations. It applies validation and cascade checks to schema.ts changes, ensuring safe generation and application of migration files across your environments.

What is the safest way to apply Drizzle migrations across staging and production environments?

The safest way to apply Drizzle migrations is to generate migration files from schema.ts, review them, and use the migrate action in staging before production. This process ensures validation and cascade checks pass safely.