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

Function install_qoder_durable_context

src/cli/cli.c:7848–7889  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

7846}
7847
7848static void install_qoder_durable_context(const char *home, const char *binary_path,
7849 const char *settings_path, bool config_resolved,
7850 bool force, bool dry_run) {
7851 char skills_dir[CLI_BUF_1K];
7852 char agent_path[CLI_BUF_1K];
7853 snprintf(skills_dir, sizeof(skills_dir), "%s/.qoder/skills", home);
7854 snprintf(agent_path, sizeof(agent_path), "%s/.qoder/agents/codebase-memory.md", home);
7855 install_agent_skill("Qoder CLI", skills_dir, force, dry_run);
7856 install_tiered_agent_profiles(
7857 (cbm_tiered_profile_set_t){
7858 .label = "Qoder CLI",
7859 .verify_path = agent_path,
7860 .binary_path = binary_path,
7861 .legacy_verify_content = legacy_qoder_verify_agent_content,
7862 .dialect = CBM_GRAPH_DIALECT_QODER,
7863 },
7864 dry_run);
7865 bool hook_supported = cbm_optional_hook_supported("qoder", cbm_current_platform_is_windows());
7866 if (g_install_plan) {
7867 if (hook_supported) {
7868 plan_record("Qoder CLI", "hook", settings_path);
7869 }
7870 return;
7871 }
7872 if (!hook_supported) {
7873 printf(" hooks: withheld because no documented executor is available\n");
7874 return;
7875 }
7876 if (!config_resolved) {
7877 printf(" hook: skipped because the settings path was unresolved\n");
7878 return;
7879 }
7880 bool installed = true;
7881 if (!dry_run && (!prepare_config_parent(settings_path) ||
7882 cbm_upsert_qoder_context_hook(settings_path, binary_path) != CLI_OK)) {
7883 installed = false;
7884 record_agent_config_error(false, "Qoder CLI", "context_hook_install", settings_path);
7885 }
7886 if (installed) {
7887 printf(" hooks: %s (SessionStart + SubagentStart + PostToolUse Read)\n", settings_path);
7888 }
7889}
7890
7891static bool cbm_gitlab_hooks_path(const cbm_agent_registry_context_t *registry, char *path,
7892 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