mcmodding-mcp 0.4.0 → 0.4.3
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 +74 -32
- package/dist/cli/manage.d.ts.map +1 -1
- package/dist/cli/manage.js +31 -29
- package/dist/cli/manage.js.map +1 -1
- package/dist/data-dir.d.ts +3 -0
- package/dist/data-dir.d.ts.map +1 -0
- package/dist/data-dir.js +21 -0
- package/dist/data-dir.js.map +1 -0
- package/dist/db-versioning.d.ts.map +1 -1
- package/dist/db-versioning.js +5 -1
- package/dist/db-versioning.js.map +1 -1
- package/dist/index.js +1 -1
- package/dist/services/concept-service.d.ts.map +1 -1
- package/dist/services/concept-service.js +2 -2
- package/dist/services/concept-service.js.map +1 -1
- package/dist/services/example-service.d.ts.map +1 -1
- package/dist/services/example-service.js +2 -2
- package/dist/services/example-service.js.map +1 -1
- package/dist/services/mappings-service.d.ts.map +1 -1
- package/dist/services/mappings-service.js +2 -2
- package/dist/services/mappings-service.js.map +1 -1
- package/dist/services/mod-examples-service.d.ts.map +1 -1
- package/dist/services/mod-examples-service.js +2 -2
- package/dist/services/mod-examples-service.js.map +1 -1
- package/dist/services/search-service.d.ts.map +1 -1
- package/dist/services/search-service.js +2 -2
- package/dist/services/search-service.js.map +1 -1
- package/package.json +19 -9
- package/scripts/postinstall.js +22 -4
package/package.json
CHANGED
|
@@ -1,6 +1,7 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "mcmodding-mcp",
|
|
3
|
-
"version": "0.4.
|
|
3
|
+
"version": "0.4.3",
|
|
4
|
+
"packageManager": "pnpm@10.30.0",
|
|
4
5
|
"description": "MCP server providing AI assistants with up-to-date Minecraft modding documentation for Fabric and NeoForge",
|
|
5
6
|
"type": "module",
|
|
6
7
|
"main": "dist/index.js",
|
|
@@ -13,7 +14,7 @@
|
|
|
13
14
|
],
|
|
14
15
|
"scripts": {
|
|
15
16
|
"build": "tsc",
|
|
16
|
-
"build:prod": "
|
|
17
|
+
"build:prod": "pnpm run build",
|
|
17
18
|
"dev": "tsx watch src/index.ts",
|
|
18
19
|
"start": "node dist/index.js",
|
|
19
20
|
"test": "vitest",
|
|
@@ -30,13 +31,13 @@
|
|
|
30
31
|
"index-docs:no-embeddings": "npx tsx --expose-gc --max-old-space-size=4096 scripts/index-docs.ts -- --sitemap",
|
|
31
32
|
"clean": "rimraf dist",
|
|
32
33
|
"clean:all": "rimraf dist data",
|
|
33
|
-
"prebuild": "
|
|
34
|
-
"prebuild:prod": "
|
|
34
|
+
"prebuild": "pnpm run clean",
|
|
35
|
+
"prebuild:prod": "pnpm run clean",
|
|
35
36
|
"postinstall": "node scripts/postinstall.js",
|
|
36
37
|
"prepublishOnly": "",
|
|
37
38
|
"release:auto": "semantic-release",
|
|
38
|
-
"release": "
|
|
39
|
-
"validate": "
|
|
39
|
+
"release": "pnpm run build:prod && pnpm version",
|
|
40
|
+
"validate": "pnpm run typecheck && pnpm run lint && pnpm run test",
|
|
40
41
|
"db:manifest": "npx tsx scripts/generate-db-manifest.ts",
|
|
41
42
|
"db:install-optional": "npx tsx src/index.ts install",
|
|
42
43
|
"index-mappings": "npx tsx scripts/index-mappings.ts",
|
|
@@ -67,7 +68,8 @@
|
|
|
67
68
|
"better-sqlite3": "^11.7.0",
|
|
68
69
|
"cheerio": "^1.0.0",
|
|
69
70
|
"jsonrepair": "^3.13.1",
|
|
70
|
-
"node-fetch": "^3.3.2"
|
|
71
|
+
"node-fetch": "^3.3.2",
|
|
72
|
+
"sharp": "^0.34.5"
|
|
71
73
|
},
|
|
72
74
|
"devDependencies": {
|
|
73
75
|
"@commitlint/cli": "^19.6.0",
|
|
@@ -76,10 +78,10 @@
|
|
|
76
78
|
"@semantic-release/changelog": "^6.0.3",
|
|
77
79
|
"@semantic-release/exec": "^7.1.0",
|
|
78
80
|
"@semantic-release/git": "^10.0.1",
|
|
81
|
+
"@types/adm-zip": "^0.5.6",
|
|
79
82
|
"@types/better-sqlite3": "^7.6.12",
|
|
80
83
|
"@types/jquery": "^3.5.33",
|
|
81
84
|
"@types/node": "^22.10.1",
|
|
82
|
-
"@types/adm-zip": "^0.5.6",
|
|
83
85
|
"@typescript-eslint/eslint-plugin": "^8.15.0",
|
|
84
86
|
"@typescript-eslint/parser": "^8.15.0",
|
|
85
87
|
"@vitest/coverage-v8": "^4.0.15",
|
|
@@ -117,5 +119,13 @@
|
|
|
117
119
|
"bugs": {
|
|
118
120
|
"url": "https://github.com/OGMatrix/mcmodding-mcp/issues"
|
|
119
121
|
},
|
|
120
|
-
"homepage": "https://github.com/OGMatrix/mcmodding-mcp#readme"
|
|
122
|
+
"homepage": "https://github.com/OGMatrix/mcmodding-mcp#readme",
|
|
123
|
+
"pnpm": {
|
|
124
|
+
"onlyBuiltDependencies": [
|
|
125
|
+
"better-sqlite3",
|
|
126
|
+
"esbuild",
|
|
127
|
+
"protobufjs",
|
|
128
|
+
"sharp"
|
|
129
|
+
]
|
|
130
|
+
}
|
|
121
131
|
}
|
package/scripts/postinstall.js
CHANGED
|
@@ -11,10 +11,28 @@ import fs from 'fs';
|
|
|
11
11
|
import path from 'path';
|
|
12
12
|
import crypto from 'crypto';
|
|
13
13
|
import https from 'https';
|
|
14
|
-
import
|
|
14
|
+
import os from 'os';
|
|
15
15
|
|
|
16
|
-
|
|
17
|
-
|
|
16
|
+
// ═══════════════════════════════════════════════════════════════════════════════
|
|
17
|
+
// SHARED DATA DIRECTORY (must match src/data-dir.ts logic exactly)
|
|
18
|
+
// ═══════════════════════════════════════════════════════════════════════════════
|
|
19
|
+
|
|
20
|
+
function getDefaultDataDir() {
|
|
21
|
+
if (process.env.MCMODDING_DATA_DIR) {
|
|
22
|
+
return process.env.MCMODDING_DATA_DIR;
|
|
23
|
+
}
|
|
24
|
+
const platform = process.platform;
|
|
25
|
+
if (platform === 'win32') {
|
|
26
|
+
const appData = process.env.APPDATA || path.join(os.homedir(), 'AppData', 'Roaming');
|
|
27
|
+
return path.join(appData, 'mcmodding-mcp');
|
|
28
|
+
}
|
|
29
|
+
if (platform === 'darwin') {
|
|
30
|
+
return path.join(os.homedir(), 'Library', 'Application Support', 'mcmodding-mcp');
|
|
31
|
+
}
|
|
32
|
+
// Linux / FreeBSD / others: XDG Base Directory Specification
|
|
33
|
+
const xdgDataHome = process.env.XDG_DATA_HOME || path.join(os.homedir(), '.local', 'share');
|
|
34
|
+
return path.join(xdgDataHome, 'mcmodding-mcp');
|
|
35
|
+
}
|
|
18
36
|
|
|
19
37
|
// ═══════════════════════════════════════════════════════════════════════════════
|
|
20
38
|
// CONFIGURATION
|
|
@@ -22,7 +40,7 @@ const __dirname = path.dirname(__filename);
|
|
|
22
40
|
|
|
23
41
|
const CONFIG = {
|
|
24
42
|
repoUrl: 'https://api.github.com/repos/OGMatrix/mcmodding-mcp/releases',
|
|
25
|
-
dataDir:
|
|
43
|
+
dataDir: getDefaultDataDir(),
|
|
26
44
|
dbFileName: 'mcmodding-docs.db',
|
|
27
45
|
manifestFileName: 'db-manifest.json',
|
|
28
46
|
userAgent: 'mcmodding-mcp-installer',
|