get-claudia 1.51.8 → 1.51.9
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/bin/index.js +23 -6
- package/package.json +1 -1
package/bin/index.js
CHANGED
|
@@ -469,7 +469,9 @@ async function main() {
|
|
|
469
469
|
console.log(` ${colors.green}✓${colors.reset} Framework updated (data preserved)`);
|
|
470
470
|
}
|
|
471
471
|
|
|
472
|
-
//
|
|
472
|
+
// Move legacy MCP servers (memory, Gmail, Calendar) to _disabled_mcpServers.
|
|
473
|
+
// Claude Code's native disable format: servers in _disabled_mcpServers are
|
|
474
|
+
// preserved but not launched. User can move them back to re-enable if needed.
|
|
473
475
|
disableLegacyMcpServers(targetPath);
|
|
474
476
|
|
|
475
477
|
// Write context/whats-new.md for Claudia's self-awareness (silent)
|
|
@@ -893,7 +895,12 @@ function disableLegacyMcpServers(targetPath) {
|
|
|
893
895
|
const config = JSON.parse(raw);
|
|
894
896
|
if (!config.mcpServers) return;
|
|
895
897
|
|
|
896
|
-
// Map of MCP server keys to their CLI replacement description
|
|
898
|
+
// Map of MCP server keys to their CLI replacement description.
|
|
899
|
+
// These servers are superseded by native CLI commands and should not
|
|
900
|
+
// be launched by Claude Code. We MOVE them from mcpServers into the
|
|
901
|
+
// _disabled_mcpServers top-level key, which is Claude Code's native
|
|
902
|
+
// disable format (used by the /mcp toggle UI). This preserves the
|
|
903
|
+
// full config so the user can move it back to re-enable if needed.
|
|
897
904
|
const legacyServers = {
|
|
898
905
|
'claudia-memory': 'claudia memory CLI',
|
|
899
906
|
'claudia_memory': 'claudia memory CLI',
|
|
@@ -907,9 +914,19 @@ function disableLegacyMcpServers(targetPath) {
|
|
|
907
914
|
const disabled = [];
|
|
908
915
|
|
|
909
916
|
for (const [key, replacement] of Object.entries(legacyServers)) {
|
|
910
|
-
if (config.mcpServers[key]
|
|
911
|
-
|
|
912
|
-
config.
|
|
917
|
+
if (config.mcpServers[key]) {
|
|
918
|
+
// Ensure _disabled_mcpServers exists as a top-level sibling
|
|
919
|
+
if (!config._disabled_mcpServers) config._disabled_mcpServers = {};
|
|
920
|
+
|
|
921
|
+
// Preserve full server config, strip our old _disabled flag if present
|
|
922
|
+
const serverConfig = { ...config.mcpServers[key] };
|
|
923
|
+
delete serverConfig._disabled;
|
|
924
|
+
delete serverConfig._replaced_by;
|
|
925
|
+
serverConfig._replaced_by = replacement;
|
|
926
|
+
config._disabled_mcpServers[key] = serverConfig;
|
|
927
|
+
|
|
928
|
+
// Remove from active servers so Claude Code won't launch it
|
|
929
|
+
delete config.mcpServers[key];
|
|
913
930
|
changed = true;
|
|
914
931
|
disabled.push(key);
|
|
915
932
|
}
|
|
@@ -917,7 +934,7 @@ function disableLegacyMcpServers(targetPath) {
|
|
|
917
934
|
|
|
918
935
|
if (changed) {
|
|
919
936
|
writeFileSync(mcpPath, JSON.stringify(config, null, 2) + '\n');
|
|
920
|
-
console.log(` ${colors.yellow}→${colors.reset} Disabled legacy MCP: ${disabled.join(', ')} (
|
|
937
|
+
console.log(` ${colors.yellow}→${colors.reset} Disabled legacy MCP: ${disabled.join(', ')} (moved to _disabled_mcpServers)`);
|
|
921
938
|
}
|
|
922
939
|
} catch {
|
|
923
940
|
// Not valid JSON or can't read -- skip silently
|