# Claude Sync

> >

- **Type:** Skill
- **Install:** `agentstack add skill-samterces-claude-sync-claude-sync`
- **Verified:** Yes — security-reviewed for prompt injection and unsafe behavior
- **Seller:** [SamTerces](https://agentstack.voostack.com/s/samterces)
- **Installs:** 0
- **Category:** [Agent Skills](https://agentstack.voostack.com/c/agent-skills)
- **Latest version:** 0.1.0
- **License:** MIT
- **Upstream author:** [SamTerces](https://github.com/SamTerces)
- **Source:** https://github.com/SamTerces/claude-sync/tree/main/skills/claude-sync

## Install

```sh
agentstack add skill-samterces-claude-sync-claude-sync
```

Requires the [AgentStack CLI](https://agentstack.voostack.com/docs/cli). Works with Claude Code, Cursor, and any MCP-compatible agent.

## About

# claude-sync

Sync the user's Claude brain across machines and teammates. Read `skills/claude-sync/REFERENCE.md`
before running any command — it contains the full protocol for each operation including safety
rules, conflict resolution policy, and the secrets-scrubbing contract.

## What a "brain" contains

| Layer      | Path (global)             | Path (project)        |
|------------|---------------------------|-----------------------|
| Memory     | `~/.claude/memory/`       | `.claude/memory/`     |
| Skills     | `~/.claude/skills/`       | `.claude/skills/`     |
| Agents     | `~/.claude/agents/`       | `.claude/agents/`     |
| Rules      | `~/.claude/CLAUDE.md`     | `./CLAUDE.md`         |
| Settings   | `~/.claude/settings.json` | —                     |

Settings are scrubbed before sync. Only `permissions`, `hooks`, `theme`, and `model` travel.
API keys, tokens, and `.env` files **never** leave the machine.

## Determine intent, then act

Before running anything, identify which operation the user wants:

- **First time / new machine** → `init`
- **"push", "share", "upload my context"** → `push`
- **"pull", "get latest", "download team context"** → `pull`
- **"what changed", "diff", "compare"** → `diff`
- **"merge alice", "absorb bob's learnings"** → `merge `
- **"auto-sync", "watch", "sync automatically"** → `watch`
- **"status", "am I up to date"** → `status`

If intent is ambiguous, ask one clarifying question before proceeding.

## Running commands

All operations delegate to `skills/claude-sync/scripts/sync.sh`:

```bash
~/.claude/skills/claude-sync/scripts/sync.sh  [args]
```

If the script is not yet installed (first run on a machine), guide the user through
`init` first, which sets up the sync repo and installs the script.

## Output contract

Every operation must end with a structured summary. Use this exact format — fill in real values,
never placeholders:

```
┌─────────────────────────────────────────────┐
│  claude-sync —  complete         │
├─────────────────────────────────────────────┤
│  Memory files  :                         │
│  Skills        :                         │
│  Agents        :                         │
│  Branch        : brain/           │
│  Remote        :                      │
│  Timestamp     :                  │
└─────────────────────────────────────────────┘
```

## Before modifying anything

1. Show the user what will change (diff preview).
2. Ask for confirmation if the operation overwrites existing files.
3. Never silently delete or overwrite. Local data is authoritative unless the user explicitly
   says otherwise.

## Error handling

| Condition               | What to do                                                    |
|-------------------------|---------------------------------------------------------------|
| Remote unreachable      | Show the configured remote URL, suggest checking network      |
| `git` not installed     | Link to https://git-scm.com and stop                         |
| Merge conflict          | Show conflicting files, apply local-wins policy, explain why  |
| `jq` missing            | Warn that settings merge will be skipped, proceed without it  |
| Lock file exists        | Show the PID, explain how to remove `/tmp/claude-sync.lock`   |
| Empty remote            | Normal on first push — explain and continue                   |

## Reference documents

- `skills/claude-sync/REFERENCE.md` — full protocol specification
- `skills/claude-sync/EXAMPLES.md` — concrete walkthroughs
- `skills/claude-sync/references/merge-strategy.md` — how memory and skill merges work
- `skills/claude-sync/references/conflict-resolution.md` — conflict policy and edge cases
- `skills/claude-sync/references/security.md` — what gets scrubbed and why

## Source & license

This open-source skill is cataloged on AgentStack and links to its original source — we do not rehost the code.

- **Author:** [SamTerces](https://github.com/SamTerces)
- **Source:** [SamTerces/claude-sync](https://github.com/SamTerces/claude-sync)
- **License:** MIT

Install and usage instructions live in the source repository linked above.

## Pricing

- **Free** — Free

## Security capabilities

Automated source analysis of v0.1.0 — what this tool can access:

- **Network access:** no
- **Filesystem access:** no
- **Shell / process execution:** no
- **Environment & secrets:** yes
- **Dynamic code execution:** no

*"Yes" means the capability is present in the source — more access means more to trust, not that it is unsafe.*


## Versions

- **0.1.0** — security scan: passed — Imported from the upstream source.

## Links

- Listing page: https://agentstack.voostack.com/l/skill-samterces-claude-sync-claude-sync
- Seller: https://agentstack.voostack.com/s/samterces
- Browse the marketplace: https://agentstack.voostack.com/browse

---
Listed on AgentStack — the marketplace for AI agent skills and MCP servers. Every listing is security-reviewed. Creators keep 70%.
