Back to Blog

Combining One Repo into Another Using AI Tools

Joe ReitzJoe Reitz

Just Let the AI Merge the Repos

There might be “better” ways to merge two repos, but honestly, with modern AI tools like Claude, I don’t see a compelling reason to do it another way.

As you build more tools, you’ll eventually hit the point where maintaining multiple repos stops feeling clever and starts feeling annoying. Trust me, I’m there too. To consolidate and reduce my own tech debt, this is my process:

  1. Open my main repo
  2. Open my AI tool of choice (Claude, Cursor, etc.)
  3. Say something like:
“I want to incorporate the repo located at
/Users/me/dev/seo-aeo-generator
into this repo under /tools/seo-aeo.
Fix imports, make it a routable page, and don’t refactor unless necessary.”

Then I let it rip.

This post is about why that works and what you still need to be explicit about.

The Only Prep That Matters

Before you involve an AI, do two things:

  1. Decide where the code should live.
  2. Decide how users should access it.

That’s it.

Example target structure:

/apps

/web

/tools

/seo-aeo

If you can’t answer “where does this live?” and “who can use it?”, the AI can’t either.

Give the AI a Concrete Instruction

Bad prompt:

“Merge these two repos.”

Good prompt:

“Take the repo at /path/to/seo-aeo and incorporate it into this repo under /tools/seo-aeo.

Fix broken imports and routing.

Do not refactor or extract shared code unless required for it to run.”


You’re not asking it to design a system.

You’re asking it to move working code without breaking it.

Let It Do the Mechanical Work

This is where AI actually shines.

  • Copying files.
  • Updating import paths.
  • Fixing relative references.
  • Adapting routing to your app structure.
  • Surfacing what’s broken.

This used to be 30–60 minutes of annoying work, now it’s a few minutes of review. You still review the changes, but you’re just not doing the grunt work anywmore.

Archive the Old Repo When You’re Done

Once the tool lives in the main repo, is routable, and is behind auth, archive or clearly deprecate the old repo. Two sources of truth will confuse you later; it’s not worth the hassle if a couple extra minutes of clean-up can solve for it.

This Is the New Normal

If you’re still manually stitching repos together, you’re doing unnecessary work. The modern workflow is simple:

  • Be explicit about intent.
  • Let AI handle the mechanics.
  • Review.
  • Ship.
  • Move on.

That’s exactly what I show in the video.

  • Open the main repo.
  • Point the AI at the side repo.
  • Tell it what you want.
  • Add auth. if necessary – in this example, I don’t want yall running up my AI Gateway bill ;)
  • Ship.

Join the Discussion

Got thoughts on this post? Let's chat on social.