Skip to content

feat(claude): support --plugin-dir via CLAUDE_PLUGIN_DIR#251

Open
jordane95 wants to merge 1 commit into
xvirobotics:mainfrom
jordane95:feat/claude-plugin-dir
Open

feat(claude): support --plugin-dir via CLAUDE_PLUGIN_DIR#251
jordane95 wants to merge 1 commit into
xvirobotics:mainfrom
jordane95:feat/claude-plugin-dir

Conversation

@jordane95

Copy link
Copy Markdown

Summary

  • Pass a configurable plugin directory to the Claude Code CLI via the SDK's extraArgs (--plugin-dir), so bots can load custom plugins without touching the user's global Claude config.
  • New config field claude.pluginDir (per-bot) and CLAUDE_PLUGIN_DIR env var fallback. Wired through buildClaudeConfig and all three env-var bot constructors (Feishu, Telegram, WeChat).
  • Applied in src/engines/claude/executor.ts when building queryOptions.

Test plan

  • Set CLAUDE_PLUGIN_DIR=/some/plugin/dir and confirm the spawned claude subprocess receives --plugin-dir /some/plugin/dir.
  • Set pluginDir in a bot's JSON entry and confirm the per-bot value wins over the env var.
  • Bots without pluginDir configured behave exactly as before (no extraArgs added).
  • npm run build and npm test pass.

🤖 Generated with Claude Code

Passes a configurable plugin directory to the Claude Code CLI via the
SDK's extraArgs so bots can load custom plugins without modifying the
user's global Claude config.

Co-Authored-By: Claude Opus 4.7 <noreply@anthropic.com>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant