Skip to content
Skill

Migration loop

Migrates a fixed set of code targets one at a time, verifying with tests and grep

Migration loop is an open-source agent skill for developer tools. It is available on Claude Code.

Scripts
None
Platforms
Claude Code
GitHub stars
12
Last commit
License
MIT
Listing updated

Similar skills

About Migration loop

Migration loop works through an enumerated list of targets, applying the same transform to one target per iteration. After each change it re-runs the full test suite, commits a checkpoint named for that target, and marks the target done in a checklist file. Every entry starts as not migrated, so the loop assumes the job is unfinished until the evidence shows otherwise.

Completion requires three things observed together: every checklist entry is marked migrated, the whole suite exits successfully, and a grep for the legacy pattern returns zero matches. The loop treats a green suite alone as insufficient, since it only shows that touched code still works. It also covers an expand, migrate, contract sequence for changes that would break many call sites at once, and it stops and escalates when progress stalls for several rounds instead of weakening the grep or skipping tests.

The skill is written for Claude Code, depends on a companion loop-controller skill for guardrails, and can dispatch to fix-until-green or the database migration role for schema changes. It works with Read, Write, Edit, Bash, Grep, Glob and Agent tools, and relies on git for per-target checkpoint commits.

When your agent uses it

Migrate an enumerated set of targets one per iteration: transform, verify the suite stays green, checkpoint, mark done, until every target is migrated and a grep for the old pattern returns zero. Use for codemods, framework or test-runner swaps, API version bumps, renames across a repo. Trigger on "migrate everything from X to Y", "run the codemod across the repo", "finish the migration".

From the skill's SKILL.md. Your agent reads this description to decide when to load the skill.

What it can access

From a static check of its 2 files (20 KB) on GitHub on 4 December 2026. Nothing was run. Read the files before you install a skill: it can tell your agent to run anything its tools allow.

Check another skill before you install it.

Install

This skill ships in the skill-madness plugin. In Claude Code, add the marketplace and install the plugin (it may include other skills too):

/plugin marketplace add ivy00johns/Skill-Madness
/plugin install skill-madness@skill-madness

Or copy only this skill to ~/.claude/skills/migration-loop:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.claude/skills &&
rm -rf ~/.claude/skills/migration-loop &&
cp -R "$tmp/skills/loops/migration-loop" ~/.claude/skills/migration-loop &&
rm -rf "$tmp"

For one project only, put the folder in .claude/skills/migration-loop inside it instead.

Claude Code docs on skills

Copy the skill folder to ~/.agents/skills/migration-loop to use it in every repository:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.agents/skills &&
rm -rf ~/.agents/skills/migration-loop &&
cp -R "$tmp/skills/loops/migration-loop" ~/.agents/skills/migration-loop &&
rm -rf "$tmp"

For one repository only, put the folder in .agents/skills/migration-loop inside it instead.

Codex docs on skills

Copy the skill folder to ~/.cursor/skills/migration-loop to use it in every project:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.cursor/skills &&
rm -rf ~/.cursor/skills/migration-loop &&
cp -R "$tmp/skills/loops/migration-loop" ~/.cursor/skills/migration-loop &&
rm -rf "$tmp"

For one project only, put the folder in .cursor/skills/migration-loop inside it instead.

Cursor docs on skills

Run in a terminal (add --scope workspace to install it for the current workspace only):

gemini skills install https://github.com/ivy00johns/Skill-Madness.git --path skills/loops/migration-loop

Or copy the folder to ~/.gemini/skills/migration-loop yourself.

Gemini CLI docs on skills

For GitHub Copilot in VS Code, copy the skill folder to ~/.copilot/skills/migration-loop:

tmp=$(mktemp -d) &&
git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git "$tmp" &&
mkdir -p ~/.copilot/skills &&
rm -rf ~/.copilot/skills/migration-loop &&
cp -R "$tmp/skills/loops/migration-loop" ~/.copilot/skills/migration-loop &&
rm -rf "$tmp"

For one project only, put the folder in .github/skills/migration-loop inside it instead.

VS Code docs on skills

Get the folder:

git clone --depth 1 https://github.com/ivy00johns/Skill-Madness.git

Then copy Skill-Madness/skills/loops/migration-loop into your agent's skills folder as migration-loop. Agents that support SKILL.md read one folder per skill.

The SKILL.md format

What it does

Enumerated target checklist
Builds a default-fail JSON checklist of every occurrence to migrate, with old-to-new mappings.
One target per iteration
Transforms a single target, runs the suite, and commits a checkpoint before advancing.
Legacy pattern grep proof
Confirms completion with a grep for the old pattern returning zero matches.
Expand, migrate, contract mode
Sequences breaking changes as add-new, migrate call sites in batches, then remove the old form.
Stall and cap guardrails
Stops and escalates after repeated no-progress rounds or when iteration caps are reached.
Parallel worktree fan-out
Supports splitting large uniform sets across isolated worktrees for parallel migration.

Good for

  • Migrate every test file from Jest to Vitest
  • Run a codemod across the whole repository
  • Rename a function or import everywhere it is used
  • Bump an API version across all call sites
  • Finish a framework migration until no old usages remain

Migration loop FAQ

What does Migration loop need to run?

It requires Claude Code, a test suite the transform can be verified against, and git for per-target checkpoint commits. It uses Read, Write, Edit, Bash, Grep, Glob and Agent tools.

Does Migration loop change the database?

Reversible code transforms run without a human check, but irreversible resources such as live database schema migrations pause for human approval and are routed to a separate database migration role.

How does Migration loop know the migration is complete?

It requires every checklist entry marked migrated, the full test suite exiting 0, and a grep for the legacy pattern returning zero matches, all observed together.

Can Migration loop run automatically?

Model invocation is disabled, so it runs when a user types the command or when the orchestrator dispatches it, not automatically.

How do I install Migration loop in Claude Code?

Copy the skill folder from GitHub to ~/.claude/skills/migration-loop to use it in all your projects, or to .claude/skills/migration-loop in one project. Or install the skill-madness plugin, which includes it: /plugin marketplace add ivy00johns/Skill-Madness, then /plugin install skill-madness@skill-madness.

Does Migration loop run scripts?

No. It is instructions only, with no scripts. This comes from a static check of the files on GitHub; nothing was run. Read the files before you install it.

Which AI agents can use Migration loop?

Claude Code. It reads skills in the SKILL.md format; the install steps on this page show where to put the folder.

What are the best alternatives to Migration loop?

The closest alternatives to Migration loop are Autonomous loops, Migrate to codex, Figure it out, Migrate legacy and Coverage loop.

Where this comes from

  • Description: from the skill's own SKILL.md.

More from ivy00johns/Skill-Madness

  1. Finds merged and stale git branches, then deletes them only after your confirmation

    • Open source
    • 12 GitHub stars
    • Developer tools
  2. Finds and removes git worktrees whose changes are already merged into main

    • Open source
    • 12 GitHub stars
    • Developer tools
  3. Bulk-scans a skill ecosystem for consistency, quality gaps and ownership conflicts

    • Open source
    • 12 GitHub stars
    • Developer tools
  4. Runs a single-skill quality review covering structure, triggering and output checks

    • Open source
    • 12 GitHub stars
    • Developer tools
  5. Turns skill review or audit reports into a prioritized list of concrete SKILL.md fixes

    • Open source
    • 12 GitHub stars
    • Developer tools
  6. Applies planned edits to SKILL.md files, validates them, and offers to sync

    • Open source
    • 12 GitHub stars
    • Developer tools