claude-yes 1.150.0 → 1.151.1
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/dist/{SUPPORTED_CLIS-D8mK1P78.js → SUPPORTED_CLIS-CKqnbe_-.js} +2 -2
- package/dist/SUPPORTED_CLIS-VRQX4l7K.js +8 -0
- package/dist/cli.js +3 -13
- package/dist/index.js +2 -2
- package/dist/{schedule-3FpLAXCx.js → schedule-CHhOFoc_.js} +4 -4
- package/dist/{serve-plR3NUPH.js → serve-D95Tjt_c.js} +12 -6
- package/dist/{setup-BWGYyij8.js → setup-BU0hqKTl.js} +2 -2
- package/dist/{subcommands-BDftiFrp.js → subcommands-8qtgnf0g.js} +1 -1
- package/dist/{subcommands-BtUKGF4n.js → subcommands-DmtX9Tyj.js} +4 -4
- package/dist/{ts-Cng1o5fC.js → ts-Bbb1IaDh.js} +2 -2
- package/dist/{versionChecker-CeVZzVQB.js → versionChecker-D-05ZcrY.js} +2 -2
- package/lab/ui/console-logic.js +12 -3
- package/package.json +1 -1
- package/ts/rustBinary.ts +4 -9
- package/ts/serve.ts +18 -2
- package/dist/SUPPORTED_CLIS-BsjC_rd9.js +0 -8
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { t as CLIS_CONFIG } from "./ts-
|
|
1
|
+
import { t as CLIS_CONFIG } from "./ts-Bbb1IaDh.js";
|
|
2
2
|
|
|
3
3
|
//#region ts/SUPPORTED_CLIS.ts
|
|
4
4
|
const SUPPORTED_CLIS = Object.keys(CLIS_CONFIG);
|
|
5
5
|
|
|
6
6
|
//#endregion
|
|
7
7
|
export { SUPPORTED_CLIS as t };
|
|
8
|
-
//# sourceMappingURL=SUPPORTED_CLIS-
|
|
8
|
+
//# sourceMappingURL=SUPPORTED_CLIS-CKqnbe_-.js.map
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import "./ts-Bbb1IaDh.js";
|
|
2
|
+
import "./logger-CDIsZ-Pp.js";
|
|
3
|
+
import "./versionChecker-D-05ZcrY.js";
|
|
4
|
+
import "./pidStore-fqXqTKkh.js";
|
|
5
|
+
import "./globalPidIndex-DlmmJlO8.js";
|
|
6
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-CKqnbe_-.js";
|
|
7
|
+
|
|
8
|
+
export { SUPPORTED_CLIS };
|
package/dist/cli.js
CHANGED
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
#!/usr/bin/env bun
|
|
2
2
|
import { t as invokedCliName } from "./invokedCli-uqM2YYA7.js";
|
|
3
3
|
import { n as logger } from "./logger-CDIsZ-Pp.js";
|
|
4
|
-
import { i as versionString, n as displayVersion, r as getInstalledPackage, t as checkAndAutoUpdate } from "./versionChecker-
|
|
4
|
+
import { i as versionString, n as displayVersion, r as getInstalledPackage, t as checkAndAutoUpdate } from "./versionChecker-D-05ZcrY.js";
|
|
5
5
|
import { argv } from "process";
|
|
6
6
|
import { execFileSync, spawn } from "child_process";
|
|
7
7
|
import ms from "ms";
|
|
@@ -410,16 +410,6 @@ function autoRebuildIfOutdated(binaryPath, verbose) {
|
|
|
410
410
|
stdio: "inherit",
|
|
411
411
|
timeout: 3e5
|
|
412
412
|
});
|
|
413
|
-
try {
|
|
414
|
-
execFileSync("cargo", [
|
|
415
|
-
"install",
|
|
416
|
-
"--path",
|
|
417
|
-
rsDir
|
|
418
|
-
], {
|
|
419
|
-
stdio: "inherit",
|
|
420
|
-
timeout: 6e4
|
|
421
|
-
});
|
|
422
|
-
} catch {}
|
|
423
413
|
process.stderr.write(`\x1b[32m[rust] Rebuild complete\x1b[0m\n`);
|
|
424
414
|
return true;
|
|
425
415
|
} catch {
|
|
@@ -480,7 +470,7 @@ function buildRustArgs(argv, cliFromScript, supportedClis) {
|
|
|
480
470
|
const rawArg = process.argv[2];
|
|
481
471
|
const managerCommands = !invokedCliName(process.argv);
|
|
482
472
|
const isHelpFlag = rawArg === "-h" || rawArg === "--help";
|
|
483
|
-
const { isSubcommand, runSubcommand, cmdHelp } = await import("./subcommands-
|
|
473
|
+
const { isSubcommand, runSubcommand, cmdHelp } = await import("./subcommands-8qtgnf0g.js");
|
|
484
474
|
if (isHelpFlag && process.argv.length === 3) {
|
|
485
475
|
cmdHelp(managerCommands);
|
|
486
476
|
process.exit(0);
|
|
@@ -513,7 +503,7 @@ if (config.useRust) {
|
|
|
513
503
|
}
|
|
514
504
|
}
|
|
515
505
|
if (rustBinary) {
|
|
516
|
-
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-
|
|
506
|
+
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-VRQX4l7K.js");
|
|
517
507
|
const rustArgs = buildRustArgs(process.argv, config.cli, SUPPORTED_CLIS);
|
|
518
508
|
if (config.verbose) {
|
|
519
509
|
console.log(`[rust] Using binary: ${rustBinary}`);
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
|
-
import { a as removeControlCharacters, i as AgentContext, n as agentYes, r as config, t as CLIS_CONFIG } from "./ts-
|
|
1
|
+
import { a as removeControlCharacters, i as AgentContext, n as agentYes, r as config, t as CLIS_CONFIG } from "./ts-Bbb1IaDh.js";
|
|
2
2
|
import "./logger-CDIsZ-Pp.js";
|
|
3
|
-
import "./versionChecker-
|
|
3
|
+
import "./versionChecker-D-05ZcrY.js";
|
|
4
4
|
import "./pidStore-fqXqTKkh.js";
|
|
5
5
|
import "./globalPidIndex-DlmmJlO8.js";
|
|
6
6
|
|
|
@@ -1,9 +1,9 @@
|
|
|
1
|
-
import "./ts-
|
|
1
|
+
import "./ts-Bbb1IaDh.js";
|
|
2
2
|
import "./logger-CDIsZ-Pp.js";
|
|
3
|
-
import "./versionChecker-
|
|
3
|
+
import "./versionChecker-D-05ZcrY.js";
|
|
4
4
|
import "./pidStore-fqXqTKkh.js";
|
|
5
5
|
import "./globalPidIndex-DlmmJlO8.js";
|
|
6
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
6
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-CKqnbe_-.js";
|
|
7
7
|
import { i as resolveSpawnCwd } from "./workspaceConfig-B9VX8tVO.js";
|
|
8
8
|
import { createHash } from "node:crypto";
|
|
9
9
|
|
|
@@ -141,4 +141,4 @@ async function cmdSchedule(rest) {
|
|
|
141
141
|
|
|
142
142
|
//#endregion
|
|
143
143
|
export { cmdSchedule };
|
|
144
|
-
//# sourceMappingURL=schedule-
|
|
144
|
+
//# sourceMappingURL=schedule-CHhOFoc_.js.map
|
|
@@ -1,20 +1,21 @@
|
|
|
1
|
-
import "./ts-
|
|
1
|
+
import "./ts-Bbb1IaDh.js";
|
|
2
2
|
import "./logger-CDIsZ-Pp.js";
|
|
3
|
-
import { r as getInstalledPackage } from "./versionChecker-
|
|
3
|
+
import { r as getInstalledPackage } from "./versionChecker-D-05ZcrY.js";
|
|
4
4
|
import "./pidStore-fqXqTKkh.js";
|
|
5
5
|
import { a as updateGlobalPidStatus } from "./globalPidIndex-DlmmJlO8.js";
|
|
6
6
|
import { t as pgidForWrapper } from "./reaper-C-eWAxIj.js";
|
|
7
7
|
import "./configShared-C1C04bbq.js";
|
|
8
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
8
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-CKqnbe_-.js";
|
|
9
9
|
import "./e2e-ClOI_aqV.js";
|
|
10
10
|
import "./webrtcLink-BWhuA74k.js";
|
|
11
11
|
import "./remotes-qK6uozO4.js";
|
|
12
12
|
import { i as resolveSpawnCwd, r as isProvisionAllowed, t as getProvisionRoot } from "./workspaceConfig-B9VX8tVO.js";
|
|
13
|
-
import { C as snapshotStatus, T as writeToIpc, _ as readPtysize, b as resolveOne, c as extractTaskCounts, g as readNotes, i as controlCodeFromName, m as listRecords, o as deriveLiveStatus, v as renderRawLog } from "./subcommands-
|
|
13
|
+
import { C as snapshotStatus, T as writeToIpc, _ as readPtysize, b as resolveOne, c as extractTaskCounts, g as readNotes, i as controlCodeFromName, m as listRecords, o as deriveLiveStatus, v as renderRawLog } from "./subcommands-DmtX9Tyj.js";
|
|
14
14
|
import yargs from "yargs";
|
|
15
15
|
import { mkdir, open, readFile, stat, writeFile } from "fs/promises";
|
|
16
16
|
import { homedir, hostname, userInfo } from "os";
|
|
17
17
|
import path from "path";
|
|
18
|
+
import { execFileSync } from "node:child_process";
|
|
18
19
|
import { fileURLToPath } from "node:url";
|
|
19
20
|
import { renameSync, watch, writeFileSync } from "node:fs";
|
|
20
21
|
import { randomBytes, timingSafeEqual } from "crypto";
|
|
@@ -774,7 +775,12 @@ Options:
|
|
|
774
775
|
if (req.method === "GET" && p === "/api/whoami") {
|
|
775
776
|
let user = "";
|
|
776
777
|
try {
|
|
777
|
-
|
|
778
|
+
const u = userInfo().username;
|
|
779
|
+
if (u && u !== "unknown") user = u;
|
|
780
|
+
} catch {}
|
|
781
|
+
user ||= process.env.USER || process.env.LOGNAME || process.env.USERNAME || "";
|
|
782
|
+
if (!user && process.platform !== "win32") try {
|
|
783
|
+
user = execFileSync("id", ["-un"], { encoding: "utf8" }).trim();
|
|
778
784
|
} catch {}
|
|
779
785
|
const host = hostname();
|
|
780
786
|
return Response.json({ host: user ? `${user}@${host}` : host });
|
|
@@ -1259,4 +1265,4 @@ Options:
|
|
|
1259
1265
|
|
|
1260
1266
|
//#endregion
|
|
1261
1267
|
export { cmdServe };
|
|
1262
|
-
//# sourceMappingURL=serve-
|
|
1268
|
+
//# sourceMappingURL=serve-D95Tjt_c.js.map
|
|
@@ -32,7 +32,7 @@ async function cmdSetup(rest) {
|
|
|
32
32
|
if (!existsSync(abs)) process.stderr.write(` note: that directory doesn't exist yet — create it, or agents spawned there will fail\n`);
|
|
33
33
|
if (noShare) return 0;
|
|
34
34
|
process.stdout.write(`\nsharing this machine to agent-yes.com…\n`);
|
|
35
|
-
const { cmdServe } = await import("./serve-
|
|
35
|
+
const { cmdServe } = await import("./serve-D95Tjt_c.js");
|
|
36
36
|
return cmdServe([
|
|
37
37
|
"install",
|
|
38
38
|
"--share",
|
|
@@ -42,4 +42,4 @@ async function cmdSetup(rest) {
|
|
|
42
42
|
|
|
43
43
|
//#endregion
|
|
44
44
|
export { cmdSetup };
|
|
45
|
-
//# sourceMappingURL=setup-
|
|
45
|
+
//# sourceMappingURL=setup-BU0hqKTl.js.map
|
|
@@ -4,6 +4,6 @@ import "./configShared-C1C04bbq.js";
|
|
|
4
4
|
import "./e2e-ClOI_aqV.js";
|
|
5
5
|
import "./webrtcLink-BWhuA74k.js";
|
|
6
6
|
import "./remotes-qK6uozO4.js";
|
|
7
|
-
import { C as snapshotStatus, S as runSubcommand, T as writeToIpc, _ as readPtysize, a as cursorAbs, b as resolveOne, c as extractTaskCounts, d as isExitRequest, f as isPidAlive, g as readNotes, h as matchKeyword, i as controlCodeFromName, l as finalizedLines, m as listRecords, n as READ_PAGE_DEFAULT, o as deriveLiveStatus, p as isSubcommand, r as cmdHelp, s as extractNeedsInput, t as GRACEFUL_EXIT_COMMANDS, u as isAgentStuck, v as renderRawLog, w as stopTipForCli, x as resolveReadWindow, y as renderRawLogLines } from "./subcommands-
|
|
7
|
+
import { C as snapshotStatus, S as runSubcommand, T as writeToIpc, _ as readPtysize, a as cursorAbs, b as resolveOne, c as extractTaskCounts, d as isExitRequest, f as isPidAlive, g as readNotes, h as matchKeyword, i as controlCodeFromName, l as finalizedLines, m as listRecords, n as READ_PAGE_DEFAULT, o as deriveLiveStatus, p as isSubcommand, r as cmdHelp, s as extractNeedsInput, t as GRACEFUL_EXIT_COMMANDS, u as isAgentStuck, v as renderRawLog, w as stopTipForCli, x as resolveReadWindow, y as renderRawLogLines } from "./subcommands-DmtX9Tyj.js";
|
|
8
8
|
|
|
9
9
|
export { cmdHelp, isSubcommand, runSubcommand };
|
|
@@ -554,15 +554,15 @@ async function runSubcommand(argv) {
|
|
|
554
554
|
case "restart": return await cmdRestart(rest);
|
|
555
555
|
case "note": return await cmdNote(rest);
|
|
556
556
|
case "serve": {
|
|
557
|
-
const { cmdServe } = await import("./serve-
|
|
557
|
+
const { cmdServe } = await import("./serve-D95Tjt_c.js");
|
|
558
558
|
return cmdServe(rest);
|
|
559
559
|
}
|
|
560
560
|
case "setup": {
|
|
561
|
-
const { cmdSetup } = await import("./setup-
|
|
561
|
+
const { cmdSetup } = await import("./setup-BU0hqKTl.js");
|
|
562
562
|
return cmdSetup(rest);
|
|
563
563
|
}
|
|
564
564
|
case "schedule": {
|
|
565
|
-
const { cmdSchedule } = await import("./schedule-
|
|
565
|
+
const { cmdSchedule } = await import("./schedule-CHhOFoc_.js");
|
|
566
566
|
return cmdSchedule(rest);
|
|
567
567
|
}
|
|
568
568
|
case "remote": {
|
|
@@ -2619,4 +2619,4 @@ async function cmdResultSet(rest) {
|
|
|
2619
2619
|
|
|
2620
2620
|
//#endregion
|
|
2621
2621
|
export { snapshotStatus as C, runSubcommand as S, writeToIpc as T, readPtysize as _, cursorAbs as a, resolveOne as b, extractTaskCounts as c, isExitRequest as d, isPidAlive as f, readNotes as g, matchKeyword as h, controlCodeFromName as i, finalizedLines as l, listRecords as m, READ_PAGE_DEFAULT as n, deriveLiveStatus as o, isSubcommand as p, cmdHelp as r, extractNeedsInput as s, GRACEFUL_EXIT_COMMANDS as t, isAgentStuck as u, renderRawLog as v, stopTipForCli as w, resolveReadWindow as x, renderRawLogLines as y };
|
|
2622
|
-
//# sourceMappingURL=subcommands-
|
|
2622
|
+
//# sourceMappingURL=subcommands-DmtX9Tyj.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { n as logger, t as addTransport } from "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import { r as getInstalledPackage } from "./versionChecker-
|
|
2
|
+
import { r as getInstalledPackage } from "./versionChecker-D-05ZcrY.js";
|
|
3
3
|
import { t as agentYesHome } from "./agentYesHome-_eJa3DaX.js";
|
|
4
4
|
import { i as shouldUseLock, r as releaseLock, t as acquireLock } from "./runningLock-V4qvXgAw.js";
|
|
5
5
|
import { t as PidStore } from "./pidStore-fqXqTKkh.js";
|
|
@@ -1802,4 +1802,4 @@ function sleep(ms) {
|
|
|
1802
1802
|
|
|
1803
1803
|
//#endregion
|
|
1804
1804
|
export { removeControlCharacters as a, AgentContext as i, agentYes as n, config as r, CLIS_CONFIG as t };
|
|
1805
|
-
//# sourceMappingURL=ts-
|
|
1805
|
+
//# sourceMappingURL=ts-Bbb1IaDh.js.map
|
|
@@ -7,7 +7,7 @@ import { fileURLToPath } from "url";
|
|
|
7
7
|
|
|
8
8
|
//#region package.json
|
|
9
9
|
var name = "claude-yes";
|
|
10
|
-
var version = "1.
|
|
10
|
+
var version = "1.151.1";
|
|
11
11
|
|
|
12
12
|
//#endregion
|
|
13
13
|
//#region ts/versionChecker.ts
|
|
@@ -215,4 +215,4 @@ async function displayVersion() {
|
|
|
215
215
|
|
|
216
216
|
//#endregion
|
|
217
217
|
export { versionString as i, displayVersion as n, getInstalledPackage as r, checkAndAutoUpdate as t };
|
|
218
|
-
//# sourceMappingURL=versionChecker-
|
|
218
|
+
//# sourceMappingURL=versionChecker-D-05ZcrY.js.map
|
package/lab/ui/console-logic.js
CHANGED
|
@@ -13,6 +13,14 @@
|
|
|
13
13
|
// common case stays uncluttered and the identity (repo/branch) leads instead.
|
|
14
14
|
export const cliLabel = (e) => (e.cli && e.cli !== "claude" ? e.cli : "");
|
|
15
15
|
|
|
16
|
+
// Windows daemons report cwds with backslashes (C:\Users\…\tree\main); every
|
|
17
|
+
// cwd parser/comparator below assumes forward slashes, so normalize once here.
|
|
18
|
+
// Without this a Windows host's agents parse no owner/repo/branch and render as
|
|
19
|
+
// a bare "user@host://" with no path identity.
|
|
20
|
+
export function normCwd(cwd) {
|
|
21
|
+
return (cwd || "").replace(/\\/g, "/");
|
|
22
|
+
}
|
|
23
|
+
|
|
16
24
|
// Parse owner/repo/branch from a cwd like .../ws/<owner>/<repo>/tree/<branch>.
|
|
17
25
|
// A cwd inside a git submodule keeps trailing path after the worktree branch
|
|
18
26
|
// (e.g. .../tree/share/lib/bot, where lib/bot is a submodule). The owner/repo/
|
|
@@ -21,7 +29,7 @@ export const cliLabel = (e) => (e.cli && e.cli !== "claude" ? e.cli : "");
|
|
|
21
29
|
// leaf dir as `sub` to keep nested repos distinguishable. `sub` is "" when the
|
|
22
30
|
// cwd is the worktree root.
|
|
23
31
|
export function repoBranch(e) {
|
|
24
|
-
const m = /\/([^/]+)\/([^/]+)\/tree\/([^/]+)(\/.*)?$/.exec(e.cwd
|
|
32
|
+
const m = /\/([^/]+)\/([^/]+)\/tree\/([^/]+)(\/.*)?$/.exec(normCwd(e.cwd));
|
|
25
33
|
if (!m) return null;
|
|
26
34
|
const sub = (m[4] || "").split("/").filter(Boolean).pop() || "";
|
|
27
35
|
return { owner: m[1], repo: m[2], branch: m[3], sub };
|
|
@@ -261,13 +269,14 @@ function agentForestNodes(list) {
|
|
|
261
269
|
if (parentOf.has(e) || !e.cwd) continue;
|
|
262
270
|
const rb = repoBranch(e);
|
|
263
271
|
if (!rb) continue;
|
|
272
|
+
const ecwd = normCwd(e.cwd);
|
|
264
273
|
let best = null;
|
|
265
274
|
for (const c of list) {
|
|
266
|
-
if (c === e || !c.cwd || !
|
|
275
|
+
if (c === e || !c.cwd || !ecwd.startsWith(normCwd(c.cwd) + "/")) continue;
|
|
267
276
|
const crb = repoBranch(c);
|
|
268
277
|
if (!crb || crb.owner !== rb.owner || crb.repo !== rb.repo || crb.branch !== rb.branch)
|
|
269
278
|
continue;
|
|
270
|
-
if (!best || c.cwd.length > best.cwd.length) best = c;
|
|
279
|
+
if (!best || normCwd(c.cwd).length > normCwd(best.cwd).length) best = c;
|
|
271
280
|
}
|
|
272
281
|
if (best) parentOf.set(e, best);
|
|
273
282
|
}
|
package/package.json
CHANGED
package/ts/rustBinary.ts
CHANGED
|
@@ -264,15 +264,10 @@ function autoRebuildIfOutdated(binaryPath: string, verbose: boolean): boolean {
|
|
|
264
264
|
stdio: "inherit",
|
|
265
265
|
timeout: 300_000, // 5 min max
|
|
266
266
|
});
|
|
267
|
-
//
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
timeout: 60_000,
|
|
272
|
-
});
|
|
273
|
-
} catch {
|
|
274
|
-
// non-fatal: the target/ binary is already updated
|
|
275
|
-
}
|
|
267
|
+
// Only the target/ binary is rebuilt — we deliberately do NOT `cargo install`
|
|
268
|
+
// a system-wide `agent-yes`. The launcher is the single global command (it's
|
|
269
|
+
// what's linked onto PATH) and it spawns this binary from target/release via
|
|
270
|
+
// findRustBinary(); a cargo-installed `agent-yes` would shadow that launcher.
|
|
276
271
|
process.stderr.write(`\x1b[32m[rust] Rebuild complete\x1b[0m\n`);
|
|
277
272
|
return true;
|
|
278
273
|
} catch {
|
package/ts/serve.ts
CHANGED
|
@@ -1,5 +1,6 @@
|
|
|
1
1
|
import { mkdir, open, readFile, stat, writeFile } from "fs/promises";
|
|
2
2
|
import { renameSync, watch, writeFileSync } from "node:fs";
|
|
3
|
+
import { execFileSync } from "node:child_process";
|
|
3
4
|
import { fileURLToPath } from "node:url";
|
|
4
5
|
import { createHash, randomBytes, timingSafeEqual } from "crypto";
|
|
5
6
|
import { homedir, hostname, userInfo } from "os";
|
|
@@ -1119,9 +1120,24 @@ export async function cmdServe(rest: string[]): Promise<number> {
|
|
|
1119
1120
|
if (req.method === "GET" && p === "/api/whoami") {
|
|
1120
1121
|
let user = "";
|
|
1121
1122
|
try {
|
|
1122
|
-
|
|
1123
|
+
// Bun's userInfo() doesn't always throw on a uid with no /etc/passwd
|
|
1124
|
+
// entry (arbitrary-uid / minimal containers) — it can return the literal
|
|
1125
|
+
// "unknown". Treat that (and "") as a miss so the fallbacks run; without
|
|
1126
|
+
// this a root container surfaced as `unknown@host`, not `root@host`.
|
|
1127
|
+
const u = userInfo().username;
|
|
1128
|
+
if (u && u !== "unknown") user = u;
|
|
1123
1129
|
} catch {
|
|
1124
|
-
/* userInfo
|
|
1130
|
+
/* userInfo can still throw outright on some platforms */
|
|
1131
|
+
}
|
|
1132
|
+
user ||= process.env.USER || process.env.LOGNAME || process.env.USERNAME || "";
|
|
1133
|
+
// Last resort on Unix: resolve the uid against the passwd db directly,
|
|
1134
|
+
// which returns `root` for uid 0 even when the env carries no USER.
|
|
1135
|
+
if (!user && process.platform !== "win32") {
|
|
1136
|
+
try {
|
|
1137
|
+
user = execFileSync("id", ["-un"], { encoding: "utf8" }).trim();
|
|
1138
|
+
} catch {
|
|
1139
|
+
/* no `id` on PATH — leave user blank, host-only label */
|
|
1140
|
+
}
|
|
1125
1141
|
}
|
|
1126
1142
|
const host = hostname();
|
|
1127
1143
|
return Response.json({ host: user ? `${user}@${host}` : host });
|
|
@@ -1,8 +0,0 @@
|
|
|
1
|
-
import "./ts-Cng1o5fC.js";
|
|
2
|
-
import "./logger-CDIsZ-Pp.js";
|
|
3
|
-
import "./versionChecker-CeVZzVQB.js";
|
|
4
|
-
import "./pidStore-fqXqTKkh.js";
|
|
5
|
-
import "./globalPidIndex-DlmmJlO8.js";
|
|
6
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-D8mK1P78.js";
|
|
7
|
-
|
|
8
|
-
export { SUPPORTED_CLIS };
|