@wipcomputer/wip-ldm-os 0.4.73-alpha.32 → 0.4.73-alpha.33
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/deploy.mjs +18 -2
- package/package.json +1 -1
package/lib/deploy.mjs
CHANGED
|
@@ -867,7 +867,6 @@ function registerMCP(repoPath, door, toolName) {
|
|
|
867
867
|
const envFlag = existsSync(OC_ROOT) ? ` -e OPENCLAW_HOME="${OC_ROOT}"` : '';
|
|
868
868
|
execSync(`claude mcp add --scope user ${name}${envFlag} -- node "${mcpPath}"`, { stdio: 'pipe' });
|
|
869
869
|
ok(`MCP: registered ${name} at user scope`);
|
|
870
|
-
return true;
|
|
871
870
|
} catch (e) {
|
|
872
871
|
// Fallback: write to ~/.claude.json directly
|
|
873
872
|
try {
|
|
@@ -879,12 +878,29 @@ function registerMCP(repoPath, door, toolName) {
|
|
|
879
878
|
};
|
|
880
879
|
writeJSON(ccUserPath, mcpConfig);
|
|
881
880
|
ok(`MCP: registered ${name} in ~/.claude.json (fallback)`);
|
|
882
|
-
return true;
|
|
883
881
|
} catch (e2) {
|
|
884
882
|
fail(`MCP: registration failed. ${e.message}`);
|
|
885
883
|
return false;
|
|
886
884
|
}
|
|
887
885
|
}
|
|
886
|
+
|
|
887
|
+
// Also register with OpenClaw so the MCP tools are available to all
|
|
888
|
+
// OpenClaw agents (e.g. Lēsa) without exec-approval gates. CC
|
|
889
|
+
// registration alone only gives tools to Claude Code sessions, not
|
|
890
|
+
// to OpenClaw's agent pipeline. Discovered 2026-04-11 when Lēsa
|
|
891
|
+
// lost xAI image gen tools after switching from Grok to Claude CLI.
|
|
892
|
+
try {
|
|
893
|
+
const ocMcpConfig = JSON.stringify({ command: 'node', args: [mcpPath] });
|
|
894
|
+
execSync(`openclaw mcp set ${name} '${ocMcpConfig}'`, { stdio: 'pipe' });
|
|
895
|
+
ok(`MCP: registered ${name} with OpenClaw`);
|
|
896
|
+
} catch {
|
|
897
|
+
// Non-fatal: OpenClaw may not be installed on all machines
|
|
898
|
+
}
|
|
899
|
+
|
|
900
|
+
// Add to OpenClaw tools.allow so the MCP tools are pre-authorized
|
|
901
|
+
updateToolsAllow(name);
|
|
902
|
+
|
|
903
|
+
return true;
|
|
888
904
|
}
|
|
889
905
|
|
|
890
906
|
/**
|