aidex-mcp 1.5.0 → 1.5.1
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/CHANGELOG.md +5 -0
- package/build/commands/setup.js +27 -13
- package/package.json +1 -1
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,11 @@
|
|
|
2
2
|
|
|
3
3
|
All notable changes to AiDex will be documented in this file.
|
|
4
4
|
|
|
5
|
+
## [1.5.1] - 2026-01-31
|
|
6
|
+
|
|
7
|
+
### Fixed
|
|
8
|
+
- **`aidex setup`**: Now creates config file if client directory exists but config is missing (e.g. fresh Claude Code install)
|
|
9
|
+
|
|
5
10
|
## [1.5.0] - 2026-01-31
|
|
6
11
|
|
|
7
12
|
### Added
|
package/build/commands/setup.js
CHANGED
|
@@ -23,37 +23,43 @@ function getClients() {
|
|
|
23
23
|
// Claude Code
|
|
24
24
|
clients.push({
|
|
25
25
|
name: 'Claude Code',
|
|
26
|
-
configPath: join(home, '.claude', 'settings.json')
|
|
26
|
+
configPath: join(home, '.claude', 'settings.json'),
|
|
27
|
+
detectDir: join(home, '.claude')
|
|
27
28
|
});
|
|
28
29
|
// Claude Desktop
|
|
29
30
|
if (plat === 'win32') {
|
|
30
31
|
const appData = process.env.APPDATA || join(home, 'AppData', 'Roaming');
|
|
31
32
|
clients.push({
|
|
32
33
|
name: 'Claude Desktop',
|
|
33
|
-
configPath: join(appData, 'Claude', 'claude_desktop_config.json')
|
|
34
|
+
configPath: join(appData, 'Claude', 'claude_desktop_config.json'),
|
|
35
|
+
detectDir: join(appData, 'Claude')
|
|
34
36
|
});
|
|
35
37
|
}
|
|
36
38
|
else if (plat === 'darwin') {
|
|
37
39
|
clients.push({
|
|
38
40
|
name: 'Claude Desktop',
|
|
39
|
-
configPath: join(home, 'Library', 'Application Support', 'Claude', 'claude_desktop_config.json')
|
|
41
|
+
configPath: join(home, 'Library', 'Application Support', 'Claude', 'claude_desktop_config.json'),
|
|
42
|
+
detectDir: join(home, 'Library', 'Application Support', 'Claude')
|
|
40
43
|
});
|
|
41
44
|
}
|
|
42
45
|
else {
|
|
43
46
|
clients.push({
|
|
44
47
|
name: 'Claude Desktop',
|
|
45
|
-
configPath: join(home, '.config', 'Claude', 'claude_desktop_config.json')
|
|
48
|
+
configPath: join(home, '.config', 'Claude', 'claude_desktop_config.json'),
|
|
49
|
+
detectDir: join(home, '.config', 'Claude')
|
|
46
50
|
});
|
|
47
51
|
}
|
|
48
52
|
// Cursor
|
|
49
53
|
clients.push({
|
|
50
54
|
name: 'Cursor',
|
|
51
|
-
configPath: join(home, '.cursor', 'mcp.json')
|
|
55
|
+
configPath: join(home, '.cursor', 'mcp.json'),
|
|
56
|
+
detectDir: join(home, '.cursor')
|
|
52
57
|
});
|
|
53
58
|
// Windsurf
|
|
54
59
|
clients.push({
|
|
55
60
|
name: 'Windsurf',
|
|
56
|
-
configPath: join(home, '.codeium', 'windsurf', 'mcp_config.json')
|
|
61
|
+
configPath: join(home, '.codeium', 'windsurf', 'mcp_config.json'),
|
|
62
|
+
detectDir: join(home, '.codeium', 'windsurf')
|
|
57
63
|
});
|
|
58
64
|
return clients;
|
|
59
65
|
}
|
|
@@ -95,18 +101,26 @@ export function setupMcpClients() {
|
|
|
95
101
|
console.log('\nAiDex MCP Server Registration');
|
|
96
102
|
console.log('==============================\n');
|
|
97
103
|
for (const client of clients) {
|
|
98
|
-
if (
|
|
104
|
+
// Check if client is installed (detect directory exists)
|
|
105
|
+
if (!existsSync(client.detectDir)) {
|
|
99
106
|
results.push({ client: client.name, status: 'skipped', configPath: client.configPath });
|
|
100
107
|
console.log(` - ${client.name} (not installed)`);
|
|
101
108
|
continue;
|
|
102
109
|
}
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
|
|
107
|
-
|
|
110
|
+
// Read existing config or start with empty object
|
|
111
|
+
let data;
|
|
112
|
+
if (existsSync(client.configPath)) {
|
|
113
|
+
const config = readJsonConfig(client.configPath);
|
|
114
|
+
if (!config.success || !config.data) {
|
|
115
|
+
results.push({ client: client.name, status: 'error', configPath: client.configPath, message: config.error });
|
|
116
|
+
console.log(` ✗ ${client.name} (${config.error})`);
|
|
117
|
+
continue;
|
|
118
|
+
}
|
|
119
|
+
data = config.data;
|
|
120
|
+
}
|
|
121
|
+
else {
|
|
122
|
+
data = {};
|
|
108
123
|
}
|
|
109
|
-
const data = config.data;
|
|
110
124
|
if (!data.mcpServers || typeof data.mcpServers !== 'object') {
|
|
111
125
|
data.mcpServers = {};
|
|
112
126
|
}
|