| 7830 | } |
| 7831 | |
| 7832 | static void cbm_init_agent_registry_context(const char *home, |
| 7833 | cbm_agent_registry_context_t *registry) { |
| 7834 | memset(registry, 0, sizeof(*registry)); |
| 7835 | registry->options.home_dir = home; |
| 7836 | registry->options.xdg_config_home = cbm_agent_registry_env_path( |
| 7837 | "XDG_CONFIG_HOME", home, registry->xdg_config_home, sizeof(registry->xdg_config_home)); |
| 7838 | registry->options.appdata_dir = cbm_agent_registry_env_path( |
| 7839 | "APPDATA", home, registry->appdata_dir, sizeof(registry->appdata_dir)); |
| 7840 | registry->options.glab_config_dir = cbm_agent_registry_env_path( |
| 7841 | "GLAB_CONFIG_DIR", home, registry->glab_config_dir, sizeof(registry->glab_config_dir)); |
| 7842 | registry->options.kimi_code_home = cbm_agent_registry_env_path( |
| 7843 | "KIMI_CODE_HOME", home, registry->kimi_code_home, sizeof(registry->kimi_code_home)); |
| 7844 | registry->options.continue_config_path = cbm_agent_registry_env_path( |
| 7845 | "CBM_CONTINUE_CONFIG_PATH", home, registry->continue_config_path, |
| 7846 | sizeof(registry->continue_config_path)); |
| 7847 | registry->options.trae_config_path = |
| 7848 | cbm_agent_registry_env_path("CBM_TRAE_CONFIG_PATH", home, registry->trae_config_path, |
| 7849 | sizeof(registry->trae_config_path)); |
| 7850 | registry->options.roo_config_path = cbm_agent_registry_env_path( |
| 7851 | "CBM_ROO_CONFIG_PATH", home, registry->roo_config_path, sizeof(registry->roo_config_path)); |
| 7852 | registry->options.cody_config_path = |
| 7853 | cbm_agent_registry_env_path("CBM_CODY_CONFIG_PATH", home, registry->cody_config_path, |
| 7854 | sizeof(registry->cody_config_path)); |
| 7855 | #ifdef _WIN32 |
| 7856 | registry->options.is_windows = true; |
| 7857 | #else |
| 7858 | registry->options.is_windows = false; |
| 7859 | #endif |
| 7860 | registry->options.path_exists = cbm_agent_registry_path_exists; |
| 7861 | registry->options.command_exists = cbm_agent_registry_command_exists; |
| 7862 | registry->options.probe_context = registry; |
| 7863 | } |
| 7864 | |
| 7865 | static void print_detected_registry_agents(const char *home, bool *any) { |
| 7866 | cbm_agent_registry_context_t registry; |
no test coverage detected