From 15419d74c23ae76fd7d2e1c5059372f9d28a0276 Mon Sep 17 00:00:00 2001 From: YeonGyu-Kim Date: Tue, 30 Dec 2025 11:23:29 +0900 Subject: [PATCH] feat: wire skill tool to plugin with claude_code.skills toggle MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit - Export createSkillTool from src/tools/index.ts for public use - Import and instantiate skill tool in OhMyOpenCodePlugin with configuration - Use claude_code?.skills toggle to control inclusion of Claude Code paths - When skills toggle is false, only OpenCode-specific paths are included - Add skill to tools object and register with plugin for Claude Code compatibility - Respects existing plugin configuration patterns and integration style 🤖 GENERATED WITH ASSISTANCE OF [OhMyOpenCode](https://github.com/code-yeongyu/oh-my-opencode) --- src/index.ts | 6 +++++- src/tools/index.ts | 1 + 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/src/index.ts b/src/index.ts index 0e2ad51..f02721c 100644 --- a/src/index.ts +++ b/src/index.ts @@ -50,7 +50,7 @@ import { setMainSession, getMainSessionID, } from "./features/claude-code-session-state"; -import { builtinTools, createCallOmoAgent, createBackgroundTools, createLookAt, interactive_bash, getTmuxPath } from "./tools"; +import { builtinTools, createCallOmoAgent, createBackgroundTools, createLookAt, createSkillTool, interactive_bash, getTmuxPath } from "./tools"; import { BackgroundManager } from "./features/background-agent"; import { createBuiltinMcps } from "./mcp"; import { OhMyOpenCodeConfigSchema, type OhMyOpenCodeConfig, type HookName } from "./config"; @@ -322,6 +322,9 @@ const OhMyOpenCodePlugin: Plugin = async (ctx) => { const callOmoAgent = createCallOmoAgent(ctx, backgroundManager); const lookAt = createLookAt(ctx); + const skillTool = createSkillTool({ + opencodeOnly: pluginConfig.claude_code?.skills === false, + }); const googleAuthHooks = pluginConfig.google_auth !== false ? await createGoogleAntigravityAuthPlugin(ctx) @@ -337,6 +340,7 @@ const OhMyOpenCodePlugin: Plugin = async (ctx) => { ...backgroundTools, call_omo_agent: callOmoAgent, look_at: lookAt, + skill: skillTool, ...(tmuxAvailable ? { interactive_bash } : {}), }, diff --git a/src/tools/index.ts b/src/tools/index.ts index 283447b..9484473 100644 --- a/src/tools/index.ts +++ b/src/tools/index.ts @@ -29,6 +29,7 @@ import { } from "./session-manager" export { interactive_bash, startBackgroundCheck as startTmuxCheck } from "./interactive-bash" +export { createSkillTool } from "./skill" export { getTmuxPath } from "./interactive-bash/utils" import {