db-migrate

db-migrate is a skill for Claude Code from suxrobGM/jobpilot. It costs 42 tokens per session (541 once invoked), scanned A, original, MIT.

A tool for creating and applying Prisma database migrations, which are controlled changes to a PostgreSQL database's structure, such as adding a table or column. It works with a remote database reached through an SSH tunnel.

In plain words
What is it for?
Use it to create migration files, inspect changes such as renames, apply approved migrations, and regenerate the database client.
Why use it?
It provides a safer process for changing database structure while checking the tunnel, reviewing the generated SQL, and avoiding accidental data loss.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

Good fit Use it to create migration files, inspect changes such as renames, apply approved migrations, and regenerate the database client.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/suxrobgm/jobpilot/db-migrate
Install

Getting it into your agent

One page per mod, every tool's command on it. A separate URL per tool would split the same page into five that compete with each other.

Any agent
npx skills add suxrobGM/jobpilot --skill db-migrate
Clone the repo
git clone --depth 1 https://github.com/suxrobGM/jobpilot

Made for: Claude Code.

Wrote this? Show the measurements

A badge with what this costs and how it scanned, read live from this page, so it follows the numbers instead of freezing them. Markdown for a README, HTML for a documentation site or a project page.

agentmods badge for db-migrate

README.md
[![agentmods](https://agentmods.dev/badge/skills/suxrobgm/jobpilot/db-migrate/github.svg)](https://agentmods.dev/skills/suxrobgm/jobpilot/db-migrate)
Your own site
<a href="https://agentmods.dev/skills/suxrobgm/jobpilot/db-migrate"><img src="https://agentmods.dev/badge/skills/suxrobgm/jobpilot/db-migrate/github.svg" alt="Measured on agentmods" height="20"></a>

Or the 80×15 button, for a site that already has a row of RSS and ATOM ones. Only the verdict fits; the numbers stay here.

agentmods 80×15 button for db-migrate

Your own site · 80×15
<a href="https://agentmods.dev/skills/suxrobgm/jobpilot/db-migrate"><img src="https://agentmods.dev/badge/skills/suxrobgm/jobpilot/db-migrate.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 42 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 541 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. A grade says what 26 rules found in the file — not that it is safe. Third-party audits
  • NVIDIA SkillSpector pass 7 Sept 2026
How audits are shown
Origin original No closer match found in the catalogue.
Token cost

What it costs to keep this loaded

Counted locally with the o200k_base tokenizer, which is exact for GPT models; Claude uses its own tokenizer and its counts differ. Treat this as one consistent yardstick across the catalogue rather than a bill. Prices are per million input tokens.

ModelPer sessionOnce invoked
Fable 5.1 $0.00042 $0.00541
Opus 5.5 $0.00017 $0.00216
Sonnet 5.5 $0.00008 $0.00108
Haiku 4.5 $0.00004 $0.00054

Measured today against content hash fd953321ecb3, method: parsed. Prices are Anthropic first-party input rates as of 2026-10-07, from the pricing page.

Security

Grade A, and why

db-migrate scanned grade A with 0 findings against 26 rules in 11 categories — prompt injection, anti-refusal, data exfiltration, privilege escalation, supply chain, agent snooping, system-prompt leakage, SSRF and excessive agency — measured today.

A static scan of the body, not an audit. Every finding is printed with the line that produced it so you can judge whether it matters here. A mod is markdown that instructs an agent; that is exactly why what it instructs is worth reading.

Nothing flagged

None of the 26 patterns this scan looks for appear in this file: no shell pipes, no recursive deletes, no credential paths, no hidden text, no instruction-override or anti-refusal phrasing, no agent-config snooping. That is not a guarantee, it is the absence of the things that are checkable.

.claude/skills/db-migrate/SKILL.md · 32 lines

What it actually says

DB migrate

The tunneled database (bun run db:tunnel, localhost:5433) is production. prisma migrate dev can demand a reset there, which wipes it, so never run it. All commands are bun --cwd=apps/api run ….

  1. Edit the schema - split by domain under apps/api/prisma/schema/*.prisma.
  2. Restore a throwaway copy: pg_dump prod through the tunnel, restore it into a local PostgreSQL on another port (e.g. 5434), and point DATABASE_URL at it for every step below until step 6. A local PostgreSQL and the tunnel both default to 5433 - check docker ps first.
  3. db:diff prints the SQL from the database to the schema (read-only). Save it as apps/api/prisma/migrations/<yyyymmddhhmmss>_<name>/migration.sql and edit it: Prisma turns renames into drop + add - hand-edit to ALTER ... RENAME when data must survive. Data fixes that need TS logic go in a one-off apps/api/scripts/<name>.ts with a --dry-run report. migrate deploy applies every pending migration at once, so a script can't run between two of them. When the migration needs the script's output, run the script first against the old schema, have it fill a staging table the migration joins on, and make the migration RAISE EXCEPTION before any change if rows are left unmapped (20261026070000_board_ids in git history). Partial unique indexes aren't in the Prisma schema; db:diff won't emit them, so write them by hand.
  4. db:migrate:apply against the copy, run the data script, spot-check counts and samples, and run the app against the copy. Then db:generate.
  5. Ask the user before touching production.
  6. Production: fresh pg_dump backup, db:migrate:apply through the tunnel, the data script, then deploy the matching images back to back. Never leave code that accepts both shapes.

Never run db:reset without explicit user confirmation - it wipes the database it points at.

Changes

What this file has done since we first saw it

Hashed on every crawl. A supply-chain change to an agent config is a question of when, not whether, so the history is kept rather than the latest state alone.

  1. today Changed · +12 lines fd953321ecb3
  2. 1mo ago First seen · 20 lines · 42 tokens per session scan A a357c9145a1c

Subscribe to this mod's changes

db-migrate is a skill published in the GitHub repository suxrobGM/jobpilot (102 stars, last pushed yesterday), licensed MIT. It adds 42 tokens to every session and 541 once invoked, about $0.0002 per session on Opus 5.5. A static security scan graded it A with 0 findings. No closer match exists in the catalogue, so it is treated as the original; first seen 2026-08-30.