coding-friend-cli 1.34.0 → 1.35.0
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/README.md +1 -0
- package/dist/chunk-2DTXVMPQ.js +26 -0
- package/dist/{chunk-OYPOADCX.js → chunk-57EGAXYI.js} +3 -3
- package/dist/{chunk-K6EDQGDN.js → chunk-B2NFXRFP.js} +17 -12
- package/dist/{chunk-3UIH5U3Y.js → chunk-C5YWESSF.js} +2 -6
- package/dist/chunk-E5J24GD5.js +190 -0
- package/dist/{chunk-UGTNIFBH.js → chunk-H5TXJZD7.js} +6 -6
- package/dist/{chunk-5X3JZKYW.js → chunk-L53RNEV3.js} +116 -73
- package/dist/{chunk-DMJCO6LJ.js → chunk-RLUNNJWJ.js} +2 -1
- package/dist/{chunk-XOHLBLN2.js → chunk-WNTMKIKC.js} +1 -1
- package/dist/chunk-WSUYLIYX.js +61 -0
- package/dist/clean-67ACB4OS.js +95 -0
- package/dist/{chunk-CXG6I6ZF.js → config-HTQAALMA.js} +182 -194
- package/dist/{dev-S6VZUD33.js → dev-PFUF67SH.js} +7 -7
- package/dist/{disable-ZWQVU3QZ.js → disable-CDOM7SSI.js} +2 -2
- package/dist/{enable-NXP6APNI.js → enable-SF7742UR.js} +2 -2
- package/dist/{host-Y3WIXDSS.js → host-HKA4OHBM.js} +3 -3
- package/dist/index.js +38 -34
- package/dist/{init-WDFYY5MM.js → init-YM7YEEGK.js} +154 -99
- package/dist/{install-FKL6WLIG.js → install-VYZSTXN6.js} +8 -8
- package/dist/{mcp-J4SD646S.js → mcp-7MO2MCLE.js} +72 -67
- package/dist/{mcp-serve-learn-UNW6VH5M.js → mcp-serve-learn-OKVC5WV3.js} +19 -3
- package/dist/{memory-RLZR7XQY.js → memory-XALEMWQF.js} +7 -7
- package/dist/{permission-DNW7DE24.js → permission-C5R3LMZQ.js} +2 -2
- package/dist/postinstall.js +1 -1
- package/dist/{session-6WQGKIRG.js → session-M4KRQ4VU.js} +2 -2
- package/dist/{status-BX2SVBBW.js → status-2XM5OZDR.js} +19 -14
- package/dist/{statusline-MLLKBHHR.js → statusline-VFIA7OS2.js} +3 -3
- package/dist/{uninstall-6ZJRS2H4.js → uninstall-QKEC3O64.js} +6 -6
- package/dist/{update-G5HZINBK.js → update-IV4Y3T72.js} +6 -6
- package/package.json +1 -1
- package/dist/chunk-AYIREX73.js +0 -85
- package/dist/chunk-TVAY4OQL.js +0 -118
- package/dist/config-MCEQOLE5.js +0 -22
- package/dist/{chunk-Z5Q533UG.js → chunk-HPNRQYLM.js} +3 -3
- package/dist/{update-check-5SCD2JR2.js → update-check-BPCQ25AR.js} +3 -3
package/dist/chunk-TVAY4OQL.js
DELETED
|
@@ -1,118 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
detectMemoryMcpState
|
|
3
|
-
} from "./chunk-AYIREX73.js";
|
|
4
|
-
|
|
5
|
-
// src/lib/mcp-health.ts
|
|
6
|
-
async function checkMemoryMcpHealth(deps) {
|
|
7
|
-
const checks = [];
|
|
8
|
-
const mcpJson = deps.readMcpJson();
|
|
9
|
-
const state = detectMemoryMcpState(mcpJson, deps.pathExists);
|
|
10
|
-
if (state.kind === "npx") {
|
|
11
|
-
checks.push({ label: "Config (.mcp.json)", ok: true });
|
|
12
|
-
} else if (state.kind === "none") {
|
|
13
|
-
checks.push({
|
|
14
|
-
label: "Config (.mcp.json)",
|
|
15
|
-
ok: false,
|
|
16
|
-
detail: "coding-friend-memory not configured",
|
|
17
|
-
fix: 'Run "cf memory mcp" to add the MCP entry'
|
|
18
|
-
});
|
|
19
|
-
} else {
|
|
20
|
-
const detail = state.kind === "stale" ? `Stale path: ${state.path}` : `Absolute path (legacy): ${state.path}`;
|
|
21
|
-
checks.push({
|
|
22
|
-
label: "Config (.mcp.json)",
|
|
23
|
-
ok: false,
|
|
24
|
-
detail,
|
|
25
|
-
fix: 'Run "cf memory mcp" to update to the npx format'
|
|
26
|
-
});
|
|
27
|
-
}
|
|
28
|
-
const distExists = deps.pathExists(deps.memoryDistPath);
|
|
29
|
-
checks.push({
|
|
30
|
-
label: "Package built",
|
|
31
|
-
ok: distExists,
|
|
32
|
-
...distExists ? {} : {
|
|
33
|
-
detail: "cf-memory not built",
|
|
34
|
-
fix: 'Run "cf memory init" to build'
|
|
35
|
-
}
|
|
36
|
-
});
|
|
37
|
-
let daemonRunning = false;
|
|
38
|
-
let daemonCheckError;
|
|
39
|
-
try {
|
|
40
|
-
daemonRunning = await deps.isDaemonRunning();
|
|
41
|
-
} catch (err) {
|
|
42
|
-
daemonCheckError = err instanceof Error ? err.message : String(err);
|
|
43
|
-
}
|
|
44
|
-
checks.push({
|
|
45
|
-
label: "Daemon status",
|
|
46
|
-
ok: daemonRunning,
|
|
47
|
-
...daemonRunning ? {} : {
|
|
48
|
-
warn: true,
|
|
49
|
-
detail: daemonCheckError ? `check failed: ${daemonCheckError}` : "stopped (starts automatically on MCP connect)"
|
|
50
|
-
}
|
|
51
|
-
});
|
|
52
|
-
const ok = checks.every((c) => c.ok || c.warn === true);
|
|
53
|
-
return { checks, ok };
|
|
54
|
-
}
|
|
55
|
-
async function checkLearnMcpHealth(deps) {
|
|
56
|
-
const checks = [];
|
|
57
|
-
const mcpJson = deps.readMcpJson();
|
|
58
|
-
const servers = mcpJson?.mcpServers;
|
|
59
|
-
const hasEntry = servers != null && typeof servers === "object" && !Array.isArray(servers) && "coding-friend-learn" in servers;
|
|
60
|
-
checks.push({
|
|
61
|
-
label: "Config (.mcp.json)",
|
|
62
|
-
ok: hasEntry,
|
|
63
|
-
...hasEntry ? {} : {
|
|
64
|
-
detail: "coding-friend-learn not configured",
|
|
65
|
-
fix: 'Run "cf mcp" to print the config snippet and add it'
|
|
66
|
-
}
|
|
67
|
-
});
|
|
68
|
-
const distExists = deps.pathExists(deps.learnMcpDistPath);
|
|
69
|
-
checks.push({
|
|
70
|
-
label: "Package built",
|
|
71
|
-
ok: distExists,
|
|
72
|
-
...distExists ? {} : {
|
|
73
|
-
detail: "learn-mcp not built",
|
|
74
|
-
fix: 'Run "cf mcp" to install and build'
|
|
75
|
-
}
|
|
76
|
-
});
|
|
77
|
-
const mdFiles = deps.listMdFiles(deps.docsDir);
|
|
78
|
-
const hasDocs = mdFiles.length > 0;
|
|
79
|
-
checks.push({
|
|
80
|
-
label: "Docs directory",
|
|
81
|
-
ok: hasDocs,
|
|
82
|
-
...hasDocs ? {} : {
|
|
83
|
-
detail: `No .md files found in ${deps.docsDir}`,
|
|
84
|
-
fix: 'Run "/cf-learn" to generate docs'
|
|
85
|
-
}
|
|
86
|
-
});
|
|
87
|
-
const ok = checks.every((c) => c.ok || c.warn === true);
|
|
88
|
-
return { checks, ok };
|
|
89
|
-
}
|
|
90
|
-
|
|
91
|
-
// src/lib/fs-utils.ts
|
|
92
|
-
import { readdirSync } from "fs";
|
|
93
|
-
import { join } from "path";
|
|
94
|
-
function listMdFilesRecursive(dir, maxDepth = 15) {
|
|
95
|
-
try {
|
|
96
|
-
const results = [];
|
|
97
|
-
for (const entry of readdirSync(dir, { withFileTypes: true })) {
|
|
98
|
-
if (entry.isDirectory()) {
|
|
99
|
-
if (maxDepth > 0) {
|
|
100
|
-
results.push(
|
|
101
|
-
...listMdFilesRecursive(join(dir, entry.name), maxDepth - 1)
|
|
102
|
-
);
|
|
103
|
-
}
|
|
104
|
-
} else if (entry.name.endsWith(".md") && entry.name !== "README.md") {
|
|
105
|
-
results.push(entry.name);
|
|
106
|
-
}
|
|
107
|
-
}
|
|
108
|
-
return results;
|
|
109
|
-
} catch {
|
|
110
|
-
return [];
|
|
111
|
-
}
|
|
112
|
-
}
|
|
113
|
-
|
|
114
|
-
export {
|
|
115
|
-
checkMemoryMcpHealth,
|
|
116
|
-
checkLearnMcpHealth,
|
|
117
|
-
listMdFilesRecursive
|
|
118
|
-
};
|
package/dist/config-MCEQOLE5.js
DELETED
|
@@ -1,22 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
buildCodexConfig,
|
|
3
|
-
configCommand,
|
|
4
|
-
editCodex
|
|
5
|
-
} from "./chunk-CXG6I6ZF.js";
|
|
6
|
-
import "./chunk-3UIH5U3Y.js";
|
|
7
|
-
import "./chunk-K6EDQGDN.js";
|
|
8
|
-
import "./chunk-RZRT7NGT.js";
|
|
9
|
-
import "./chunk-XOHLBLN2.js";
|
|
10
|
-
import "./chunk-OYPOADCX.js";
|
|
11
|
-
import "./chunk-DMJCO6LJ.js";
|
|
12
|
-
import "./chunk-Z5Q533UG.js";
|
|
13
|
-
import "./chunk-TWKNGPBO.js";
|
|
14
|
-
import "./chunk-EVGXUDX4.js";
|
|
15
|
-
import "./chunk-NREZK463.js";
|
|
16
|
-
import "./chunk-O27FVQFU.js";
|
|
17
|
-
import "./chunk-5UVDWG5L.js";
|
|
18
|
-
export {
|
|
19
|
-
buildCodexConfig,
|
|
20
|
-
configCommand,
|
|
21
|
-
editCodex
|
|
22
|
-
};
|