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

Function install_qoder_durable_context

src/cli/cli.c:8053–8094  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

8051}
8052
8053static void install_qoder_durable_context(const char *home, const char *binary_path,
8054 const char *settings_path, bool config_resolved,
8055 bool force, bool dry_run) {
8056 char skills_dir[CLI_BUF_1K];
8057 char agent_path[CLI_BUF_1K];
8058 snprintf(skills_dir, sizeof(skills_dir), "%s/.qoder/skills", home);
8059 snprintf(agent_path, sizeof(agent_path), "%s/.qoder/agents/codebase-memory.md", home);
8060 install_agent_skill("Qoder CLI", skills_dir, force, dry_run);
8061 install_tiered_agent_profiles(
8062 (cbm_tiered_profile_set_t){
8063 .label = "Qoder CLI",
8064 .verify_path = agent_path,
8065 .binary_path = binary_path,
8066 .legacy_verify_content = legacy_qoder_verify_agent_content,
8067 .dialect = CBM_GRAPH_DIALECT_QODER,
8068 },
8069 dry_run);
8070 bool hook_supported = cbm_optional_hook_supported("qoder", cbm_current_platform_is_windows());
8071 if (g_install_plan) {
8072 if (hook_supported) {
8073 plan_record("Qoder CLI", "hook", settings_path);
8074 }
8075 return;
8076 }
8077 if (!hook_supported) {
8078 printf(" hooks: withheld because no documented executor is available\n");
8079 return;
8080 }
8081 if (!config_resolved) {
8082 printf(" hook: skipped because the settings path was unresolved\n");
8083 return;
8084 }
8085 bool installed = true;
8086 if (!dry_run && (!prepare_config_parent(settings_path) ||
8087 cbm_upsert_qoder_context_hook(settings_path, binary_path) != CLI_OK)) {
8088 installed = false;
8089 record_agent_config_error(false, "Qoder CLI", "context_hook_install", settings_path);
8090 }
8091 if (installed) {
8092 printf(" hooks: %s (SessionStart + SubagentStart + PostToolUse Read)\n", settings_path);
8093 }
8094}
8095
8096static bool cbm_gitlab_hooks_path(const cbm_agent_registry_context_t *registry, char *path,
8097 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