diff --git a/scripts/enable-plugins.js b/scripts/enable-plugins.js index d537cbd..b0bad33 100644 --- a/scripts/enable-plugins.js +++ b/scripts/enable-plugins.js @@ -13,8 +13,13 @@ if (!settingsPath) { const MARKETPLACES = { caveman: { source: { source: "github", repo: "JuliusBrussee/caveman" } }, ponytail: { source: { source: "github", repo: "DietrichGebert/ponytail" } }, + "codebase-memory": { source: { source: "github", repo: "DeusData/codebase-memory-mcp" } }, +}; +const PLUGINS = { + "caveman@caveman": true, + "ponytail@ponytail": true, + "codebase-memory@codebase-memory": true, }; -const PLUGINS = { "caveman@caveman": true, "ponytail@ponytail": true }; const REMINDERS = ["kvb-dream", "kvb-coach"]; const RETIRED = [ "autotune/hooks/reminder.sh", @@ -119,4 +124,4 @@ for (const [script, event, matcher, sub] of SCRIPT_HOOKS) { } fs.writeFileSync(settingsPath, JSON.stringify(data, null, 2) + "\n"); -console.log(`skills: enabled caveman + ponytail plugins (their skill copies dropped from this .claude), the ${REMINDERS.join(" + ")} reminders, the kvb-org-organize claim gate, news hook and resource watch, and the kvb-org-perform log in ${settingsPath}`); +console.log(`skills: enabled the caveman, ponytail and codebase-memory plugins (plugin skill copies dropped from this .claude), the ${REMINDERS.join(" + ")} reminders, the kvb-org-organize claim gate, news hook and resource watch, and the kvb-org-perform log in ${settingsPath}`); diff --git a/scripts/install.sh b/scripts/install.sh index 3a758c7..ca40a67 100644 --- a/scripts/install.sh +++ b/scripts/install.sh @@ -64,6 +64,10 @@ if [[ "${TARGET}" == "${HOME}" ]]; then else warn "skills: no systemd user session; skipped the kvb-dream notification timer." fi + if ! command -v codebase-memory-mcp &>/dev/null && command -v yay &>/dev/null; then + log "skills: installing the codebase-memory-mcp code graph" + yay -S --needed codebase-memory-mcp-bin + fi if command -v codebase-memory-mcp &>/dev/null; then log "skills: auto-indexing every repository a session opens into the code graph" codebase-memory-mcp config set auto_index true diff --git a/skills/kvb-agent-optimize/SKILL.md b/skills/kvb-agent-optimize/SKILL.md index 1383e6b..e70eea7 100644 --- a/skills/kvb-agent-optimize/SKILL.md +++ b/skills/kvb-agent-optimize/SKILL.md @@ -22,15 +22,13 @@ installed, and the state of the shared snapshot ## Step 2: index -- **Binary missing**: installing registers an MCP server in the agent - configuration, so it is the operator's step; hand these to the - `kvb-org-operator` skill and continue after the restart: - - ```bash - yay -S codebase-memory-mcp-bin - claude plugin marketplace add DeusData/codebase-memory-mcp - claude plugin install codebase-memory@codebase-memory - ``` +- **Binary missing**: the skills repository's `make install` installs it + (`yay -S --needed codebase-memory-mcp-bin` where yay exists) and enables + the `codebase-memory@codebase-memory` plugin with its marketplace in the + settings. Installing touches the agent configuration and needs sudo, so it + is the operator's step: hand `make install` (or, without yay, the + package's install on that system) to the `kvb-org-operator` skill and + continue after the restart. - **Index**: once installed, the skills repository's `make install` switches `auto_index` on, so every repository a session opens is indexed and diff --git a/tests/test_dream.py b/tests/test_dream.py index 1887b1d..19dd39d 100644 --- a/tests/test_dream.py +++ b/tests/test_dream.py @@ -162,6 +162,13 @@ class TestSettingsRegistration(unittest.TestCase): self.assertEqual(gate.count("kvb-org-perform/scripts/log.py"), 1) self.assertEqual(post.count("kvb-org-perform/scripts/log.py"), 1) + def test_code_graph_plugin_is_enabled_with_its_marketplace(self): + data = self._patch() + self.assertTrue(data["enabledPlugins"]["codebase-memory@codebase-memory"]) + self.assertEqual( + data["extraKnownMarketplaces"]["codebase-memory"]["source"]["repo"], "DeusData/codebase-memory-mcp" + ) + def test_compact_window_is_set_once_and_never_overwritten(self): self.assertEqual(self._patch()["env"]["CLAUDE_CODE_AUTO_COMPACT_WINDOW"], "500000") self.settings.write_text(json.dumps({"env": {"CLAUDE_CODE_AUTO_COMPACT_WINDOW": "300000"}}), encoding="utf-8")