@71zone/ccm-core
v0.1.6
Published
Core library for Claude Code Extension Manager
Maintainers
Readme
CCM - Claude Code Extension Manager
A CLI tool to manage Claude Code configurations (agents, skills, commands, MCP) from multiple Git repositories.
Installation
npm install -g @71zone/ccmQuick Start
# Add a repository
ccm add https://github.com/anthropics/claude-skills
# Interactive picker - select what you want
ccm use anth
# Check what's linked
ccm statusCommands
ccm add <github-url>
Clone a repository and register it as a source.
$ ccm add https://github.com/acme/claude-toolkit
✓ Cloned to ~/.local/share/ccm/repos/acme
✓ Detected: 3a 5s 2c 1m
✓ Registered as "acme"ccm list (alias: ccm ls)
Show all registered repositories.
$ ccm list
acme github.com/acme/claude-toolkit 3a 5s 2c 1m
myco github.com/myco/dotclaude 1a 0s 4c 0mccm remove <alias> (alias: ccm rm)
Remove a repository and unlink all its assets.
$ ccm remove acme
Unlinked 4 assets. Removed repository.ccm update [alias]
Pull latest changes from registered repositories.
# Updates only repos with active selections
$ ccm update
# Updates all registered repos
$ ccm update -a
# Updates specific repo
$ ccm update acmeccm show <alias>
Display available assets in a repository.
$ ccm show acme
acme (acme/claude-toolkit)
├── agents/
│ ├── coder.md
│ └── reviewer.md
├── skills/
│ ├── coding/SKILL.md
│ └── debugging/SKILL.md
├── commands/
│ └── deploy.md
└── mcp/
└── github.jsonccm use [alias]
Interactive asset picker with grouped selection (select all by category). Without alias, prompts for repository selection first.
$ ccm use acme
◆ Select assets to link (space to toggle, enter to confirm)
│ ◻ agents (select all)
│ ◻ coder.md
│ ◻ reviewer.md
│ ◻ skills (select all)
│ ◻ coding
│ ◻ debugging
│ ◻ commands (select all)
│ ◻ deploy.md
✓ Linked acme-coder.md
✓ Linked acme-codingFor MCP configs, servers are selected individually:
◆ Select servers from mcp.json
│ ◻ servers (select all)
│ ◻ github
│ ◻ filesystem
│ ◻ postgres
✓ Staged MCP server: github
✓ Staged MCP server: filesystem
Run `ccm mcp sync` to apply staged MCP serversccm unuse [alias:path]
Interactive unlink picker. Without arguments, shows grouped selection of all linked assets.
# Interactive mode (default)
$ ccm unuse
◆ Select assets to unlink:
│ ◻ acme
│ ◻ agent/coder
│ ◻ skill/coding
│ ◻ myco
│ ◻ command/deploy
# Unlink specific asset
$ ccm unuse acme:agents/coder.md
# Unlink everything
$ ccm unuse --allccm status
Show currently linked assets.
$ ccm status
agents/
acme-coder.md ✓
myco-writer.md ✗ broken
skills/
acme-coding ✓
mcp/ (staged)
acme: github, filesystem
myco: postgres
Run `ccm doctor cure` to fix broken links
Run `ccm mcp sync` to apply staged MCP configsccm doctor
Check for issues.
$ ccm doctor
✗ Broken symlink: ~/.claude/agents/myco-writer.md
✗ Missing source: myco/agents/writer.md (deleted upstream?)
✓ 3 healthy link(s)
Run `ccm doctor cure` to auto-fixccm doctor cure
Auto-fix issues (remove broken symlinks, clean orphaned selections).
$ ccm doctor cure
✓ Fixed 2 broken link(s)ccm mcp show
Preview merged MCP configuration.
$ ccm mcp show
# Merged from: acme:github.json, myco:filesystem.json
{
"mcpServers": {
"github": { ... },
"filesystem": { ... }
}
}ccm mcp sync
Build and apply merged MCP config to ~/.claude/mcp.json.
$ ccm mcp sync
Preview:
+ github (from acme)
+ filesystem (from myco)
Apply to ~/.claude/mcp.json? [y/N] y
✓ AppliedFile Structure
~/.config/ccm/config.json # Registry & selection state
~/.local/share/ccm/repos/ # Cloned repositories
~/.claude/ # Output (symlinks)
├── agents/ # Agent symlinks
├── skills/ # Skill symlinks
├── commands/ # Command symlinks
└── mcp.json # Merged MCP configAsset Detection
Assets are detected by path patterns:
| Pattern | Type |
|---------|------|
| */agents/*.md | Agent |
| */skills/*/SKILL.md | Skill |
| */commands/*.md | Command |
| *mcp*.json with mcpServers key | MCP config |
Fallback: parse YAML frontmatter (tools/model fields = Agent).
Alias Generation
- Username ≤ 4 chars → use as-is
- Else → first 4 chars
- Collision → append number (acme, acme2)
How It Works
- Symlinks for live updates (edits in source repos propagate automatically)
git fetch && git reset --hard origin/<branch>for updates- Flat output structure with namespace prefix (e.g.,
acme-coder.md) - Per-server MCP staging - Individual MCP servers are staged (not whole files), then merged on
ccm mcp sync
Development
# Install dependencies
pnpm install
# Build all packages
pnpm build
# Run tests
pnpm test
# Development mode (watch)
pnpm devPackages
| Package | Description |
|---------|-------------|
| @71zone/ccm | CLI tool |
| @71zone/ccm-core | Core library (repo management, asset detection, linking) |
License
MIT
