| 7917 | } |
| 7918 | |
| 7919 | static void cbm_init_agent_registry_context(const char *home, |
| 7920 | cbm_agent_registry_context_t *registry) { |
| 7921 | memset(registry, 0, sizeof(*registry)); |
| 7922 | registry->options.home_dir = home; |
| 7923 | registry->options.xdg_config_home = cbm_agent_registry_env_path( |
| 7924 | "XDG_CONFIG_HOME", home, registry->xdg_config_home, sizeof(registry->xdg_config_home)); |
| 7925 | registry->options.appdata_dir = cbm_agent_registry_env_path( |
| 7926 | "APPDATA", home, registry->appdata_dir, sizeof(registry->appdata_dir)); |
| 7927 | registry->options.glab_config_dir = cbm_agent_registry_env_path( |
| 7928 | "GLAB_CONFIG_DIR", home, registry->glab_config_dir, sizeof(registry->glab_config_dir)); |
| 7929 | registry->options.kimi_code_home = cbm_agent_registry_env_path( |
| 7930 | "KIMI_CODE_HOME", home, registry->kimi_code_home, sizeof(registry->kimi_code_home)); |
| 7931 | registry->options.continue_config_path = cbm_agent_registry_env_path( |
| 7932 | "CBM_CONTINUE_CONFIG_PATH", home, registry->continue_config_path, |
| 7933 | sizeof(registry->continue_config_path)); |
| 7934 | registry->options.trae_config_path = |
| 7935 | cbm_agent_registry_env_path("CBM_TRAE_CONFIG_PATH", home, registry->trae_config_path, |
| 7936 | sizeof(registry->trae_config_path)); |
| 7937 | registry->options.roo_config_path = cbm_agent_registry_env_path( |
| 7938 | "CBM_ROO_CONFIG_PATH", home, registry->roo_config_path, sizeof(registry->roo_config_path)); |
| 7939 | registry->options.cody_config_path = |
| 7940 | cbm_agent_registry_env_path("CBM_CODY_CONFIG_PATH", home, registry->cody_config_path, |
| 7941 | sizeof(registry->cody_config_path)); |
| 7942 | #ifdef _WIN32 |
| 7943 | registry->options.is_windows = true; |
| 7944 | #else |
| 7945 | registry->options.is_windows = false; |
| 7946 | #endif |
| 7947 | registry->options.path_exists = cbm_agent_registry_path_exists; |
| 7948 | registry->options.command_exists = cbm_agent_registry_command_exists; |
| 7949 | registry->options.probe_context = registry; |
| 7950 | } |
| 7951 | |
| 7952 | static void print_detected_registry_agents(const char *home, bool *any) { |
| 7953 | cbm_agent_registry_context_t registry; |
no test coverage detected