mindwtr-mcp 1.1.4 → 1.1.6
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 +10 -10
- package/dist/cli.js +19 -0
- package/dist/index.js +47800 -32206
- package/package.json +6 -5
package/README.md
CHANGED
|
@@ -162,7 +162,7 @@ Stop:
|
|
|
162
162
|
```bash
|
|
163
163
|
# from repo root
|
|
164
164
|
bun run --filter mindwtr-mcp build
|
|
165
|
-
node apps/mcp-server/dist/
|
|
165
|
+
node apps/mcp-server/dist/cli.js --db "/path/to/mindwtr.db"
|
|
166
166
|
```
|
|
167
167
|
|
|
168
168
|
Stop:
|
|
@@ -182,7 +182,7 @@ bun run mindwtr:mcp -- --db "/path/to/mindwtr.db"
|
|
|
182
182
|
|
|
183
183
|
# ✅ build then run
|
|
184
184
|
bun run --filter mindwtr-mcp build
|
|
185
|
-
node apps/mcp-server/dist/
|
|
185
|
+
node apps/mcp-server/dist/cli.js --db "/path/to/mindwtr.db"
|
|
186
186
|
```
|
|
187
187
|
|
|
188
188
|
### Optional: create a global `mindwtr-mcp` command
|
|
@@ -225,7 +225,7 @@ MCP clients run the server as a subprocess. You point them to **the command** an
|
|
|
225
225
|
"mindwtr": {
|
|
226
226
|
"command": "bun",
|
|
227
227
|
"args": [
|
|
228
|
-
"/absolute/path/to/Mindwtr/apps/mcp-server/src/
|
|
228
|
+
"/absolute/path/to/Mindwtr/apps/mcp-server/src/cli.ts",
|
|
229
229
|
"--db",
|
|
230
230
|
"~/.local/share/mindwtr/mindwtr.db"
|
|
231
231
|
]
|
|
@@ -249,7 +249,7 @@ cd /path/to/Mindwtr && bun run --filter mindwtr-mcp build
|
|
|
249
249
|
"mindwtr": {
|
|
250
250
|
"command": "node",
|
|
251
251
|
"args": [
|
|
252
|
-
"/absolute/path/to/Mindwtr/apps/mcp-server/dist/
|
|
252
|
+
"/absolute/path/to/Mindwtr/apps/mcp-server/dist/cli.js",
|
|
253
253
|
"--db",
|
|
254
254
|
"~/.local/share/mindwtr/mindwtr.db"
|
|
255
255
|
]
|
|
@@ -276,7 +276,7 @@ Add a server via the CLI:
|
|
|
276
276
|
|
|
277
277
|
```bash
|
|
278
278
|
claude mcp add mindwtr -- \
|
|
279
|
-
bun /path/to/Mindwtr/apps/mcp-server/src/
|
|
279
|
+
bun /path/to/Mindwtr/apps/mcp-server/src/cli.ts --db "/path/to/mindwtr.db" --write
|
|
280
280
|
```
|
|
281
281
|
|
|
282
282
|
Or edit `~/.claude.json` directly:
|
|
@@ -290,7 +290,7 @@ Or edit `~/.claude.json` directly:
|
|
|
290
290
|
"type": "stdio",
|
|
291
291
|
"command": "bun",
|
|
292
292
|
"args": [
|
|
293
|
-
"/absolute/path/to/Mindwtr/apps/mcp-server/src/
|
|
293
|
+
"/absolute/path/to/Mindwtr/apps/mcp-server/src/cli.ts",
|
|
294
294
|
"--db",
|
|
295
295
|
"~/.local/share/mindwtr/mindwtr.db",
|
|
296
296
|
"--write"
|
|
@@ -311,7 +311,7 @@ Codex stores MCP config in `~/.codex/config.toml`. Add:
|
|
|
311
311
|
```toml
|
|
312
312
|
[mcp_servers.mindwtr]
|
|
313
313
|
command = "bun"
|
|
314
|
-
args = ["/absolute/path/to/Mindwtr/apps/mcp-server/src/
|
|
314
|
+
args = ["/absolute/path/to/Mindwtr/apps/mcp-server/src/cli.ts", "--db", "/path/to/mindwtr.db", "--write"]
|
|
315
315
|
|
|
316
316
|
# Optional: pass env vars to the server
|
|
317
317
|
[mcp_servers.mindwtr.env]
|
|
@@ -332,7 +332,7 @@ You can add Mindwtr MCP two ways:
|
|
|
332
332
|
|
|
333
333
|
```bash
|
|
334
334
|
gemini mcp add mindwtr \
|
|
335
|
-
bun /absolute/path/to/Mindwtr/apps/mcp-server/src/
|
|
335
|
+
bun /absolute/path/to/Mindwtr/apps/mcp-server/src/cli.ts \
|
|
336
336
|
--db "/path/to/mindwtr.db" --write
|
|
337
337
|
```
|
|
338
338
|
|
|
@@ -343,7 +343,7 @@ gemini mcp add mindwtr \
|
|
|
343
343
|
"mcpServers": {
|
|
344
344
|
"mindwtr": {
|
|
345
345
|
"command": "bun",
|
|
346
|
-
"args": ["/absolute/path/to/Mindwtr/apps/mcp-server/src/
|
|
346
|
+
"args": ["/absolute/path/to/Mindwtr/apps/mcp-server/src/cli.ts", "--db", "/path/to/mindwtr.db", "--write"]
|
|
347
347
|
}
|
|
348
348
|
}
|
|
349
349
|
}
|
|
@@ -506,7 +506,7 @@ If these succeed, the stdio transport is working end-to-end.
|
|
|
506
506
|
1) Add the server:
|
|
507
507
|
```bash
|
|
508
508
|
claude mcp add mindwtr -- \
|
|
509
|
-
bun /path/to/Mindwtr/apps/mcp-server/src/
|
|
509
|
+
bun /path/to/Mindwtr/apps/mcp-server/src/cli.ts --db "/path/to/mindwtr.db" --write
|
|
510
510
|
```
|
|
511
511
|
2) Restart Claude Code, run `/mcp`, and verify **mindwtr** is connected.
|
|
512
512
|
3) Ask the model to call:
|
package/dist/cli.js
ADDED
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
#!/usr/bin/env node
|
|
2
|
+
// The package's only executable entry point (npm "bin"). Kept separate from index.ts so
|
|
3
|
+
// importing the package as a library (its npm "main") can never boot a stdio server as a
|
|
4
|
+
// side effect - see startMcpServer's own doc history for BUG-14: a
|
|
5
|
+
// `bun build --target node --format esm` guard here would compile to a tautology that starts
|
|
6
|
+
// the server on import too (verified against Node 22).
|
|
7
|
+
//
|
|
8
|
+
// The build copies this file to dist/cli.js verbatim rather than bundling it (see
|
|
9
|
+
// package.json's "build" script): bundling re-inlined the whole ~6.4MB index.js graph into
|
|
10
|
+
// cli.js too, doubling the published package for no reason since dist/cli.js only needs to
|
|
11
|
+
// import dist/index.js at runtime. A verbatim copy works because this file is deliberately
|
|
12
|
+
// kept to plain-JS syntax (no TS-only constructs) - `tsc --noEmit` in the typecheck script
|
|
13
|
+
// still catches any drift from that.
|
|
14
|
+
import { logError, startMcpServer } from './index.js';
|
|
15
|
+
|
|
16
|
+
startMcpServer().catch((error) => {
|
|
17
|
+
logError('Failed to start server', error);
|
|
18
|
+
process.exit(1);
|
|
19
|
+
});
|