local-mcp 3.0.165 → 3.0.167
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/download.js +15 -1
- package/package.json +1 -1
package/download.js
CHANGED
|
@@ -575,7 +575,21 @@ async function _ensureTrayWindows() {
|
|
|
575
575
|
const url = `https://download.local-mcp.com/lmcp-tray.exe?v=${version}`
|
|
576
576
|
process.stderr.write(`\nDescargando tray v${version}...\n`)
|
|
577
577
|
fs.mkdirSync(binDir, { recursive: true })
|
|
578
|
-
|
|
578
|
+
|
|
579
|
+
// Download to a temp file first — if the tray is running, the exe is locked
|
|
580
|
+
// and we can't write directly to it (EBUSY). Download first, then kill, then replace.
|
|
581
|
+
const tmpPath = trayPath + '.tmp'
|
|
582
|
+
try { if (fs.existsSync(tmpPath)) fs.unlinkSync(tmpPath) } catch {}
|
|
583
|
+
await downloadFile(url, tmpPath)
|
|
584
|
+
|
|
585
|
+
// Kill the running tray (if any) before replacing the binary
|
|
586
|
+
try { execSync('taskkill /F /IM lmcp-tray.exe /T', { stdio: 'ignore' }) } catch {}
|
|
587
|
+
// Give Windows a moment to release the file handle
|
|
588
|
+
await new Promise(r => setTimeout(r, 500))
|
|
589
|
+
|
|
590
|
+
// Replace the old binary with the downloaded one
|
|
591
|
+
try { if (fs.existsSync(trayPath)) fs.unlinkSync(trayPath) } catch {}
|
|
592
|
+
fs.renameSync(tmpPath, trayPath)
|
|
579
593
|
|
|
580
594
|
const stat = fs.statSync(trayPath)
|
|
581
595
|
if (stat.size < 100000) {
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "local-mcp",
|
|
3
|
-
"version": "3.0.
|
|
3
|
+
"version": "3.0.167",
|
|
4
4
|
"description": "LMCP — connect Claude Desktop, Cursor, Windsurf to Mail, Calendar, Contacts, Teams, OneDrive on macOS. Privacy-first: all data stays on your Mac.",
|
|
5
5
|
"main": "index.js",
|
|
6
6
|
"bin": {
|