chore: remove legacy .kilocode migration helpers and update docs#9590
chore: remove legacy .kilocode migration helpers and update docs#9590Doondi-Ashlesh wants to merge 2 commits intoKilo-Org:mainfrom
Conversation
Post-GA cleanup tracked in Kilo-Org#6986. Code changes: - Remove migrateAgentManagerData, LEGACY_DIR, MigrationResult, and all helper functions from agent-manager/constants.ts - Remove ensureMigrated() method and migrated field from WorktreeManager.ts - Remove LEGACY_DIR fallback in readMetadata and legacy .kilocode entries from ensureGitExclude in WorktreeManager.ts - Remove migration call and git refresh logic from WorktreeStateManager.ts and AgentManagerProvider.ts; simplify load() return type to void - Remove stale .kilocode path rewrite from WorktreeStateManager.ts Docs changes: - Update .kilocode/ directory references to .kilo/ across skills, MCP, agent-manager, auto-launch, cloud-agent, analytics, and migration guides
Code Review SummaryStatus: 3 Issues Found | Recommendation: Address before merge Fix these issues in Kilo Cloud Overview
Issue Details (click to expand)WARNING
Other Observations (not in diff)Issues found in unchanged code that cannot receive inline comments:
Files Reviewed (14 files)
Reviewed by gpt-5.5-20260423 · 4,529,218 tokens |
…omepage - Update primary .kilo/rules/ path references in the VSCode (Legacy) tab of custom-rules.md (directory trees, step-by-step instructions, load order listing, and troubleshooting guide) - Update homepage terminal example from .kilocode/rules.md to .kilo/rules.md - Backward-compat callout notes (lines 64, 100, 210, 224) are left intact as they correctly document that .kilocode/rules/ still works
| <span className="terminal-comment"># Create a custom rules file in your project</span> | ||
| {"\n"} | ||
| <span className="terminal-prompt">$</span> touch .kilocode/rules.md | ||
| <span className="terminal-prompt">$</span> touch .kilo/rules.md |
There was a problem hiding this comment.
WARNING: Homepage example creates an unloaded rules file
Rules are discovered from .kilo/rules/*.md (or explicit instructions entries), so .kilo/rules.md at the config directory root will not be picked up. Users following this command won't actually create an active custom rule.
| <span className="terminal-prompt">$</span> touch .kilo/rules.md | |
| <span className="terminal-prompt">$</span> mkdir -p .kilo/rules && touch .kilo/rules/rules.md |
| @@ -510,13 +495,6 @@ export class WorktreeManager { | |||
| [".kilo/setup-script.ps1", "Kilo Code worktree setup script"], | |||
There was a problem hiding this comment.
WARNING: Stale unit tests still assert removed legacy WorktreeManager behavior
With the legacy .kilocode exclude entries and gitdir repair helper removed, packages/kilo-vscode/tests/unit/worktree-manager.test.ts:641 and packages/kilo-vscode/tests/unit/worktree-manager.test.ts:673 still assert behavior that no longer exists. The unit suite will fail unless those tests are updated or removed with this cleanup.
| return `${leadingSep}.kilo${trailingSep}` | ||
| }) ?? wt.path | ||
| this.worktrees.set(id, { id, ...wt, path: fixed }) | ||
| this.worktrees.set(id, { id, ...wt }) |
There was a problem hiding this comment.
WARNING: Stale unit tests still assert removed path rewriting
This now preserves the stored worktree path, but packages/kilo-vscode/tests/unit/worktree-state-manager.test.ts:539 and packages/kilo-vscode/tests/unit/worktree-state-manager.test.ts:561 still expect .kilocode paths to be rewritten to .kilo. The unit suite will fail unless those tests are updated or removed with this behavior change.
Post-GA cleanup tracked in #6986.
Code changes
migrateAgentManagerData,LEGACY_DIR,MigrationResult, and all helper functions fromagent-manager/constants.tsensureMigrated()method andmigratedfield fromWorktreeManager.tsLEGACY_DIRfallback inreadMetadataand legacy.kilocodeentries fromensureGitExcludeinWorktreeManager.tsWorktreeStateManager.tsandAgentManagerProvider.ts; simplifyload()return type tovoid.kilocodepath rewrite fromWorktreeStateManager.tsDocs changes
.kilocode/directory references to.kilo/across skills, MCP, agent-manager, auto-launch, cloud-agent, analytics, and migration guidesCloses #6986