fix: add globalRuleFile for Kilo Code platform for rules scanning - #158
Conversation
- platforms.ts: 为 kilo 平台添加 globalRuleFile: "rules/global.md" - rules.ts: 添加 kilo-global 到 KNOWN_RULE_FILE_TEMPLATES 和 RULE_PLATFORM_ORDER Kilo Code 从 ~/.kilo/rules/ 目录读取所有 .md 文件作为全局规则, 选择 rules/global.md 作为 globalRuleFile 使得 PromptHub 管理的单文件 能被 Kilo Code 自动发现和加载。
|
@chung1912 is attempting to deploy a commit to the legeling's projects Team on Vercel. A member of the Team first needs to authorize it. |
Qodo reviews are paused for this user.Troubleshooting steps vary by plan Learn more → On a Teams plan? Using GitHub Enterprise Server, GitLab Self-Managed, or Bitbucket Data Center? |
|
No actionable comments were generated in the recent review. 🎉 ℹ️ Recent review info⚙️ Run configurationConfiguration used: Organization UI Review profile: CHILL Plan: Pro Run ID: 📒 Files selected for processing (2)
📝 Walkthrough总览此更改为 Kilo Code 平台增加全局规则文件支持。在 变更内容Kilo 平台全局规则支持
🎯 1 (Trivial) | ⏱️ ~5 minutes
🚥 Pre-merge checks | ✅ 5✅ Passed checks (5 passed)
✏️ Tip: You can configure your own custom pre-merge checks in the settings. ✨ Finishing Touches🧪 Generate unit tests (beta)
Warning There were issues while running some tools. Please review the errors and either fix the tool's configuration or disable the tool if it's a critical failure. 🔧 ESLint
ESLint skipped: no ESLint configuration detected in root package.json. To enable, add 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. Comment |
|
Actionable comments posted: 0 |
问题
Kilo Code 平台在 PromptHub 的 Rules 工作区中无法扫描到全局规则,
data/rules/global/kilo/目录也不会被创建。根因
Kilo Code 在
platforms.ts中只有skillsRelativePath: "skills"(用于 Skill 安装),缺少globalRuleFile属性。因此:getPlatformGlobalRulePath()返回null→ Rules 工作区跳过 Kilo CodeKNOWN_RULE_FILE_TEMPLATES中没有"kilo-global"条目 → 不创建规则目录RULE_PLATFORM_ORDER中没有"kilo"→ 侧边栏不显示 Kilo Code修复
platforms.ts: 为 Kilo Code 添加globalRuleFile: "rules/global.md"rules.ts: 添加"kilo"到RULE_PLATFORM_ORDER,添加"kilo-global"到KNOWN_RULE_FILE_TEMPLATES为什么选择
rules/global.mdKilo Code 从
~/.kilo/rules/目录读取所有.md文件作为全局规则(目录模型)。PromptHub 的 Rules 工作区目前只支持单文件模型。选择rules/global.md作为globalRuleFile是最合理的折中:~/.kilo/rules/global.md这一个文件~/.kilo/rules/下的所有.md文件global.md描述性强,不会与其他规则文件冲突测试
pnpm typecheck✅pnpm lint✅Summary by CodeRabbit
发布说明