@codebakers/cli 1.1.0 → 1.1.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/dist/index.js +7 -5
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -99,7 +99,7 @@ var IDE_CONFIGS = {
|
|
|
99
99
|
description: "Cursor AI IDE"
|
|
100
100
|
},
|
|
101
101
|
"claude-code": {
|
|
102
|
-
file: ".
|
|
102
|
+
file: ".mcp.json",
|
|
103
103
|
description: "Claude Code"
|
|
104
104
|
}
|
|
105
105
|
};
|
|
@@ -222,10 +222,12 @@ Error: ${message}`));
|
|
|
222
222
|
}
|
|
223
223
|
async function configureMCP(ide, force, spinner) {
|
|
224
224
|
const config = IDE_CONFIGS[ide];
|
|
225
|
-
const
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
225
|
+
const targetPath = ide === "cursor" ? join(process.cwd(), ".cursor", "mcp.json") : join(process.cwd(), ".mcp.json");
|
|
226
|
+
if (ide === "cursor") {
|
|
227
|
+
const targetDir = join(process.cwd(), ".cursor");
|
|
228
|
+
if (!existsSync(targetDir)) {
|
|
229
|
+
await mkdir(targetDir, { recursive: true });
|
|
230
|
+
}
|
|
229
231
|
}
|
|
230
232
|
let existingConfig = {};
|
|
231
233
|
if (existsSync(targetPath)) {
|