MCPcopy Create free account
hub / github.com/DeusData/codebase-memory-mcp / install_qoder_durable_context

Function install_qoder_durable_context

src/cli/cli.c:9031–9072  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

9029}
9030
9031static void install_qoder_durable_context(const char *home, const char *binary_path,
9032 const char *settings_path, bool config_resolved,
9033 bool force, bool dry_run) {
9034 char skills_dir[CLI_BUF_1K];
9035 char agent_path[CLI_BUF_1K];
9036 snprintf(skills_dir, sizeof(skills_dir), "%s/.qoder/skills", home);
9037 snprintf(agent_path, sizeof(agent_path), "%s/.qoder/agents/codebase-memory.md", home);
9038 install_agent_skill("Qoder CLI", skills_dir, force, dry_run);
9039 install_tiered_agent_profiles(
9040 (cbm_tiered_profile_set_t){
9041 .label = "Qoder CLI",
9042 .verify_path = agent_path,
9043 .binary_path = binary_path,
9044 .legacy_verify_content = legacy_qoder_verify_agent_content,
9045 .dialect = CBM_GRAPH_DIALECT_QODER,
9046 },
9047 dry_run);
9048 bool hook_supported = cbm_optional_hook_supported("qoder", cbm_current_platform_is_windows());
9049 if (g_install_plan) {
9050 if (hook_supported) {
9051 plan_record("Qoder CLI", "hook", settings_path);
9052 }
9053 return;
9054 }
9055 if (!hook_supported) {
9056 printf(" hooks: withheld because no documented executor is available\n");
9057 return;
9058 }
9059 if (!config_resolved) {
9060 printf(" hook: skipped because the settings path was unresolved\n");
9061 return;
9062 }
9063 bool installed = true;
9064 if (!dry_run && (!prepare_config_parent(settings_path) ||
9065 cbm_upsert_qoder_context_hook(settings_path, binary_path) != CLI_OK)) {
9066 installed = false;
9067 record_agent_config_error(false, "Qoder CLI", "context_hook_install", settings_path);
9068 }
9069 if (installed) {
9070 printf(" hooks: %s (SessionStart + SubagentStart + PostToolUse Read)\n", settings_path);
9071 }
9072}
9073
9074static bool cbm_gitlab_hooks_path(const cbm_agent_registry_context_t *registry, char *path,
9075 size_t path_size) {

Callers 1

Calls 8

install_agent_skillFunction · 0.85
plan_recordFunction · 0.85
prepare_config_parentFunction · 0.85

Tested by

no test coverage detected