deveco-mcp-server 0.1.9 → 0.1.11
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/index.js +4 -12
- package/package.json +4 -4
package/index.js
CHANGED
|
@@ -46,13 +46,11 @@ function checkAndWarnRegistry() {
|
|
|
46
46
|
function buildBinaryPaths(binDir) {
|
|
47
47
|
if (process.platform === 'win32') {
|
|
48
48
|
return {
|
|
49
|
-
server: path.join(binDir, 'deveco-mcp-server.exe')
|
|
50
|
-
toolbox: path.join(binDir, 'deveco-toolbox.exe')
|
|
49
|
+
server: path.join(binDir, 'deveco-mcp-server.exe')
|
|
51
50
|
};
|
|
52
51
|
} else {
|
|
53
52
|
return {
|
|
54
|
-
server: path.join(binDir, 'Contents', 'MacOS', 'deveco-mcp-server')
|
|
55
|
-
toolbox: path.join(binDir, 'Contents', 'MacOS', 'deveco-toolbox')
|
|
53
|
+
server: path.join(binDir, 'Contents', 'MacOS', 'deveco-mcp-server')
|
|
56
54
|
};
|
|
57
55
|
}
|
|
58
56
|
}
|
|
@@ -345,7 +343,7 @@ function ensureExecutablePermissions(filePath) {
|
|
|
345
343
|
}
|
|
346
344
|
|
|
347
345
|
function startServer() {
|
|
348
|
-
const { server: serverExePath
|
|
346
|
+
const { server: serverExePath } = getBinaryPaths();
|
|
349
347
|
|
|
350
348
|
if (!fs.existsSync(serverExePath)) {
|
|
351
349
|
console.error(`Error: Server executable not found at ${serverExePath}`);
|
|
@@ -355,15 +353,9 @@ function startServer() {
|
|
|
355
353
|
|
|
356
354
|
// Ensure execution permissions on Unix-like systems
|
|
357
355
|
ensureExecutablePermissions(serverExePath);
|
|
358
|
-
if (toolboxExePath && fs.existsSync(toolboxExePath)) {
|
|
359
|
-
ensureExecutablePermissions(toolboxExePath);
|
|
360
|
-
}
|
|
361
356
|
|
|
362
357
|
const args = process.argv.slice(2);
|
|
363
|
-
const env = {
|
|
364
|
-
...process.env,
|
|
365
|
-
DEVECO_TOOLBOX_PATH: toolboxExePath
|
|
366
|
-
};
|
|
358
|
+
const env = { ...process.env };
|
|
367
359
|
|
|
368
360
|
const child = spawn(serverExePath, args, {
|
|
369
361
|
stdio: 'inherit',
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "deveco-mcp-server",
|
|
3
|
-
"version": "0.1.
|
|
3
|
+
"version": "0.1.11",
|
|
4
4
|
"description": "NPM wrapper for deveco-mcp-server - HarmonyOS development MCP server with platform-specific binaries",
|
|
5
5
|
"keywords": [
|
|
6
6
|
"mcp",
|
|
@@ -16,9 +16,9 @@
|
|
|
16
16
|
"deveco-mcp-server": "index.js"
|
|
17
17
|
},
|
|
18
18
|
"optionalDependencies": {
|
|
19
|
-
"deveco-mcp-server-darwin-arm64": "0.1.
|
|
20
|
-
"deveco-mcp-server-darwin-x64": "0.1.
|
|
21
|
-
"deveco-mcp-server-win32-x64": "^0.1.
|
|
19
|
+
"deveco-mcp-server-darwin-arm64": "0.1.11",
|
|
20
|
+
"deveco-mcp-server-darwin-x64": "0.1.11",
|
|
21
|
+
"deveco-mcp-server-win32-x64": "^0.1.11"
|
|
22
22
|
},
|
|
23
23
|
"repository": {
|
|
24
24
|
"type": "git",
|