migration-plan

migration-plan is a command for Claude Code from TheBeardedBearSAS/claude-craft. It costs 7 tokens per session (2,445 once invoked), scanned A, original, MIT.

A database-migration planning command for Symfony projects that maps affected tables and dependencies and plans a zero-downtime change with rollback and tests.

In plain words
What is it for?
Use it to plan changes such as adding tables, renaming columns, or introducing document versioning across development, staging, and production.
Why use it?
It exposes migration risks before production changes are made and provides a plan for reversing a failed change.

Command for Claude Code

Written for Claude Code: argument-hint in frontmatter.

Part of the claude-craft plugin — 56 skills, 94 commands, 47 agents, 5 hooks shipped together

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.

agentmods
npx agentmods add commands/thebeardedbearsas/claude-craft/migration-plan
Clone the repo
git clone --depth 1 https://github.com/TheBeardedBearSAS/claude-craft

Made for: Claude Code.

Or install claude-craft, the plugin that ships this one along with the rest of its 56 skills, 94 commands, 47 agents, 5 hooks.

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 migration-plan

README.md
[![agentmods](https://agentmods.dev/badge/commands/thebeardedbearsas/claude-craft/migration-plan.svg)](https://agentmods.dev/commands/thebeardedbearsas/claude-craft/migration-plan)
Your own site
<a href="https://agentmods.dev/commands/thebeardedbearsas/claude-craft/migration-plan"><img src="https://agentmods.dev/badge/commands/thebeardedbearsas/claude-craft/migration-plan.svg" alt="Measured on agentmods" height="20"></a>
Per session 7 Only the description is in the session, so the agent can decide to use it. The body loads when it is invoked.
When invoked 2,445 The whole file, excluding the scripts and references it only reads on demand.
Security scan A 0 findings. Scan, not verified.
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.00007 $0.02445
Opus 5 $0.00003 $0.01222
Sonnet 5 $0.00001 $0.00489
Haiku 4.5 $0.00001 $0.00245

Measured 2d ago against content hash 6c0755347d40, method: parsed. Prices are Anthropic first-party input rates as of 2026-09-06, from the pricing page.

Security

Grade A, and why

migration-plan 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.

.claude/commands/symfony/migration-plan.md · 348 lines

How it starts

The opening of the file, as written. The whole thing — 348 lines — stays where its author put it; the contents beside it link to each section on GitHub.

Planification Migration Base de Données

Tu es un DBA et architecte Symfony senior. Tu dois planifier une migration de base de données complexe avec une stratégie zero-downtime, incluant le rollback et les tests.

Arguments

$ARGUMENTS

Arguments :

  • Description de la migration (ex: "Ajouter table audit_log", "Renommer colonne user.name vers full_name")

Exemple : /symfony:migration-plan "Ajouter système de versioning sur les documents"

MISSION

Étape 1 : Analyser le Changement

══════════════════════════════════════════════════════════════
📋 ANALYSE MIGRATION
══════════════════════════════════════════════════════════════

Description : {Description de la migration}
Date prévue : {YYYY-MM-DD}
Environnements : dev → staging → production

──────────────────────────────────────────────────────────────
🔍 ÉTAT ACTUEL
──────────────────────────────────────────────────────────────

Tables impactées :
- table_1 (X lignes)
- table_2 (Y lignes)

Dépendances :
- Entités : Entity1, Entity2
- Services : Service1, Service2
- Contrôleurs : Controller1

──────────────────────────────────────────────────────────────
⚠️ ÉVALUATION DES RISQUES
──────────────────────────────────────────────────────────────

| Risque | Probabilité | Impact | Mitigation |
|--------|-------------|--------|------------|
| Lock table long | Moyenne | Haute | Migration en étapes |
| Perte de données | Faible | Critique | Backup + test restore |
| Downtime | Moyenne | Haute | Blue/Green + feature flags |

Étape 2 : Stratégie de Migration

Pattern Expand/Contract (Zero-Downtime)
┌─────────────────────────────────────────────────────────────┐
│ PHASE 1: EXPAND (Ajout)                                     │
│ - Ajouter nouvelle colonne/table                            │
│ - Colonne nullable ou avec valeur par défaut                │
│ - Pas de suppression                                        │
│ - App continue de fonctionner                               │
└─────────────────────────────────────────────────────────────┘
                           │
                           ▼
┌─────────────────────────────────────────────────────────────┐
│ PHASE 2: MIGRATE (Données)                                  │
│ - Copier/transformer les données                            │
│ - Batch processing pour gros volumes                        │
│ - Validation des données migrées                            │
└─────────────────────────────────────────────────────────────┘
                           │
                           ▼
┌─────────────────────────────────────────────────────────────┐
│ PHASE 3: UPDATE (Application)                               │
│ - Déployer le code utilisant la nouvelle structure          │
│ - Écriture dans ancien ET nouveau pendant la transition     │
│ - Feature flag si nécessaire                                │
└─────────────────────────────────────────────────────────────┘
                           │
                           ▼
┌─────────────────────────────────────────────────────────────┐
│ PHASE 4: CONTRACT (Nettoyage)                               │
│ - Supprimer l'ancienne colonne/table                        │
│ - Supprimer le code de compatibilité                        │
│ - Peut être fait plus tard, en toute sécurité               │
└─────────────────────────────────────────────────────────────┘

Read the full file on GitHub · 348 lines

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 · 348 lines · 7 tokens per session scan A 6c0755347d40

Subscribe to this mod's changes

migration-plan is a command published in the GitHub repository TheBeardedBearSAS/claude-craft (105 stars, last pushed 3d ago), licensed MIT. It adds 7 tokens to every session and 2,445 once invoked, about $0.0000 per session on Opus 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-09-03.