Skip to content

Conversation

@ldclll
Copy link

@ldclll ldclll commented Nov 20, 2025

扩展Unity MCP,使其支持CodeBuddy代码编辑器。

Summary by CodeRabbit

  • New Features
    • Added CodeBuddy support as a new MCP client option in the MCPForUnity editor. The client is now available for Windows, macOS, and Linux, with configuration settings accessible at ~/.CodeBuddy/settings/mcp.json. Users can configure CodeBuddy integration through the editor's MCP configuration interface.

✏️ Tip: You can customize this high-level summary in your review settings.

@coderabbitai
Copy link
Contributor

coderabbitai bot commented Nov 20, 2025

Walkthrough

This PR extends the MCP client registry by adding CodeBuddy as a supported client type. A new enum member is introduced to McpTypes, and CodeBuddy configuration is registered with platform-specific paths to its settings file.

Changes

Cohort / File(s) Summary
CodeBuddy MCP client registration
MCPForUnity/Editor/Data/McpClients.cs
Added new MCP client entry for CodeBuddy with configuration paths set to ~/.CodeBuddy/settings/mcp.json across Windows, macOS, and Linux platforms; status initialized as "Not Configured".
Enum expansion
MCPForUnity/Editor/Models/McpTypes.cs
Added CodeBuddy enum member to the public McpTypes enum.

Estimated code review effort

🎯 2 (Simple) | ⏱️ ~8 minutes

  • Verify that the CodeBuddy configuration paths are correctly specified for all three platforms.
  • Confirm that the enum value is properly integrated and doesn't conflict with existing MCP type identifiers.

Poem

🐰 A CodeBuddy arrives at the door,
With paths through the config to explore,
An enum so new, a client so keen,
Joining the MCP machine,
Integration complete—let's settle the score! ✨

Pre-merge checks and finishing touches

✅ Passed checks (3 passed)
Check name Status Explanation
Description Check ✅ Passed Check skipped - CodeRabbit’s high-level summary is enabled.
Title check ✅ Passed The PR title is in Chinese and refers to extending CodeBuddy MCP, which directly matches the changeset that adds CodeBuddy MCP client configuration and enum support.
Docstring Coverage ✅ Passed No functions found in the changed files to evaluate docstring coverage. Skipping docstring coverage check.
✨ Finishing touches
  • 📝 Generate docstrings
🧪 Generate unit tests (beta)
  • Create PR with unit tests
  • Post copyable unit tests in a comment

Tip

📝 Customizable high-level summaries are now available in beta!

You can now customize how CodeRabbit generates the high-level summary in your pull requests — including its content, structure, tone, and formatting.

  • Provide your own instructions using the high_level_summary_instructions setting.
  • Format the summary however you like (bullet lists, tables, multi-section layouts, contributor stats, etc.).
  • Use high_level_summary_in_walkthrough to move the summary from the description to the walkthrough section.

Example instruction:

"Divide the high-level summary into five sections:

  1. 📝 Description — Summarize the main change in 50–60 words, explaining what was done.
  2. 📓 References — List relevant issues, discussions, documentation, or related PRs.
  3. 📦 Dependencies & Requirements — Mention any new/updated dependencies, environment variable changes, or configuration updates.
  4. 📊 Contributor Summary — Include a Markdown table showing contributions:
    | Contributor | Lines Added | Lines Removed | Files Changed |
  5. ✔️ Additional Notes — Add any extra reviewer context.
    Keep each section concise (under 200 words) and use bullet or numbered lists for clarity."

Note: This feature is currently in beta for Pro-tier users, and pricing will be announced later.


Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out.

❤️ Share

Comment @coderabbitai help to get the list of available commands and usage tips.

Copy link
Contributor

@coderabbitai coderabbitai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Actionable comments posted: 1

📜 Review details

Configuration used: CodeRabbit UI

Review profile: CHILL

Plan: Pro

📥 Commits

Reviewing files that changed from the base of the PR and between edd7817 and 124261a.

📒 Files selected for processing (2)
  • MCPForUnity/Editor/Data/McpClients.cs (1 hunks)
  • MCPForUnity/Editor/Models/McpTypes.cs (1 hunks)
🔇 Additional comments (1)
MCPForUnity/Editor/Models/McpTypes.cs (1)

13-13: LGTM! Enum addition follows the established pattern.

The CodeBuddy enum member is correctly added to support the new MCP client type.

Comment on lines +211 to +235
// CodeBuddy
new()
{
name = "CodeBuddy",
windowsConfigPath = Path.Combine(
Environment.GetFolderPath(Environment.SpecialFolder.UserProfile),
".CodeBuddy",
"settings",
"mcp.json"
),
macConfigPath = Path.Combine(
Environment.GetFolderPath(Environment.SpecialFolder.UserProfile),
".CodeBuddy",
"settings",
"mcp.json"
),
linuxConfigPath = Path.Combine(
Environment.GetFolderPath(Environment.SpecialFolder.UserProfile),
".CodeBuddy",
"settings",
"mcp.json"
),
mcpType = McpTypes.CodeBuddy,
configStatus = "Not Configured",
},
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

⚠️ Potential issue | 🔴 Critical

🧩 Analysis chain

LGTM! Configuration follows the established pattern.

The CodeBuddy client configuration is correctly structured and consistent with other MCP clients (particularly similar to the Kiro configuration).

However, please verify that .CodeBuddy (with capital C and B) is the correct directory name. Most other client configurations use lowercase directory names (.cursor, .kiro, .codex). If CodeBuddy's actual installation uses .codebuddy or a different casing, the paths should be updated accordingly.


🏁 Script executed:

#!/bin/bash
# Description: Check if there's any documentation or references to CodeBuddy's config directory name

# Search for any existing references to CodeBuddy paths in documentation or comments
rg -i "codebuddy" -g "*.md" -g "*.txt" -g "*.cs" -C3

Length of output: 2477


Update configuration directory to use lowercase path.

CodeBuddy uses ~/.codebuddy/settings.json (lowercase) as the user-level configuration path. The current implementation uses .CodeBuddy (mixed case), which will not match the actual directory name.

Update lines 211-235 in MCPForUnity/Editor/Data/McpClients.cs:

  • Change ".CodeBuddy" to ".codebuddy" in all three paths (Windows, Mac, Linux)
🤖 Prompt for AI Agents
MCPForUnity/Editor/Data/McpClients.cs around lines 211-235: the CodeBuddy config
paths use ".CodeBuddy" (mixed case) but the actual user directory is lowercase
".codebuddy"; update the three Path.Combine calls for windowsConfigPath,
macConfigPath and linuxConfigPath to use ".codebuddy" instead of ".CodeBuddy" so
the paths match the real config directory.

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