coding-friend-cli 1.32.0 → 1.32.2
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/{chunk-U7IVVN45.js → chunk-3QK6S74O.js} +8 -25
- package/dist/{chunk-5OXEUKOE.js → chunk-66EDSJ6W.js} +156 -149
- package/dist/{chunk-4IUUWBZG.js → chunk-G4QGJEV7.js} +4 -4
- package/dist/{config-OBCZNDKV.js → config-RE4SQ6Y7.js} +7 -7
- package/dist/{disable-CDOM7SSI.js → disable-ZWQVU3QZ.js} +2 -2
- package/dist/{enable-SF7742UR.js → enable-NXP6APNI.js} +2 -2
- package/dist/index.js +37 -29
- package/dist/{init-H2EOLWJ5.js → init-F2NO6NCJ.js} +8 -8
- package/dist/{install-JR4ITJVU.js → install-22BLHQ6D.js} +5 -5
- package/dist/{mcp-G4FEXMZW.js → mcp-VQ5OXXU7.js} +23 -57
- package/dist/mcp-serve-3FEPFVVQ.js +27 -0
- package/dist/mcp-serve-learn-UNW6VH5M.js +59 -0
- package/dist/{memory-SO33RAI5.js → memory-GKANJJXU.js} +5 -5
- package/dist/{permission-C5R3LMZQ.js → permission-DNW7DE24.js} +2 -2
- package/dist/{status-EFEXM3ZM.js → status-7YW3YV2Y.js} +6 -6
- package/dist/{uninstall-BOVKPNYN.js → uninstall-6ZJRS2H4.js} +5 -5
- package/dist/{update-JBCG4CY2.js → update-P5ZR2JVQ.js} +3 -3
- package/package.json +1 -1
- package/dist/{chunk-HPNRQYLM.js → chunk-Z5Q533UG.js} +3 -3
- package/dist/{dev-VNDV6R24.js → dev-QXVERU42.js} +4 -4
- package/dist/{host-N3GQ6OJM.js → host-XZZEMMMI.js} +4 -4
- package/dist/{statusline-5X7FZGRU.js → statusline-GKVAX7GR.js} +1 -1
- package/dist/{update-check-BPCQ25AR.js → update-check-5SCD2JR2.js} +3 -3
|
@@ -1,15 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
getLibPath
|
|
3
|
-
} from "./chunk-RZRT7NGT.js";
|
|
4
1
|
import {
|
|
5
2
|
resolveMemoryDir
|
|
6
3
|
} from "./chunk-GTX6I57V.js";
|
|
4
|
+
import {
|
|
5
|
+
getLibPath
|
|
6
|
+
} from "./chunk-RZRT7NGT.js";
|
|
7
7
|
import {
|
|
8
8
|
BACK,
|
|
9
9
|
askScope,
|
|
10
10
|
formatScopeLabel,
|
|
11
11
|
injectBackChoice
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-Z5Q533UG.js";
|
|
13
13
|
import {
|
|
14
14
|
globalConfigPath,
|
|
15
15
|
localConfigPath
|
|
@@ -24,7 +24,6 @@ import {
|
|
|
24
24
|
} from "./chunk-5UVDWG5L.js";
|
|
25
25
|
|
|
26
26
|
// src/lib/memory-prompts.ts
|
|
27
|
-
import { existsSync } from "fs";
|
|
28
27
|
import { homedir } from "os";
|
|
29
28
|
import { confirm, input, select } from "@inquirer/prompts";
|
|
30
29
|
import chalk from "chalk";
|
|
@@ -219,7 +218,7 @@ async function editMemoryEmbedding(globalCfg, localCfg) {
|
|
|
219
218
|
if (ollamaUrl) embedding.ollamaUrl = ollamaUrl;
|
|
220
219
|
writeMemoryField(scope, "embedding", embedding);
|
|
221
220
|
}
|
|
222
|
-
function writeMemoryMcpEntry(
|
|
221
|
+
function writeMemoryMcpEntry(memoryDir) {
|
|
223
222
|
const mcpPath = join(process.cwd(), ".mcp.json");
|
|
224
223
|
const existing = readJson(mcpPath) ?? {};
|
|
225
224
|
const servers = existing.mcpServers ?? {};
|
|
@@ -228,8 +227,8 @@ function writeMemoryMcpEntry(serverPath, memoryDir) {
|
|
|
228
227
|
mcpServers: {
|
|
229
228
|
...servers,
|
|
230
229
|
"coding-friend-memory": {
|
|
231
|
-
command: "
|
|
232
|
-
args: [
|
|
230
|
+
command: "npx",
|
|
231
|
+
args: ["-y", "coding-friend-cli", "mcp-serve", memoryDir]
|
|
233
232
|
}
|
|
234
233
|
}
|
|
235
234
|
});
|
|
@@ -261,24 +260,8 @@ async function editMemoryMcp() {
|
|
|
261
260
|
});
|
|
262
261
|
if (!reconfigure) return;
|
|
263
262
|
}
|
|
264
|
-
let mcpDir;
|
|
265
|
-
try {
|
|
266
|
-
mcpDir = getLibPath("cf-memory");
|
|
267
|
-
} catch {
|
|
268
|
-
log.warn(
|
|
269
|
-
"cf-memory package not found. Install the CLI first: npm i -g coding-friend-cli"
|
|
270
|
-
);
|
|
271
|
-
return;
|
|
272
|
-
}
|
|
273
|
-
const serverPath = join(mcpDir, "dist", "index.js");
|
|
274
|
-
if (!existsSync(serverPath)) {
|
|
275
|
-
log.warn(
|
|
276
|
-
'cf-memory not built yet. Run "cf memory mcp" after building to get the config.'
|
|
277
|
-
);
|
|
278
|
-
return;
|
|
279
|
-
}
|
|
280
263
|
const memoryDir = resolveMemoryDir();
|
|
281
|
-
writeMemoryMcpEntry(
|
|
264
|
+
writeMemoryMcpEntry(memoryDir);
|
|
282
265
|
}
|
|
283
266
|
async function memoryConfigMenu(opts) {
|
|
284
267
|
while (true) {
|