feat: Add OpenClaw as conversion target
Add openclaw as the 8th conversion target, enabling: bunx @every-env/compound-plugin install compound-engineering --to openclaw Converts Claude Code plugins into OpenClaw's extension format: - Agents → skills/agent-*/SKILL.md - Commands → api.registerCommand() + skills/cmd-*/SKILL.md - Skills → copied verbatim with path rewriting (.claude/ → .openclaw/) - MCP servers → openclaw.json config - Generates openclaw.plugin.json manifest, package.json, and index.ts entry point Output installs to ~/.openclaw/extensions/<plugin-name>/ Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
This commit is contained in:
52
src/types/openclaw.ts
Normal file
52
src/types/openclaw.ts
Normal file
@@ -0,0 +1,52 @@
|
||||
export type OpenClawPluginManifest = {
|
||||
id: string
|
||||
name: string
|
||||
kind: "tool"
|
||||
configSchema?: {
|
||||
type: "object"
|
||||
additionalProperties: boolean
|
||||
properties: Record<string, OpenClawConfigProperty>
|
||||
required?: string[]
|
||||
}
|
||||
uiHints?: Record<string, OpenClawUiHint>
|
||||
skills?: string[]
|
||||
}
|
||||
|
||||
export type OpenClawConfigProperty = {
|
||||
type: string
|
||||
description?: string
|
||||
default?: unknown
|
||||
}
|
||||
|
||||
export type OpenClawUiHint = {
|
||||
label: string
|
||||
sensitive?: boolean
|
||||
placeholder?: string
|
||||
}
|
||||
|
||||
export type OpenClawSkillFile = {
|
||||
name: string
|
||||
content: string
|
||||
/** Subdirectory path inside skills/ (e.g. "agent-native-reviewer") */
|
||||
dir: string
|
||||
}
|
||||
|
||||
export type OpenClawCommandRegistration = {
|
||||
name: string
|
||||
description: string
|
||||
acceptsArgs: boolean
|
||||
/** The prompt body that becomes the command handler response */
|
||||
body: string
|
||||
}
|
||||
|
||||
export type OpenClawBundle = {
|
||||
manifest: OpenClawPluginManifest
|
||||
packageJson: Record<string, unknown>
|
||||
entryPoint: string
|
||||
skills: OpenClawSkillFile[]
|
||||
/** Skill directories to copy verbatim (original Claude skills with references/) */
|
||||
skillDirCopies: { sourceDir: string; name: string }[]
|
||||
commands: OpenClawCommandRegistration[]
|
||||
/** openclaw.json fragment for MCP servers */
|
||||
openclawConfig?: Record<string, unknown>
|
||||
}
|
||||
Reference in New Issue
Block a user