patchcord 0.3.91 → 0.3.93
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 +4 -27
- package/package.json +1 -1
package/bin/patchcord.mjs
CHANGED
|
@@ -352,32 +352,9 @@ if (!cmd || cmd === "install" || cmd === "agent" || cmd === "--token" || cmd ===
|
|
|
352
352
|
}
|
|
353
353
|
} catch {}
|
|
354
354
|
}
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
try {
|
|
359
|
-
const oc = JSON.parse(readFileSync(openclawJsonPath, "utf-8"));
|
|
360
|
-
const pt = oc?.mcp?.servers?.patchcord;
|
|
361
|
-
if (pt?.headers?.Authorization) {
|
|
362
|
-
existingToken = pt.headers.Authorization.replace(/^Bearer\s+/i, "");
|
|
363
|
-
existingConfigFile = openclawJsonPath;
|
|
364
|
-
}
|
|
365
|
-
} catch {}
|
|
366
|
-
}
|
|
367
|
-
}
|
|
368
|
-
if (!existingToken) {
|
|
369
|
-
const agJsonPath = join(HOME, ".gemini", "antigravity", "mcp_config.json");
|
|
370
|
-
if (existsSync(agJsonPath)) {
|
|
371
|
-
try {
|
|
372
|
-
const ag = JSON.parse(readFileSync(agJsonPath, "utf-8"));
|
|
373
|
-
const pt = ag?.mcpServers?.patchcord;
|
|
374
|
-
if (pt?.headers?.Authorization) {
|
|
375
|
-
existingToken = pt.headers.Authorization.replace(/^Bearer\s+/i, "");
|
|
376
|
-
existingConfigFile = agJsonPath;
|
|
377
|
-
}
|
|
378
|
-
} catch {}
|
|
379
|
-
}
|
|
380
|
-
}
|
|
355
|
+
// Global configs (Antigravity, OpenClaw, Gemini, Windsurf, Zed) are NOT
|
|
356
|
+
// checked here. They're set up once globally and should not block new
|
|
357
|
+
// project setup. Only per-project configs trigger "already configured."
|
|
381
358
|
if (existingToken) {
|
|
382
359
|
// Figure out which tool is already configured
|
|
383
360
|
const existingToolName = existingConfigFile.includes(".codex") ? "Codex"
|
|
@@ -516,7 +493,7 @@ if (!cmd || cmd === "install" || cmd === "agent" || cmd === "--token" || cmd ===
|
|
|
516
493
|
const sseResult = await new Promise((resolve, reject) => {
|
|
517
494
|
const timeout = setTimeout(() => {
|
|
518
495
|
reject(new Error("Session expired. Run npx patchcord@latest again."));
|
|
519
|
-
},
|
|
496
|
+
}, 15 * 60 * 1000);
|
|
520
497
|
|
|
521
498
|
function connect() {
|
|
522
499
|
const req = http.get(`${apiUrl}/api/connect/session/${sessionId}/wait`, {
|