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

Function install_qoder_durable_context

src/cli/cli.c:7904–7945  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7902}
7903
7904static void install_qoder_durable_context(const char *home, const char *binary_path,
7905 const char *settings_path, bool config_resolved,
7906 bool force, bool dry_run) {
7907 char skills_dir[CLI_BUF_1K];
7908 char agent_path[CLI_BUF_1K];
7909 snprintf(skills_dir, sizeof(skills_dir), "%s/.qoder/skills", home);
7910 snprintf(agent_path, sizeof(agent_path), "%s/.qoder/agents/codebase-memory.md", home);
7911 install_agent_skill("Qoder CLI", skills_dir, force, dry_run);
7912 install_tiered_agent_profiles(
7913 (cbm_tiered_profile_set_t){
7914 .label = "Qoder CLI",
7915 .verify_path = agent_path,
7916 .binary_path = binary_path,
7917 .legacy_verify_content = legacy_qoder_verify_agent_content,
7918 .dialect = CBM_GRAPH_DIALECT_QODER,
7919 },
7920 dry_run);
7921 bool hook_supported = cbm_optional_hook_supported("qoder", cbm_current_platform_is_windows());
7922 if (g_install_plan) {
7923 if (hook_supported) {
7924 plan_record("Qoder CLI", "hook", settings_path);
7925 }
7926 return;
7927 }
7928 if (!hook_supported) {
7929 printf(" hooks: withheld because no documented executor is available\n");
7930 return;
7931 }
7932 if (!config_resolved) {
7933 printf(" hook: skipped because the settings path was unresolved\n");
7934 return;
7935 }
7936 bool installed = true;
7937 if (!dry_run && (!prepare_config_parent(settings_path) ||
7938 cbm_upsert_qoder_context_hook(settings_path, binary_path) != CLI_OK)) {
7939 installed = false;
7940 record_agent_config_error(false, "Qoder CLI", "context_hook_install", settings_path);
7941 }
7942 if (installed) {
7943 printf(" hooks: %s (SessionStart + SubagentStart + PostToolUse Read)\n", settings_path);
7944 }
7945}
7946
7947static bool cbm_gitlab_hooks_path(const cbm_agent_registry_context_t *registry, char *path,
7948 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