clew
Declarative Claude Code configuration management - like Brewfile for Homebrew, but for Claude Code plugins and marketplaces.
Power your agent
Install from the publisher. Not a PlugMCP endpoint.
Host a copy with our keys and logs.
No packaged release in the registry yet. Follow the repository README.
Remote URL or a command on your machine? How the two installs differ
Run on PlugMCP
A new server you create. It is not this listing's official endpoint. Use the publisher install when you want their URL and their credentials.
LaunchWhen syncing Claude Code config across workstations with yadm (or similar):
installed_plugins.json references paths that don't exist on other machinesDeclare your desired configuration in a Clewfile, sync that across machines, run clew sync.
# ~/.config/claude/Clewfile
# yaml-language-server: $schema=https://raw.githubusercontent.com/adamancini/clew/main/schema/clewfile.schema.json
---
version: 1
marketplaces:
claude-plugins-official:
source: github
repo: anthropics/claude-plugins-official
plugins:
- context7@claude-plugins-official
- superpowers@superpowers-marketplace
- name: linear@claude-plugins-official
enabled: false
go install github.com/adamancini/clew@latest
Or download a release binary:
curl -L https://github.com/adamancini/clew/releases/latest/download/clew-$(uname -s)-$(uname -m) \
-o ~/.local/bin/clew && chmod +x ~/.local/bin/clew
Once installed, you can keep clew up to date with clew version --update.
Clew can update itself to the latest version:
# Check for updates
clew version --check
# Install the latest version
clew version --update
The update process:
Supported platforms: macOS (Intel/Apple Silicon), Linux (amd64/arm64)
Environment variables:
GITHUB_TOKEN - Optional, prevents API rate limitingSecurity:
# Export your current Claude Code setup to a Clewfile
clew export > ~/.claude/Clewfile.yaml
# Sync another machine to match your Clewfile
clew sync
# Check what would change before syncing
clew diff
# Export current state to Clewfile
clew export > ~/.claude/Clewfile.yaml
# Sync system to match Clewfile
clew sync
# Show what would change (dry-run)
clew diff
# Check status
clew status
# Check for clew updates
clew version --check
# Update clew to latest version
clew version --update
Option 1: Export from existing setup (recommended)
clew export > ~/.claude/Clewfile.yaml
Option 2: Write manually
version: 1
marketplaces:
claude-plugins-official:
source: github
repo: anthropics/claude-plugins-official
plugins:
- context7@claude-plugins-official
- episodic-memory@claude-plugins-official
Use --interactive or -i to review and approve each change individually:
# Interactive sync - approve each change before applying
clew sync --interactive
clew sync -i
# Interactive diff - preview changes with prompts (dry-run)
clew diff --interactive
Interactive mode prompts for each marketplace and plugin change:
$ clew sync --interactive
Marketplaces:
+ private-marketplace (will add)
-> Add private-marketplace from github:you/plugins? [y/n/a/q] y
Plugins:
+ pr-review-toolkit@claude-plugins-official (will add)
-> Add pr-review-toolkit@claude-plugins-official? [y/n/a/q] y
- linear@claude-plugins-official (will disable)
-> Disable linear@claude-plugins-official? [y/n/a/q] n
- Skipped
Summary:
Will apply: 2 changes
Skipped: 1
Proceed with sync? [y/n] y
Installed: 2
Prompt options:
y - Yes, approve this changen - No, skip this changea - All, approve all remaining changesq - Quit, abort interactive modeNon-TTY fallback: When not running in a terminal (e.g., in scripts or CI), interactive mode automatically falls back to non-interactive mode with a warning.
By default, sync shows verbose output with commands and descriptions:
$ clew sync
Add: Installing plugin context7
> claude plugin install context7@claude-plugins-official
* Success
Enable: Enabling plugin linear
> claude plugin enable linear@claude-plugins-official
* Success
Summary:
Installed: 1
Updated: 1
Failed: 0
Use --short for concise one-line-per-item output:
$ clew sync --short
* context7 (plugin add)
* linear (plugin enable)
Summary: 1 installed, 1 updated
The short format is ideal for scripts and CI pipelines where you want minimal output.
clew can backup your Claude Code configuration before making changes, allowing easy rollback if something goes wrong.
# Create a backup
clew backup create
clew backup create --note "Before plugin update"
# List all backups
clew backup list
clew backup list -o json
# Restore from a backup
clew backup restore <id>
clew backup restore latest
# Delete a specific backup
clew backup delete <id>
# Remove old backups (keep last N)
clew backup prune --keep=10
By default, clew sync creates a backup before making changes:
# Default behavior - backup created automatically
clew sync
# Explicitly request backup
clew sync --backup
# Skip backup creation
clew sync --no-backup
Backups are stored in ~/.cache/clew/backups/ as JSON files named with timestamps (e.g., 2024-01-08-143022.json).
Each backup contains:
-o, --output <format> # Output: text (default), json, yaml
-i, --interactive # Interactive mode (sync/diff only)
--config <path> # Explicit Clewfile path
--strict # Exit non-zero on any failure (sync only)
--short # One-line per item output (sync only)
--verbose # Detailed output
--quiet # Errors only
clew supports shell completion for bash, zsh, and fish.
Bash:
# Linux (system-wide)
clew completion bash | sudo tee /etc/bash_completion.d/clew > /dev/null
# macOS (Homebrew)
clew completion bash > $(brew --prefix)/etc/bash_completion.d/clew
# Load in current session
source <(clew completion bash)
Zsh:
# Oh My Zsh
mkdir -p ~/.oh-my-zsh/completions
clew completion zsh > ~/.oh-my-zsh/completions/_clew
# Standard zsh (add to fpath)
clew completion zsh > /usr/local/share/zsh/site-functions/_clew
# Load in current session
source <(clew completion zsh)
Fish:
clew completion fish > ~/.config/fish/completions/clew.fish
After installation, restart your shell or source the completion script.
clew searches (first found wins):
--config flag or CLEWFILE env var$XDG_CONFIG_HOME/claude/Clewfile[.yaml|.toml|.json]~/.claude/Clewfile[.yaml|.toml|.json]~/.Clewfile[.yaml|.toml|.json]Supports YAML, TOML, and JSON formats (auto-detected by extension).
clew includes a JSON Schema for Clewfile validation and auto-completion:
YAML files - Add schema reference at the top:
# yaml-language-server: $schema=https://raw.githubusercontent.com/adamancini/clew/main/schema/clewfile.schema.json
---
version: 1
JSON files - Add $schema property:
{
"$schema": "https://raw.githubusercontent.com/adamancini/clew/main/schema/clewfile.schema.json",
"version": 1
}
See schema/README.md for IDE setup details and examples.
See docs/design.md for full architecture and specification.
All pull requests to main require a version bump. Before creating a PR:
.claude-plugin/plugin.jsonCHANGELOG.md with new version and changesSee .github/WORKFLOWS.md for detailed workflow documentation.
MIT
Declarative Claude Code configuration management - like Brewfile for Claude Code plugins, marketplaces, and MCP servers
Tools
No tool list yet. Remote servers get one after the first health check.
FAQ
Copy the stdio config for Cursor, Claude Desktop, Claude Code, or VS Code on this page. It uses the publisher's install, not a PlugMCP proxy.
No required environment variable is listed on this record.
Clew runs locally over stdio.
Last checked 2026-10-27. Declarative Claude Code configuration management - like Brewfile for Claude Code plugins, marketplaces, and MCP servers