| 10475 | } |
| 10476 | |
| 10477 | static void uninstall_kimi_durable_context(const cbm_agent_registry_context_t *registry, |
| 10478 | bool dry_run) { |
| 10479 | const char *kimi_home = registry->options.kimi_code_home; |
| 10480 | char default_home[CLI_BUF_1K]; |
| 10481 | if (!kimi_home || !kimi_home[0]) { |
| 10482 | snprintf(default_home, sizeof(default_home), "%s/.kimi-code", registry->options.home_dir); |
| 10483 | kimi_home = default_home; |
| 10484 | } |
| 10485 | char instructions_path[CLI_BUF_1K]; |
| 10486 | char skills_dir[CLI_BUF_1K]; |
| 10487 | char config_path[CLI_BUF_1K]; |
| 10488 | snprintf(instructions_path, sizeof(instructions_path), "%s/AGENTS.md", kimi_home); |
| 10489 | snprintf(skills_dir, sizeof(skills_dir), "%s/skills", kimi_home); |
| 10490 | snprintf(config_path, sizeof(config_path), "%s/config.toml", kimi_home); |
| 10491 | if (!dry_run && cbm_remove_kimi_context_hook(config_path) != CLI_OK) { |
| 10492 | record_agent_config_error(true, "Kimi Code CLI", "prompt_hook_uninstall", config_path); |
| 10493 | } |
| 10494 | printf(" hook: removed managed UserPromptSubmit entry\n"); |
| 10495 | uninstall_managed_agent_instructions("Kimi Code CLI", instructions_path, dry_run); |
| 10496 | uninstall_agent_skill("Kimi Code CLI", skills_dir, dry_run); |
| 10497 | } |
| 10498 | |
| 10499 | static void uninstall_rovo_durable_context(const char *home, bool dry_run) { |
| 10500 | char instructions_path[CLI_BUF_1K]; |
no test coverage detected