spawn
Skill0 starsChanged 7 months agoMITView on GitHub
Create a new feature clone for multi-clone parallel development. Clones the repo to <parent>/<repo>--<name>, creates a feature branch, copies env files with unique port, and installs dependencies. Two modes: direct (/spawn auth-refactor) or analyze (/spawn with no args to suggest workstream splits). Use when asked to "spawn", "new clone", "new workstream", "branch off", or "create a workspace".
- Reads credentials
- Installs packages
12 other projects use a version of this.
Adopted by
Most recently taken up by
- OpenRouterLabs/spawntheir own version, first seen Nov 8, 2026
- mrzli/skillstheir own version, first seen Nov 1, 2026
- adventurewave-labs/apsl-coretheir own version, first seen Oct 20, 2026
- OpenRouterTeam/spawntheir own version, first seen Oct 8, 2026
- fuzzyfox/skillstheir own version, first seen Sep 10, 2026
- Hassaan146/claude-skillstheir own version, first seen Jul 25, 2026
Other versions12 projects use a version of this.
Word for word · 0
None found.
Edited · 0
None found.
Wrote their own version · 12
- OpenRouterLabs/spawn★ 251same name
- OpenRouterTeam/spawn★ 251same name
- Hassaan146/claude-skills★ 18same name
- fuzzyfox/skills★ 4same name
- csiddhant796-blip/claude-skills-collection★ 2same name
- Hussain-Elfalah/Agentic-Skills★ 2same name
- mahiunfiltered/claude-code-skills★ 1same name
- nileshteji/skills★ 1same name
- adventurewave-labs/apsl-core★ 0same name
- dariatrainor/claude-skills★ 0same name
2 more not listed
How matches are found. Word for word: the exact same text. Edited: shares passages with this file (“99% same” means 99% of its five-word phrases also appear here; 10% or more counts). Their own version: similar meaning, or, weakest, the same name. We can’t tell which project had it first. Projects are counted among the 200 most-starred candidates, and mentions are links to the repository we found, up to 50 per site, so both counts are a floor.
The file
Show its rules and text
We split this skill into the rules it gives an agent
22 rules. 0 are common, 15 are distinctive, and 7 are very specific to this project.
0
Common
Most of the 8 edited versions we read keep these.
15
Distinctive
This author's own choices. Worth a look.
7
Very specific
Tied to their project's names, files or tools. Probably skip.
- Common
- Distinctive
- Very specific
- Distinctive: line 23
Create a new isolated clone of the current repo for parallel feature development.
- Distinctive: line 34
Run these in parallel:
- Very specific: line 48
If the user provided a feature name (e.g., /spawn auth-refactor), go to Step 4 (Direct mode).
- Distinctive: line 50
If no feature name was provided, go to Step 3 (Analyze mode).
- Very specific: line 56
Use AskUserQuestion to ask:
- Distinctive: line 68
If the user picks 1, go to Step 3c (Quick heuristics).
- Distinctive: line 69
If the user picks 2, go to Step 3b (Deep investigation).
- Distinctive: line 141
If the user enters custom names instead of numbers, use those names for the clones instead of the suggested names.
- Very specific: line 152
Check that BASE_DIR/<base-repo-name>--<feature-name> does not already exist.
- Very specific: line 164
Verify the assigned port is not actively in use: lsof -ti:<port> 2>/dev/null.
- Distinctive: line 172
Use the remote URL (not a local path) so the new clone gets a proper remote.
- Distinctive: line 183
Search for env files in the source clone.
- Distinctive: line 195
Do NOT add variables that don't exist in the source file.
- Very specific: line 208
Prefer the most specific location (e.g., web/ over root if both exist).
- Distinctive: line 212
Check if AGENTS.md in the source clone contains a markdown table with columns matching "Clone", "Port", "Branch", or "URL".
- Very specific: line 214
If found, use AskUserQuestion: "AGENTS.md has a port table.
- Distinctive: line 216
If yes, edit the table in the SOURCE clone's AGENTS.md (the new clone will pick it up on next sync).
- Distinctive: line 233
Never modify the source clone's code — only its AGENTS.md port table (with permission).
- Distinctive: line 234
Never switch branches in the source clone.
- Distinctive: line 235
If git clone fails (SSH key, network), suggest HTTPS URL as a fallback.
- Very specific: line 236
If the user is in a --<name> clone, use the REMOTE URL to clone (not the local path).
- Distinctive: line 238
If creating multiple clones (from analyze mode), create them sequentially and report each one.
“Common” is measured: kept by at least 6 in 10 of the 8 edited versions of this file we could read. “Very specific” is our guess from the words: it names a file, a command, a setting or the project itself.
Files
Spawn — Create a Feature Clone
Create a new isolated clone of the current repo for parallel feature development.
Modes
- Direct:
/spawn <feature-name>— create a single clone for the named feature - Analyze:
/spawnwith no args — scan the repo structure, suggest logical workstream splits, let the user pick which to create
Steps
1. Orient — Identify the source repo
Run these in parallel:
git remote get-url origin— the clone URLgit rev-parse --show-toplevel— repo root pathbasename $(git rev-parse --show-toplevel)— repo directory namegit branch --show-current— current branch
Derive the base repo name by stripping any --<suffix> from the directory name.
Example: job_ai_risk_evaluator--backend has base name job_ai_risk_evaluator.
Set BASE_DIR to the parent directory of the repo root (e.g., ~/Desktop).
Set SOURCE_DIR to the current repo root.
2. Mode selection
If the user provided a feature name (e.g., /spawn auth-refactor), go to Step 4 (Direct mode).
If no feature name was provided, go to Step 3 (Analyze mode).
3. Analyze mode — Suggest workstream splits
3a. Ask about investigation depth
Use AskUserQuestion to ask:
I can suggest workstream lanes two ways:
1. Quick — heuristic split based on directory structure and project type
2. Deep — investigate routes, actions, services, DB schema, and shared
surfaces to propose domain-based lanes (supply/demand style splits
that minimize cross-team file collisions)
Which approach? (1/2)If the user picks 1, go to Step 3c (Quick heuristics). If the user picks 2, go to Step 3b (Deep investigation).
3b. Deep investigation
Perform a thorough codebase analysis to find domain-based ownership boundaries:
- Map all routes/pages — find every page entry point and what it renders
- Map all server actions / API routes — list every exported function and which routes call them
- Map services and data access — which DB tables does each service touch
- Map components — which pages use which components, identify shared vs. single-owner components
- Identify cross-cutting files — files that multiple domains must touch (types, schemas, shared utils)
- Find the seams — look for natural domain boundaries where files cluster together with minimal cross-references. Prefer domain splits (by user persona or business concern) over layer splits (frontend/backend/infra). Layer splits cause more merge conflicts because features span layers.
Produce a brief analysis:
Codebase analysis for <repo-name>:
Tables: <list>
Routes: <list with brief purpose>
Action files: <list with function counts>
Suggested domain lanes:
1. --<name> : <one-line description>
Owns: <key files>
2. --<name> : <one-line description>
Owns: <key files>
3. --<name> : <one-line description>
Owns: <key files>
Shared surfaces (collision risk): <files that span lanes>
Main cross-lane seam: <the #1 file/module where lanes overlap>Then go to Step 3d (User choice).
3c. Quick heuristics
- Check for CLAUDE.md / AGENTS.md — look for a "Workstream Lanes" or "Workstream Boundaries" section. If defined, parse and use those.
- Check for monorepo markers — look for:
- Multiple
package.jsonfiles (not innode_modules) lerna.json,pnpm-workspace.yaml,turbo.json,nx.json- Top-level directories with their own build configs
- Multiple
- Heuristic directory analysis — if no explicit workstreams found:
- Detect project type: Next.js (
next.config.*), Rails (Gemfile+config/routes.rb), Django (manage.py), Go (go.mod), generic - For Next.js/React: suggest splits like
frontend(components, pages, hooks),backend(API routes, server logic),infra(config, deploy, CI) - For monorepos: suggest one clone per package/workspace
- For any repo: look for natural directory clusters that map to concerns
- Detect project type: Next.js (
Then go to Step 3d (User choice).
3d. User choice
- Check existing clones — list
BASE_DIR/<base-repo-name>--*directories to see what already exists. Don't suggest duplicates. Present suggestions using
AskUserQuestion:Suggested workstreams for <base-repo-name>: Existing clones: --backend (feat/backend, port 3002) Suggested new clones: 1. --<name> -> feat/<name> (<description>) 2. --<name> -> feat/<name> (<description>) 3. --<name> -> feat/<name> (<description>) Enter numbers to create (e.g., "1,2"), custom names (e.g., "supply,demand,platform"), or "skip":If the user enters custom names instead of numbers, use those names for the clones instead of the suggested names. This lets users override the naming while still benefiting from the analysis.
- Proceed to Step 4 for each selected clone.
4. Direct mode — Create the clone
For the given feature name:
4a. Validate
- Sanitize the feature name: lowercase, replace spaces with hyphens, strip special characters.
- Check that
BASE_DIR/<base-repo-name>--<feature-name>does not already exist. If it does, stop and report.
4b. Assign a port
Scan for used ports across all sibling clones:
for d in BASE_DIR/<base-repo-name>*; do
grep '^PORT=' "$d/.env.local" "$d/web/.env.local" "$d/frontend/.env.local" 2>/dev/null
doneFind the highest port number in use and assign highest + 1. Default starting port is 3000 if no clones have PORT set.
Verify the assigned port is not actively in use: lsof -ti:<port> 2>/dev/null. If it is, increment and try again.
4c. Clone
git clone <remote-url> BASE_DIR/<base-repo-name>--<feature-name>Use the remote URL (not a local path) so the new clone gets a proper remote.
4d. Create feature branch
cd <new-clone-dir>
git checkout -b feat/<feature-name>4e. Copy and adapt env files
Search for env files in the source clone. Check these locations in order:
.env.localweb/.env.localfrontend/.env.localapp/.env.local.env
For each env file found, copy it to the same relative path in the new clone, then modify ONLY variables that already exist:
PORT=<assigned-port>NEXT_PUBLIC_CLONE_NAME=<feature-name>(if present)NEXT_PUBLIC_BASE_URL=http://localhost:<assigned-port>(if present)
Do NOT add variables that don't exist in the source file.
4f. Install dependencies
Detect the project type and install:
web/package.jsonexists:cd web && npm installpackage.jsonat root (noweb/):npm installfrontend/package.jsonexists:cd frontend && npm installGemfileexists:bundle installrequirements.txtorpyproject.tomlexists:pip install -r requirements.txtorpip install .go.modexists:go mod downloadCargo.tomlexists:cargo fetch
Prefer the most specific location (e.g., web/ over root if both exist).
4g. Update project docs (optional)
Check if AGENTS.md in the source clone contains a markdown table with columns matching "Clone", "Port", "Branch", or "URL".
If found, use AskUserQuestion: "AGENTS.md has a port table. Add a row for --<name>? (y/n)"
If yes, edit the table in the SOURCE clone's AGENTS.md (the new clone will pick it up on next sync).
5. Report
Print a summary:
Spawned: <base-repo-name>--<feature-name>
Path: <full-path>
Branch: feat/<feature-name>
Port: <port>
Server: cd <path>/web && npm run dev
Open this directory in a new Claude Code session to start working.Rules
- Never modify the source clone's code — only its AGENTS.md port table (with permission).
- Never switch branches in the source clone.
- If
git clonefails (SSH key, network), suggest HTTPS URL as a fallback. - If the user is in a
--<name>clone, use the REMOTE URL to clone (not the local path). - Branch naming is always
feat/<name>. - If creating multiple clones (from analyze mode), create them sequentially and report each one.
- Port assignment must be collision-free — always scan ALL sibling clones.
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
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.

