What problem does it solve? Reverting a database schema after a failed or breaking migration is risky and error-prone. This Skill provides a guarded, step-by-step rollback workflow for Supabase/PostgreSQL databases with automatic safety snapshots, locking, and validation. ## Core Features & Use Cases - Guarded Rollback Execution: Requires explicit user confirmation, creates an emergency snapshot before any change, and acquires an advisory lock to prevent concurrent operations. - Multiple Rollback Strategies: Supports snapshot restore, explicit rollback scripts, and forward-fix migrations, with a decision matrix to choose the right approach. - Post-Rollback Validation: Verifies schema object counts, runs sanity checks, and creates a post-rollback snapshot for auditability. - Use Case: A migration breaks your application in staging. Run the rollback against the pre-migration snapshot, then follow up with smoke tests and an RLS audit to confirm the schema is healthy. ## Quick Start Ask the agent to roll back the database to a specific snapshot file, for example: roll back the database to supabase/snapshots/20251026_pre_migration.sql.