| 8132 | } |
| 8133 | |
| 8134 | static void cbm_init_agent_registry_context(const char *home, |
| 8135 | cbm_agent_registry_context_t *registry) { |
| 8136 | memset(registry, 0, sizeof(*registry)); |
| 8137 | registry->options.home_dir = home; |
| 8138 | registry->options.xdg_config_home = cbm_agent_registry_env_path( |
| 8139 | "XDG_CONFIG_HOME", home, registry->xdg_config_home, sizeof(registry->xdg_config_home)); |
| 8140 | registry->options.appdata_dir = cbm_agent_registry_env_path( |
| 8141 | "APPDATA", home, registry->appdata_dir, sizeof(registry->appdata_dir)); |
| 8142 | registry->options.glab_config_dir = cbm_agent_registry_env_path( |
| 8143 | "GLAB_CONFIG_DIR", home, registry->glab_config_dir, sizeof(registry->glab_config_dir)); |
| 8144 | registry->options.kimi_code_home = cbm_agent_registry_env_path( |
| 8145 | "KIMI_CODE_HOME", home, registry->kimi_code_home, sizeof(registry->kimi_code_home)); |
| 8146 | registry->options.continue_config_path = cbm_agent_registry_env_path( |
| 8147 | "CBM_CONTINUE_CONFIG_PATH", home, registry->continue_config_path, |
| 8148 | sizeof(registry->continue_config_path)); |
| 8149 | registry->options.trae_config_path = |
| 8150 | cbm_agent_registry_env_path("CBM_TRAE_CONFIG_PATH", home, registry->trae_config_path, |
| 8151 | sizeof(registry->trae_config_path)); |
| 8152 | registry->options.roo_config_path = cbm_agent_registry_env_path( |
| 8153 | "CBM_ROO_CONFIG_PATH", home, registry->roo_config_path, sizeof(registry->roo_config_path)); |
| 8154 | registry->options.cody_config_path = |
| 8155 | cbm_agent_registry_env_path("CBM_CODY_CONFIG_PATH", home, registry->cody_config_path, |
| 8156 | sizeof(registry->cody_config_path)); |
| 8157 | #ifdef _WIN32 |
| 8158 | registry->options.is_windows = true; |
| 8159 | #else |
| 8160 | registry->options.is_windows = false; |
| 8161 | #endif |
| 8162 | registry->options.path_exists = cbm_agent_registry_path_exists; |
| 8163 | registry->options.command_exists = cbm_agent_registry_command_exists; |
| 8164 | registry->options.probe_context = registry; |
| 8165 | } |
| 8166 | |
| 8167 | static void print_detected_registry_agents(const char *home, bool *any) { |
| 8168 | cbm_agent_registry_context_t registry; |
no test coverage detected