|
| 1 | +## High Level Reflections |
| 2 | + - Corey Doctorow's books have taught me that [[Interop]] tools like `rulesync` are important because in the age of AI, vendor lock-in is likely to become a serious issue. |
| 3 | + - When the pace of AI progress is so fast, the cost of using and maintaining an abstraction layer like `rulesync` is relatively high. It's relatively expensive for me to keep the canonical versions of my configurations in `rulesync`'s formats, because then I can't use the latest features of Claude Code, such as Skills (see also [Support for Claude Skills · Issue #422 · dyoshikawa/rulesync](https://github.com/dyoshikawa/rulesync/issues/422) ), and it's expensive to maintain because then external standards must be painstakingly adapted and mirrored into a centralized configuration. |
| 4 | + - In the past couple weeks, as Claude Code Skills emerged, I stopped using `rulesync`, because it wasn't supported yet. |
| 5 | + As a result, I have a high-level architectural suggestion. |
| 6 | + so I can't keep the current, best versions of my AI Code Configs in rulesync. |
| 7 | + |
| 8 | + As a result, I've been thinking more about how I can't |
| 9 | +- ## Precedent: Claude Code [Plugins](https://code.claude.com/docs/en/plugins-reference) |
| 10 | + |
| 11 | + Anthropic's Claude Code has the concept of , which enable registering a marketplace of plugins. |
| 12 | +- ## AI Marketplaces |
| 13 | + |
| 14 | + A repository is a "marketplace" which can contain multiple plugins, and each plugin can register commands, sub-agents, skills and hooks. Here are some example marketplaces: |
| 15 | + |
| 16 | + 1. [ehudhal/claude-code-marketplace](https://github.com/ehudhal/claude-code-marketplace) |
| 17 | + 2. [anthropics/skills](https://github.com/anthropics/skills) |
| 18 | + 3. [wshobson/agents](https://github.com/wshobson/agents) |
| 19 | + 4. [davila7/claude-code-templates: CLI tool for configuring and monitoring Claude Code](https://github.com/davila7/claude-code-templates) |
| 20 | + 5. See also github search using GitHub path: `**/.claude-plugin/marketplace.json` |
| 21 | +- ## Proposal: Rulesync could support its own marketplaces and plugins |
| 22 | +- ### Create [.rulesync/marketplace.jsonc](https://code.claude.com/docs/en/plugin-marketplaces#create-the-marketplace-file) |
| 23 | + |
| 24 | + ```json |
| 25 | + { |
| 26 | + "name": "company-tools", |
| 27 | + "owner": { |
| 28 | + "name": "DevTools Team", |
| 29 | + |
| 30 | + }, |
| 31 | + "plugins": [ |
| 32 | + { |
| 33 | + "name": "code-formatter", |
| 34 | + "source": "./plugins/formatter", |
| 35 | + "description": "Automatic code formatting on save", |
| 36 | + "version": "2.1.0", |
| 37 | + "author": { |
| 38 | + "name": "DevTools Team" |
| 39 | + } |
| 40 | + }, |
| 41 | + { |
| 42 | + "name": "deployment-tools", |
| 43 | + "source": { |
| 44 | + "source": "github", |
| 45 | + "repo": "company/deploy-plugin" |
| 46 | + }, |
| 47 | + "description": "Deployment automation tools" |
| 48 | + } |
| 49 | + ] |
| 50 | + } |
| 51 | + ``` |
| 52 | + |
| 53 | + Marketplaces support [expressing the location of their plugins sources in various ways](https://code.claude.com/docs/en/plugin-marketplaces#plugin-sources): |
| 54 | + |
| 55 | + Relative paths |
| 56 | + |
| 57 | + ```json |
| 58 | + { |
| 59 | + "name": "my-plugin", |
| 60 | + "source": "./plugins/my-plugin" |
| 61 | + } |
| 62 | + ``` |
| 63 | + |
| 64 | + Github repos |
| 65 | + |
| 66 | + ```json |
| 67 | + { |
| 68 | + "name": "github-plugin", |
| 69 | + "source": { |
| 70 | + "source": "github", |
| 71 | + "repo": "owner/plugin-repo" |
| 72 | + } |
| 73 | + } |
| 74 | + ``` |
| 75 | + |
| 76 | + etc |
| 77 | +- ### Create |
| 78 | + |
| 79 | + It's a simple spec. |
| 80 | + |
| 81 | + First, add a `.claude-plugin/plugin.json` like [claude-code/plugins/agent-sdk-dev/.claude-plugin/plugin.json at main · anthropics/claude-code](https://github.com/anthropics/claude-code/blob/main/plugins/agent-sdk-dev/.claude-plugin/plugin.json) (see also [the plugins.json spec](https://code.claude.com/docs/en/plugins-reference#complete-schema). |
| 82 | + |
| 83 | + For rulesync, it could be `.rulesync/plugin.jsonc`. |
| 84 | + |
| 85 | + Next, add folders `./agents/*.md`, `./skills/*.md`, `./commands/*.md`, `./hooks/*.md`, and `./.mcp.json`. |
| 86 | + |
| 87 | + So, based on [their sample directory structure](https://code.claude.com/docs/en/plugins-reference#standard-plugin-layout), |
| 88 | + |
| 89 | + ``` |
| 90 | + enterprise-plugin/ |
| 91 | + ├── .rulesync-plugin/ # Metadata directory |
| 92 | + │ └── plugin.json # Required: plugin manifest |
| 93 | + ├── commands/ # Default command location |
| 94 | + │ ├── status.md |
| 95 | + │ └── logs.md |
| 96 | + ├── subagents/ # Default agent location |
| 97 | + │ ├── security-reviewer.md |
| 98 | + │ ├── performance-tester.md |
| 99 | + │ └── compliance-checker.md |
| 100 | + ├── skills/ # Agent Skills |
| 101 | + │ ├── code-reviewer/ |
| 102 | + │ │ └── SKILL.md |
| 103 | + │ └── pdf-processor/ |
| 104 | + │ ├── SKILL.md |
| 105 | + │ └── scripts/ |
| 106 | + ├── hooks/ # Hook configurations |
| 107 | + │ ├── hooks.json # Main hook config |
| 108 | + │ └── security-hooks.json # Additional hooks |
| 109 | + ├── .mcp.json # MCP server definitions |
| 110 | + ├── scripts/ # Hook and utility scripts |
| 111 | + │ ├── security-scan.sh |
| 112 | + │ ├── format-code.py |
| 113 | + │ └── deploy.js |
| 114 | + ├── LICENSE # License file |
| 115 | + └── CHANGELOG.md # Version history |
| 116 | + ``` |
| 117 | + |
| 118 | + Furthermore |
| 119 | +- |
0 commit comments