| 2603 | } |
| 2604 | |
| 2605 | static void cbm_copilot_config_dir(const char *home_dir, char *out, size_t out_sz) { |
| 2606 | char env_buf[CLI_BUF_1K]; |
| 2607 | const char *custom = cbm_safe_getenv("COPILOT_HOME", env_buf, sizeof(env_buf), NULL); |
| 2608 | snprintf(out, out_sz, "%s", custom && custom[0] ? custom : ""); |
| 2609 | if ((!custom || !custom[0]) && home_dir && home_dir[0]) { |
| 2610 | snprintf(out, out_sz, "%s/.copilot", home_dir); |
| 2611 | } |
| 2612 | } |
| 2613 | |
| 2614 | static void cbm_crush_config_path(const char *home_dir, char *out, size_t out_sz) { |
| 2615 | char env_buf[CLI_BUF_1K]; |
no test coverage detected