Plug.
Package manager for Claude Code skills
Sharing Claude Code extensions across a team without emailing Markdown files around.
$ git clone https://github.com/dsiddharth2/plug Discover, install, and manage reusable Skills, Commands, and Agents from GitHub-hosted registries — through an interactive TUI or the CLI.
Problem
- Claude Code extensions are Markdown files in a .claude/ folder
- That works for one person on one repo, not for a team
- Good commands spread by Slack paste and then drift
- Four projects end up with four slightly different copies
- No way to hand out shared security rules to every engineer
- No way to update those rules once they change
Solution
- Interactive TUI plus a /plug skill inside Claude Code
- Any GitHub repo is a package source — public or private
- Official vault: 14 packages, 7 always-on skills, 7 commands
- Install per project or per machine against a tracked manifest
- Vaults resolve in a user-defined order, first match wins
- Published on npm as plugvault, CI on every push
Outcome
- Teams share extensions without emailing Markdown around
- Private company vaults use existing GitHub access controls
- A reviewer reads the actual skill text in the pull request
- What lands in .claude/ is byte-identical to GitHub
- Update and remove operate on the manifest, not a directory scan
- MIT licensed and fully public
Architecture Review
How it works
-
Discover
The client pulls the index from every registered vault and caches it for an hour. The terminal UI is a full-screen browser with tabs for what is available, what is installed, and which vaults are configured.
-
Resolve
A requested name is matched against the merged index in vault order. First match wins, so an internal vault can shadow a public package of the same name. A vault-qualified form exists when you need to be explicit.
-
Install
Files are fetched and written where Claude actually reads them: a skill at .claude/skills/<name>/SKILL.md, a command at .claude/commands/<name>.md, under the project or ~/.claude/ depending on scope.
-
Track
The manifest records package name, version, and which vault it came from. Update, remove, and list operate on that record, not the directory listing, so multi-file packages and hand-written files stay distinct.
-
Publish
Adding a package means creating a folder with meta.json and an entry file, adding one index row, and opening a pull request. Every package in the official vault went in through that path.
Key Decisions
-
GitHub repositories are the registry. There is no package server.
A registry is a JSON index committed to a repo. A hosted API would have needed its own accounts and something to keep running. Using repos means private distribution comes free from GitHub access controls. What I gave up: no download counts, no central moderation, no way to yank a bad package.
-
A package is a folder you can read in a pull request
Each package is registry/<name>/ holding meta.json and a Markdown entry file. Inlining into one large manifest would have been simpler to fetch and horrible to review. The file that lands in .claude/ is byte-identical to the one on GitHub.
-
Two clients, one contract
The terminal UI is Node and Ink. The Claude Code skill runs inside the conversation with no Node runtime at all. Both perform resolve, fetch, write, record in the same order, which is the only reason it is safe to have two of them.
-
Vaults resolve in a user-defined order, first match wins
An organisation registers its internal vault ahead of the public one, and its version of a package shadows the community version by the same name. Unqualified installs can silently resolve somewhere you did not expect.
-
The manifest is the source of truth, not the file tree
Scanning .claude/ and inferring what is installed falls apart the moment a package spans more than one file, and it cannot tell a Plug-managed file from one you wrote yourself. The trade-off is drift: hand-edit the folder and the manifest is quietly wrong.
Evaluation
There's no evaluation harness yet, and that's the honest gap. CI unit tests catch regressions in resolution and path routing, but they don't test whether a package installs correctly from a fresh machine, into both scopes, and whether removing it leaves nothing behind. Dogfooding covers the common path. Private vault authentication, multi-file packages, and removal with dependents are verified by hand. An install matrix in a clean container per case would replace all of that manual checking.
What I'd Change
- Version the registry format from the first commit The index schema has changed as the tool grew and there is no version field, so an older client hitting a newer vault fails confusingly. One integer at the top of the file, added on day one, costs nothing.
- Pin content to a commit, not a branch Packages are fetched from the default branch. What you installed on Monday and what a colleague installs on Friday can silently differ. Recording the commit SHA in the manifest belonged in the first version of the install path.
- Generate the index instead of maintaining it by hand Every package already has meta.json, and then it has to be copied into the root index by hand. Two places, one truth — walking the registry folder in CI and writing the index out would remove the step people forget.
- Keep the docs generated from one source The README and the architecture doc drifted apart on how installation handles dependencies, and CLI flags in the vault README don't match the tool's. Anything a reader can check against the code should come from the code.