Skip to content
Back to skills

Migration Run

ASecurity

Checks migration status, runs pending migrations, and verifies the result

  • 10 stars
  • 0 votes
  • 0 copies
  • 1 view
  • Added June 1, 2026
ai-agentsbashdatabase

Works with

  • cli

Security analysis

A100/100

Scanned June 1, 2026

npx -y skills add berkcangumusisik/claude-code-practices --skill migration-run --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of Migration Run?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for Migration Run
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/berkcangumusisik-migration-run/badge)](https://www.skillsdirectory.com/skills/berkcangumusisik-migration-run)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: migration-run
description: Checks migration status, runs pending migrations, and verifies the result
user-invocable: true
allowed-tools: Bash Read
effort: low
---

## Run Database Migrations

1. Check current migration status:
```bash
npx prisma migrate status 2>/dev/null \
  || npx knex migrate:status 2>/dev/null \
  || npx sequelize-cli db:migrate:status 2>/dev/null \
  || ls migrations/ | tail -5
```

2. Show pending migrations and what each one does (read migration files).

3. Ask for confirmation before running.

4. Run migrations:
```bash
npx prisma migrate deploy 2>/dev/null \
  || npx knex migrate:latest 2>/dev/null \
  || npx sequelize-cli db:migrate 2>/dev/null
```

5. Verify the result - check migration status again to confirm all are applied.

6. If migration fails:
   - Show the exact error
   - Check if it's a data conflict, constraint violation, or connection issue
   - Suggest rollback if needed: `npx prisma migrate reset` (caution: destructive)
   - Provide targeted fix

**Safety rule:** Never suggest dropping data without explicit confirmation and backup verification.

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.