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

Function cbm_upsert_claude_hooks

src/cli/cli.c:2018–2029  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2016}
2017
2018int cbm_upsert_claude_hooks(const char *settings_path) {
2019 char command[CLI_BUF_1K];
2020 cbm_resolve_hook_command(CMM_HOOK_GATE_SCRIPT, command, sizeof(command));
2021 return upsert_hooks_json((hooks_upsert_args_t){
2022 .settings_path = settings_path,
2023 .hook_event = "PreToolUse",
2024 .matcher_str = CMM_HOOK_MATCHER,
2025 .command_str = command,
2026 .old_matchers = cmm_claude_old_matchers,
2027 .timeout_sec = CMM_HOOK_TIMEOUT_SEC,
2028 });
2029}
2030
2031int cbm_remove_claude_hooks(const char *settings_path) {
2032 return remove_hooks_json((hooks_remove_args_t){

Callers 3

test_cli.cFile · 0.85
repro_issue409.cFile · 0.85

Calls 2

cbm_resolve_hook_commandFunction · 0.85
upsert_hooks_jsonFunction · 0.85

Tested by

no test coverage detected