patchcord 0.3.38 → 0.3.39
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/bin/patchcord.mjs +9 -0
- package/package.json +1 -1
package/bin/patchcord.mjs
CHANGED
|
@@ -408,6 +408,8 @@ if (!cmd || cmd === "install" || cmd === "agent") {
|
|
|
408
408
|
|
|
409
409
|
rl.close();
|
|
410
410
|
|
|
411
|
+
const hostname = run("hostname -s") || run("hostname") || "unknown";
|
|
412
|
+
|
|
411
413
|
if (isCursor) {
|
|
412
414
|
// Cursor: write .cursor/mcp.json (per-project)
|
|
413
415
|
const cursorDir = join(cwd, ".cursor");
|
|
@@ -422,6 +424,8 @@ if (!cmd || cmd === "install" || cmd === "agent") {
|
|
|
422
424
|
serverUrl,
|
|
423
425
|
"--header",
|
|
424
426
|
`Authorization: Bearer ${token}`,
|
|
427
|
+
"--header",
|
|
428
|
+
`X-Patchcord-Machine: ${hostname}`,
|
|
425
429
|
],
|
|
426
430
|
},
|
|
427
431
|
},
|
|
@@ -453,6 +457,8 @@ if (!cmd || cmd === "install" || cmd === "agent") {
|
|
|
453
457
|
serverUrl,
|
|
454
458
|
"--header",
|
|
455
459
|
`Authorization: Bearer ${token}`,
|
|
460
|
+
"--header",
|
|
461
|
+
`X-Patchcord-Machine: ${hostname}`,
|
|
456
462
|
],
|
|
457
463
|
},
|
|
458
464
|
},
|
|
@@ -494,6 +500,7 @@ if (!cmd || cmd === "install" || cmd === "agent") {
|
|
|
494
500
|
httpUrl: `${serverUrl}/mcp`,
|
|
495
501
|
headers: {
|
|
496
502
|
Authorization: `Bearer ${token}`,
|
|
503
|
+
"X-Patchcord-Machine": hostname,
|
|
497
504
|
},
|
|
498
505
|
};
|
|
499
506
|
// Clean up deprecated tools.allowed if present (removed in Gemini CLI 1.0)
|
|
@@ -517,6 +524,7 @@ if (!cmd || cmd === "install" || cmd === "agent") {
|
|
|
517
524
|
url: `${serverUrl}/mcp`,
|
|
518
525
|
headers: {
|
|
519
526
|
Authorization: `Bearer ${token}`,
|
|
527
|
+
"X-Patchcord-Machine": hostname,
|
|
520
528
|
},
|
|
521
529
|
},
|
|
522
530
|
},
|
|
@@ -578,6 +586,7 @@ if (!cmd || cmd === "install" || cmd === "agent") {
|
|
|
578
586
|
url: `${serverUrl}/mcp`,
|
|
579
587
|
headers: {
|
|
580
588
|
Authorization: `Bearer ${token}`,
|
|
589
|
+
"X-Patchcord-Machine": hostname,
|
|
581
590
|
},
|
|
582
591
|
},
|
|
583
592
|
},
|