sprawl graft

Workspace Lifecycle

Surgically stitches Sprawl DNA onto an existing legacy project without touching existing source code.


📌 1. The Target Problem

1. The Target Problem

"How do I secure an existing project that contains disorganized, legacy editor rules files without losing our custom configurations?"

Over time, codebases accumulate multiple conflicting rules files (Cursor, Cline, Windsurf) representing different developer settings. AI agents reading these files get confused. Deleting them breaks custom setups, while leaving them wastes token budgets.


⚙️ 2. Usage & Options

sprawl graft

Options & Flags

  • --verbose: Dump diagnostic file traversal logs during migration.

🔍 3. How it Works (Under the Hood)

  1. Scans the active directory recursively for files like .cursorrules, .clinerules, or .windsurfrules.
  2. Harvests their contents, placing them inside .agents/rules/ prefixed with local_.
  3. Registers these local files inside the newly generated sprawl_manifest.yml manifest, converting them into version-controlled baseline assets.

🩺 4. Troubleshooting

  • Error: Not in a git repository
  • Resolution: Sprawl graft operates in existing git workspaces. Ensure you are in the root directory of your git project.

🔗 Related Resources & Tutorials