Skip to content

WoodyJ2H/claude-code-clone

Repository files navigation

Claude Code Family — Multi-PC Synchronized Development

Clone your entire development environment across machines using Claude Code, SMB shares, and automated PowerShell scripts.

Perfect for:

  • Parents & kids coding together on separate machines
  • Developers with multiple laptops (office + home)
  • Teaching assistants managing student environments
  • Pair programming setups with instant sync

What This Does

PC 1 (Main)                    Network SMB Share (T:\)                PC 2 (Secondary)
├── .env                       ├── secrets/                          ├── .env
├── credentials                ├── memory/ (80 files)                ├── credentials
├── SSH keys          ←→       ├── ssh/                      ←→      ├── SSH keys
├── .claude/                   ├── CLAUDE.md                         ├── .claude/
└── Node.js + Python           └── INSTALL.ps1                       └── Node.js + Python

Run one PowerShell script on PC 2. Everything syncs automatically:

  • Secrets (.env, API keys, credentials)
  • Claude Code configuration & memory (80 markdown files)
  • SSH keys for VPS access
  • Node.js + Python dependencies
  • n8n MCP servers configuration

Result: Identical development environment, no manual copy-paste.


Quick Start

Prerequisites

On both PCs:

Network:

  • Both PCs on same local network (LAN)
  • One PC with shared folder (Primary PC)
  • Network access credentials (if using passwords)

Step 1: Share the Setup Folder (Primary PC)

On your main PC (ROGSTRIXJH in the example):

  1. Create a folder: T:\TwinSetup\ (or C:\TwinSetup\)
  2. Copy this repo into it
  3. Right-click → PropertiesShare → Allow network access
  4. Note the network path: \\PCNAME\TwinSetup

Step 2: Map Network Drive (Secondary PC)

On your second PC (ASUSZENBOOK in the example):

  1. File ExplorerThis PCMap Network Drive
  2. Choose drive letter (e.g., T:)
  3. Paste network path: \\ROGSTRIXJH\TwinSetup
  4. Reconnect at sign-in (recommended)

Step 3: Run Installation Script (Secondary PC)

Open PowerShell as Administrator and run:

# Option A: Run from mapped drive
cd T:\TwinSetup
.\INSTALL.ps1

# Option B: Run from GitHub (if drive mapping fails)
powershell -ExecutionPolicy Bypass -Command "& { (Invoke-WebRequest -Uri 'https://raw.githubusercontent.com/WoodyJ2H/claude-code-family/main/INSTALL.ps1').Content | Invoke-Expression }"

The script will:

  • ✅ Verify Node.js, Python, Git are installed
  • ✅ Install Claude Code CLI globally
  • ✅ Create C:\CLAUDE CODE folder
  • ✅ Copy secrets from network share
  • ✅ Copy Claude Code config & memory files
  • ✅ Copy SSH keys for VPS access
  • ✅ Install Python dependencies

What Gets Synced

Item Source (PC 1) Destination (PC 2) Purpose
.env T:\secrets\ C:\CLAUDE CODE\ API keys, tokens, database URLs
credentials.json T:\secrets\ C:\CLAUDE CODE\JOB SEEKING\ Google OAuth tokens
token.json T:\secrets\ C:\CLAUDE CODE\JOB SEEKING\ Google API refresh tokens
linkedin-cookie.md T:\secrets\ C:\CLAUDE CODE\Credentials\ LinkedIn session data
CLAUDE.md T:\ ~\.claude\ Global Claude Code instructions
Memory files (80 .md) T:\memory\ ~\.claude\projects\c--CLAUDE-CODE\memory\ Project context & learnings
SSH keys (9 files) T:\ssh\ ~\.ssh\ SSH access to VPS / GitHub
MCP config T:\.mcp.json C:\CLAUDE CODE\ n8n-mcp, Hostinger, etc.

Troubleshooting

"Network path not found"

  • Primary PC: Verify the folder is shared. Right-click → Properties → Share tab → "Share..." button
  • Secondary PC: Try UNC path directly: \\ROGSTRIXJH\TwinSetup (replace ROGSTRIXJH with your main PC's name)
  • Check Windows Firewall/Norton: Allow SMB (port 445)

PowerShell script closes immediately

  • Open PowerShell as Administrator
  • Navigate to T:\TwinSetup first: cd T:\TwinSetup
  • Run: .\INSTALL.ps1
  • (Not: double-click the .ps1 file)

"Credentials not valid"

  • Main PC: Set a network password (Microsoft Account or local password)
  • Secondary PC: Enter credentials when prompted (domain\username format, e.g., ROGSTRIXJH\jhhig)
  • If still blocked: Disable password protection on the share temporarily

Drive mapping disappears

  • Reopen File ExplorerThis PCMap Network Drive
  • Check "Reconnect at sign-in"
  • If network is "Public": Switch to "Private" in Windows Settings

"Node.js not found"

  • Download from nodejs.org (LTS version)
  • Install, then restart PowerShell
  • Verify: node --version (should show v18+ or v20+)

Advanced: Sync in Reverse (PC 2 → PC 1)

After editing code on PC 2, sync changes back to PC 1:

# On PC 2
robocopy "C:\CLAUDE CODE\workflows-n8n" "T:\workflows-n8n" /MIR /R:3
robocopy "C:\Users\$env:USERNAME\.claude\projects" "T:\memory" /MIR

Or use Settings Sync built into VS Code (Ctrl+Shift+P → "Settings Sync: Turn On").


Architecture Notes

Why SMB (not Dropbox/OneDrive)?

  • ✅ No cloud dependency → faster, more private
  • ✅ Works offline after initial sync
  • ✅ Secrets stay on local network
  • ✅ Zero cost, works on any Windows LAN

Why PowerShell Script (not Docker)?

  • ✅ Works on Windows without Linux VM
  • ✅ No admin rights required (after initial share setup)
  • ✅ Idempotent — safe to run multiple times
  • ✅ Easy to customize for your own setup

What About Conflicts?

  • T: is the source of truth — always sync TO PC 2 FROM PC 1
  • If you edit .env on PC 2, manually copy it back to T:\ before syncing again
  • Workflows (n8n) live in the cloud (Hostinger) — not synced locally

Extending the Setup

Add More Folders

Edit INSTALL.ps1 and add copy operations:

Copy-Item "T:\your-folder\*" "C:\CLAUDE CODE\your-folder\" -Force -Recurse

Sync from PC 2 Back to PC 1

Create a SYNC-BACK.ps1 on the secondary PC:

robocopy "C:\CLAUDE CODE\projects" "T:\projects" /MIR
robocopy "$env:USERPROFILE\.claude\projects" "T:\memory" /MIR

Automate Periodic Syncs

Use Task Scheduler to run SYNC-BACK.ps1 nightly:

  • Create a task
  • Trigger: "On a schedule" → Daily at 2 AM
  • Action: powershell.exe -File C:\path\to\SYNC-BACK.ps1

For Parents & Kids

Scenario: You want your kids to code alongside you, but with their own PC.

  1. Set up Primary PC (yours) with all your workflows, secrets, and SSH keys
  2. Give Secondary PC to kid(s) with everything pre-configured
  3. Teach from same codebase — you edit on your machine, they see it instantly
  4. Collaborative debugging — both working in the same project folder structure

Example workflow:

Dad (PC 1): Writes n8n workflow
  ↓ (SMB share)
  ↓ (INSTALL.ps1)
Kid (PC 2): Sees workflow, asks questions
  ↓ (Live pair coding)
Kid (PC 2): Modifies the workflow
  ↓ (Manual copy back to T:\)
Dad (PC 1): Reviews changes

For Pair Programming

Scenario: You and a colleague each have a laptop, and you want to work on the same codebase.

  1. Main developer shares their setup folder
  2. Colleague maps the network drive and runs the script
  3. Both have identical environments in 5 minutes
  4. Collaborate using VS Code's Live Share extension (optional)

Reporting Issues

Found a bug or want to add a feature?

  1. Fork this repo
  2. Create a branch: git checkout -b fix/your-issue
  3. Commit your changes
  4. Push and open a Pull Request

Common issues to report:

  • PowerShell execution problems on your Windows version
  • Firewall/antivirus blocking the script
  • Missing dependencies or incompatible tool versions
  • Network share not appearing in File Explorer

License

MIT License — use, modify, and share freely.


Credits

Built to solve the "I want my second PC to be identical to my first" problem without cloud storage, manual copying, or complex tooling.

Inspired by DevOps practices (Infrastructure as Code) applied to personal development setups.


Ready to sync? Map that network drive and run INSTALL.ps1. 🚀

About

Multi-PC dev environment sync. English fork of claude-code-family.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

 
 
 

Contributors