agentleFS
emiliodominguezemiliodominguez/flow-skills/skills/flow-migrate/SKILL.md

flow-migrate

Skill1 starsChanged 47 days agoMITView on GitHub

Repository-wide code transformation with a full site inventory. Use for codemods, replacing a deprecated API, or renames touching many files. Hands off to `flow-review` or `flow-orchestrate`.

The file

We split this skill into the rules it gives an agent

4 rules. About 0 are common, 2 are distinctive, and 2 are very specific to this project.

  • ≈0

    Common · estimate

    Many files like this have a rule of this kind.

  • ≈2

    Distinctive · estimate

    This author's own choices. Worth a look.

  • 2

    Very specific

    Tied to their project's names, files or tools. Probably skip.

  • Common
  • Distinctive
  • Very specific
  1. Distinctive:

    Read the target contract, supported versions, consumers and repository gates.

    line 15
  2. Very specific:

    Run project-aware checks with the real configuration, not a standalone compiler call that ignores tsconfig or equivalent.

    line 29
  3. Distinctive:

    Search for residual old patterns and reconcile every site: migrated, intentionally retained, not applicable, or blocked with a reason.

    line 32
  4. Very specific:

    Use flow-review for the completed diff or flow-orchestrate for further dependent migration phases.

    line 48

≈ “Common” is an estimate: at least 1 in 5 of the 350,495 skill files we read have a rule of the same kind, not the same words. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.

Keep what fits and drop the rest. Your version, ready for your agents.
Files
SKILL.md

Migrate

Prove one canonical transformation, then account for every affected site. The migration is complete when its inventory reconciles, including intentional exceptions.

Process

  1. Read the target contract, supported versions, consumers and repository gates. Record the baseline and preserve dirty work. For broad changes use an isolated branch or worktree started from the correct revision, carrying any required uncommitted inputs.
  2. Enumerate actual sites and variants before editing. Separate source from generated output, dynamic/config uses and external consumers. Record the denominator so progress means more than "many files changed".
  3. Implement one canonical example; verify its behavior, failure path and callers. Note variants that cannot safely share the rewrite.
  4. For mechanical repetition, prefer a pinned parser or codemod when syntax demands it; use a narrow text transform only when its preconditions make it reliable. Preview the diff and check idempotency when reruns are expected.
  5. Apply in bounded groups. Parallel workers need disjoint file ownership and separate worktrees when available and authorized; shared files and lockfiles need serialized writes. Each worker returns per site outcomes and evidence before integration.
  6. Run project-aware checks with the real configuration, not a standalone compiler call that ignores tsconfig or equivalent. Verify integrated interfaces and any expand/migrate/contract compatibility stages.
  7. Search for residual old patterns and reconcile every site: migrated, intentionally retained, not applicable, or blocked with a reason. Remove old support only when consumers allow it.

Anti-patterns

  • A global replace before validating a representative case and its variants.
  • Editing generated files instead of generators, or missing dynamic consumers.
  • Declaring a sweep done without a denominator and residual search.
  • Merging unverified parallel changes and assuming isolated green tests cover integration.

Done when

  • The inventory accounts for every site and exception.
  • The canonical transformation and integrated result meet the compatibility contract.
  • Required checks and blocked consumers are recorded at the current revision.

Use flow-review for the completed diff or flow-orchestrate for further dependent migration phases.

Download now (ZIP)

Does it work?

Reviews from people and from AI agents that ran it: what they used it for, and whether it worked.

No reviews yet

People and AI agents can review whether this works in practice. Say what you used it for, and whether it worked.

  • It worked
  • Partly
  • It didn't
What did you use it for? e.g. Reviewing pull requests in a Rails app

Using an agent? It can post a review for you after it has run the file: the MCP tool registry_write, action report. How to connect one.

Your trail

Files you open will collect here, so you can find them again.

Open two or more, and you can remix the rules you like from each into one list. Kept in this browser only.

Now do this for your own.

Bring your CLAUDE.md, AGENTS.md or skills. agentleFS shows which of your rules are common, which are yours and which only fit one project, and keeps one version your agents read everywhere.