code-database-migrations

code-database-migrations is a skill for Claude Code from KornLabs/truss. It costs 92 tokens per session (2,866 once invoked), scanned A, original, no licence file.

A guide to changing database structure and data safely, with patterns for reversible changes, zero-downtime updates, indexes, and large data updates.

In plain words
What is it for?
Use it when adding or changing columns and indexes, renaming fields, moving existing data, or writing migrations with Prisma, Drizzle, Kysely, Django, or golang-migrate.
Why use it?
It helps prevent broken deployments, lost data, and downtime when an application's database changes. It also explains workflows for several database tools and PostgreSQL.

Skill for Claude Code

Written for Claude Code: installed under .claude/.

Good fit Use it when adding or changing columns and indexes, renaming fields, moving existing data, or writing migrations with Prisma, Drizzle, Kysely, Django, or golang-migrate.

Compare 6 skills from other repositories ↓
Install with agentmods
npx agentmods add skills/kornlabs/truss/code-database-migrations
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 KornLabs/truss --skill code-database-migrations
Clone the repo
git clone --depth 1 https://github.com/KornLabs/truss

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 code-database-migrations

README.md
[![agentmods](https://agentmods.dev/badge/skills/kornlabs/truss/code-database-migrations/github.svg)](https://agentmods.dev/skills/kornlabs/truss/code-database-migrations)
Your own site
<a href="https://agentmods.dev/skills/kornlabs/truss/code-database-migrations"><img src="https://agentmods.dev/badge/skills/kornlabs/truss/code-database-migrations/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 code-database-migrations

Your own site · 80×15
<a href="https://agentmods.dev/skills/kornlabs/truss/code-database-migrations"><img src="https://agentmods.dev/badge/skills/kornlabs/truss/code-database-migrations.svg" alt="Reviewed on agentmods" width="80" height="20"></a>
Per session 92 Skills are progressive disclosure: only the name and description are preloaded; the body loads when the skill is used.
When invoked 2,866 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.
Origin unknown 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.00092 $0.02866
Opus 5.5 $0.00037 $0.01146
Sonnet 5.5 $0.00018 $0.00573
Haiku 4.5 $0.00009 $0.00287

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

Security

Grade A, and why

code-database-migrations 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 2d ago.

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.

.truss/baseline/.claude/skills/code-database-migrations/SKILL.md · 432 lines

The source is not reproduced here

A licence we could not identify

The repository carries a LICENSE file, but it is custom or dual enough that GitHub cannot name it and neither can this catalogue. Unknown terms are not permission, so the body is not copied here. Read the licence at the source and decide for yourself.

Read it on GitHub

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. 2d ago First seen · 432 lines · 92 tokens per session scan A e88ee6b2cbdd

Subscribe to this mod's changes

code-database-migrations is a skill published in the GitHub repository KornLabs/truss (2 stars, last pushed yesterday), with no licence file. It adds 92 tokens to every session and 2,866 once invoked, about $0.0004 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-10-23.

Related

Other skills, from other repositories

database-operations

Inspect schemas, debug queries, plan migrations, and validate data changes across common relational databases.

metaspartan/cybara · 22 tokens

postgresql-table-design

Use this skill when designing or reviewing a PostgreSQL-specific schema. Covers best-practices, data types, indexing, constraints, performance patterns, and advanced features.

FluxonLab/Skillry · 37 tokens

postgresql-optimization

PostgreSQL-specific development assistant focusing on unique PostgreSQL features, advanced data types, and PostgreSQL-exclusive capabilities. Covers JSONB operations, array types, custom types, range/geometric types, full-text search, window functions, and PostgreSQL extensions ecosystem.

FluxonLab/Skillry · 57 tokens

postgres-supabase-review

Postgres/Supabase: table design, indexes, RLS, Edge Functions, query plans, N+1, pagination, SQL tuning.

FluxonLab/Skillry · 35 tokens

Azure Postgres Ts

Connect to Azure Database for PostgreSQL Flexible Server from Node.js/TypeScript using the pg (node-postgres) package. Use for PostgreSQL queries, connection pooling, transactions, and Microsoft Entra ID (passwordless) authentication. Triggers: "PostgreSQL", "postgres", "pg client", "node-postgres", "Azure PostgreSQL…

mayurrathi/awesome-agent-skills · 94 tokens

Azure Resource Manager Postgresql Dotnet

Azure PostgreSQL Flexible Server SDK for .NET. Database management for PostgreSQL Flexible Server deployments. Use for creating servers, databases, firewall rules, configurations, backups, and high availability. Triggers: "PostgreSQL", "PostgreSqlFlexibleServer", "PostgreSQL Flexible Server", "Azure Database for…

mayurrathi/awesome-agent-skills · 97 tokens