agent-yes 1.265.3 → 1.265.4
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-X3jH37iY.js → SUPPORTED_CLIS-C3tcRetU.js} +2 -2
- package/dist/{SUPPORTED_CLIS-DnYyo_km.js → SUPPORTED_CLIS-CY3SaV0D.js} +3 -3
- package/dist/{agentShare-D8Qx06xK.js → agentShare-g6N1A6A_.js} +3 -3
- package/dist/{callback-CByNygd_.js → callback-L4k-v2GG.js} +3 -3
- package/dist/{callback-C5A5zDzb.js → callback-z-w0ND5z.js} +3 -3
- package/dist/cli.js +8 -8
- package/dist/hist-CoXBBjJt.js +442 -0
- package/dist/index.js +2 -2
- package/dist/{nodeRuntime-vhOBffJ3.js → nodeRuntime-CT0w6zsB.js} +1 -1
- package/dist/{notifyDaemon-DuKvOHJJ.js → notifyDaemon-BL1tmxUK.js} +3 -3
- package/dist/{openBrowser-D-aQjh3y.js → openBrowser-Cw8hg7ok.js} +1 -1
- package/dist/{remotes-lOhHSoSS.js → remotes-DWVw-Q7V.js} +1 -1
- package/dist/{remotes-Cn-wszbK.js → remotes-iIvqiFWK.js} +2 -2
- package/dist/{rustBinary-CkTiZVJ4.js → rustBinary-DSVRhDzO.js} +2 -2
- package/dist/{schedule-R6C567wG.js → schedule-i4o5SJ_h.js} +6 -6
- package/dist/{serve-bXCIgnq_.js → serve-CpGJD2Kt.js} +23 -23
- package/dist/{setup-CtUFv2Se.js → setup-B-iQKsQW.js} +4 -4
- package/dist/{spawnGate-D0E1uRP7.js → spawnGate-BmsTv340.js} +2 -2
- package/dist/{spawnGate-DqKBA07k.js → spawnGate-S6EoFdzX.js} +1 -1
- package/dist/{subcommands-Cbhtldub.js → subcommands-CQPnT5qu.js} +22 -18
- package/dist/{subcommands-CnARtyVR.js → subcommands-Cgt2-kjg.js} +2 -2
- package/dist/{systemPathLink-DTAhFXFx.js → systemPathLink-CjLmiPbB.js} +1 -1
- package/dist/{terminal-B8jbz_HG.js → terminal-CybRgMZu.js} +2 -2
- package/dist/{todoCli-CngDeaT2.js → todoCli-DZmOmcvd.js} +1 -1
- package/dist/{tray-wWMvGWeY.js → tray-Cjm3a8JH.js} +1 -1
- package/dist/trayApp-CmwwBg8v.js +5 -0
- package/dist/{trayApp-CZR7Thm6.js → trayApp-UglHbk_m.js} +2 -2
- package/dist/{ts-ZKWh7obB.js → ts-nuUnrVcf.js} +2 -2
- package/dist/{versionChecker-C6RmYXss.js → versionChecker-CMOLbEEi.js} +2 -2
- package/dist/{webrtcRemote-BkZcA5yq.js → webrtcRemote-zQybN9IR.js} +1 -1
- package/dist/{widget-BOcpTCTQ.js → widget-y5Bpvwsa.js} +3 -3
- package/dist/{workspaceConfig-Bxuk_MOq.js → workspaceConfig-BDqp7fYl.js} +1 -1
- package/dist/{ws-CPJxObp_.js → ws-BrLV-AlH.js} +3 -3
- package/dist/{ws-C9NmPMjN.js → ws-CH8GzcQn.js} +3 -3
- package/package.json +1 -1
- package/ts/hist.spec.ts +18 -3
- package/ts/hist.ts +13 -4
- package/ts/subcommands.ts +8 -0
- package/dist/trayApp-Bx0qlt3A.js +0 -5
|
@@ -1,14 +1,14 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import "./versionChecker-
|
|
3
|
-
import "./ts-
|
|
2
|
+
import "./versionChecker-CMOLbEEi.js";
|
|
3
|
+
import "./ts-nuUnrVcf.js";
|
|
4
4
|
import "./todoAutomation-BQRW614S.js";
|
|
5
5
|
import "./JsonlStore-CPGIR0Wy.js";
|
|
6
6
|
import "./globalPidIndex-Dq4KY2IV.js";
|
|
7
7
|
import "./pidStore-DJqSZPJi.js";
|
|
8
8
|
import "./messageLog-BYFwioFY.js";
|
|
9
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
10
|
-
import { f as resolveSpawnCwd } from "./workspaceConfig-
|
|
11
|
-
import { n as liveEnv, t as ensureNodeRuntime } from "./nodeRuntime-
|
|
9
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-C3tcRetU.js";
|
|
10
|
+
import { f as resolveSpawnCwd } from "./workspaceConfig-BDqp7fYl.js";
|
|
11
|
+
import { n as liveEnv, t as ensureNodeRuntime } from "./nodeRuntime-CT0w6zsB.js";
|
|
12
12
|
import { createHash } from "node:crypto";
|
|
13
13
|
|
|
14
14
|
//#region ts/oxmgrService.ts
|
|
@@ -153,4 +153,4 @@ async function cmdSchedule(rest) {
|
|
|
153
153
|
|
|
154
154
|
//#endregion
|
|
155
155
|
export { cmdSchedule };
|
|
156
|
-
//# sourceMappingURL=schedule-
|
|
156
|
+
//# sourceMappingURL=schedule-i4o5SJ_h.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import { r as getInstalledPackage } from "./versionChecker-
|
|
3
|
-
import { t as findSpawnHiddenLauncher } from "./rustBinary-
|
|
4
|
-
import { c as permissionBadge, i as answerAsk, o as listAsks, u as CLAUDE_SESSION_PIN_ENV } from "./ts-
|
|
2
|
+
import { r as getInstalledPackage } from "./versionChecker-CMOLbEEi.js";
|
|
3
|
+
import { t as findSpawnHiddenLauncher } from "./rustBinary-DSVRhDzO.js";
|
|
4
|
+
import { c as permissionBadge, i as answerAsk, o as listAsks, u as CLAUDE_SESSION_PIN_ENV } from "./ts-nuUnrVcf.js";
|
|
5
5
|
import { t as agentYesHome$1 } from "./agentYesHome-CtmsY6I-.js";
|
|
6
6
|
import { x as removeControlCharacters } from "./todoAutomation-BQRW614S.js";
|
|
7
7
|
import "./JsonlStore-CPGIR0Wy.js";
|
|
@@ -11,17 +11,17 @@ import { r as recordInbox } from "./messageLog-BYFwioFY.js";
|
|
|
11
11
|
import { t as pgidForWrapper } from "./reaper-C4BvNylH.js";
|
|
12
12
|
import "./e2e-CUMZC53I.js";
|
|
13
13
|
import "./configShared-DtHMBCl7.js";
|
|
14
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
15
|
-
import { $ as isTransientLockMkdirError, A as readLogForRender, E as listRecords, F as renderLogTailLines, I as renderRawLog, L as renderRawLogLines, M as readPtysize, N as recentMessageEdges, P as recentReadEdges, R as resolveOne, U as snapshotStatus, Y as writeToIpc, c as controlCodeFromName, d as deriveLiveStatus, f as extractBadges, h as extractTaskCounts, j as readNotes, m as extractNeedsInput, st as TYPING_BADGE, w as isUserTyping } from "./subcommands-
|
|
14
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-C3tcRetU.js";
|
|
15
|
+
import { $ as isTransientLockMkdirError, A as readLogForRender, E as listRecords, F as renderLogTailLines, I as renderRawLog, L as renderRawLogLines, M as readPtysize, N as recentMessageEdges, P as recentReadEdges, R as resolveOne, U as snapshotStatus, Y as writeToIpc, c as controlCodeFromName, d as deriveLiveStatus, f as extractBadges, h as extractTaskCounts, j as readNotes, m as extractNeedsInput, st as TYPING_BADGE, w as isUserTyping } from "./subcommands-CQPnT5qu.js";
|
|
16
16
|
import "./webrtcLink-CS4D-3G1.js";
|
|
17
|
-
import "./remotes-
|
|
17
|
+
import "./remotes-iIvqiFWK.js";
|
|
18
18
|
import { i as frameVisitorMessage, s as verifyCapability, t as MAX_CALLBACK_MSG_BYTES } from "./callbackCore-Cg3Ye0ZS.js";
|
|
19
|
-
import { n as isCallbackRevoked, r as loadCallbackSecretReadOnly } from "./callback-
|
|
20
|
-
import { a as getProvisionRoot, d as isProvisionAllowed, f as resolveSpawnCwd, i as getProvisionHook, l as hasProvisionHook, o as getSpawnHook, t as allowsSkipPermissions, u as hasSpawnHook } from "./workspaceConfig-
|
|
21
|
-
import { n as liveEnv, t as ensureNodeRuntime } from "./nodeRuntime-
|
|
22
|
-
import { i as importProvisionModule } from "./ws-
|
|
23
|
-
import { r as spawnRejectionReason } from "./spawnGate-
|
|
24
|
-
import { i as launchTray } from "./trayApp-
|
|
19
|
+
import { n as isCallbackRevoked, r as loadCallbackSecretReadOnly } from "./callback-z-w0ND5z.js";
|
|
20
|
+
import { a as getProvisionRoot, d as isProvisionAllowed, f as resolveSpawnCwd, i as getProvisionHook, l as hasProvisionHook, o as getSpawnHook, t as allowsSkipPermissions, u as hasSpawnHook } from "./workspaceConfig-BDqp7fYl.js";
|
|
21
|
+
import { n as liveEnv, t as ensureNodeRuntime } from "./nodeRuntime-CT0w6zsB.js";
|
|
22
|
+
import { i as importProvisionModule } from "./ws-BrLV-AlH.js";
|
|
23
|
+
import { r as spawnRejectionReason } from "./spawnGate-BmsTv340.js";
|
|
24
|
+
import { i as launchTray } from "./trayApp-UglHbk_m.js";
|
|
25
25
|
import yargs from "yargs";
|
|
26
26
|
import { appendFile, mkdir, open, readFile, readdir, rename, rm, stat, unlink, writeFile } from "fs/promises";
|
|
27
27
|
import { arch, cpus, freemem, homedir, hostname, loadavg, platform, totalmem, uptime, userInfo } from "os";
|
|
@@ -1277,7 +1277,7 @@ async function cmdServeDaemon(sub, args) {
|
|
|
1277
1277
|
if (!webrtcDaemon) return;
|
|
1278
1278
|
if (shareLink) {
|
|
1279
1279
|
process.stdout.write(`\nshared over WebRTC — open this link (the token is eaten from the URL on open):\n ${shareLink}\n` + (shareLinkMinted ? ` (persistent room — same link across restarts; delete ~/.agent-yes/.share-room to rotate)\n` : ``));
|
|
1280
|
-
const { offerOpenInBrowser } = await import("./openBrowser-
|
|
1280
|
+
const { offerOpenInBrowser } = await import("./openBrowser-Cw8hg7ok.js");
|
|
1281
1281
|
await offerOpenInBrowser(shareLink);
|
|
1282
1282
|
} else process.stdout.write("\nthe WebRTC share link carries a secret, so the daemon does NOT log it —\nread it from ~/.agent-yes/.share-link (mode 0600). The room persists in\n~/.agent-yes/.share-room, so the link survives restarts.\n");
|
|
1283
1283
|
};
|
|
@@ -2434,7 +2434,7 @@ Options:
|
|
|
2434
2434
|
}
|
|
2435
2435
|
});
|
|
2436
2436
|
if (req.method === "GET" && p === "/api/ws") {
|
|
2437
|
-
const ws = await import("./ws-
|
|
2437
|
+
const ws = await import("./ws-CH8GzcQn.js");
|
|
2438
2438
|
try {
|
|
2439
2439
|
await ws.loadProvision();
|
|
2440
2440
|
} catch (e) {
|
|
@@ -2454,7 +2454,7 @@ Options:
|
|
|
2454
2454
|
if (req.method === "GET" && p === "/api/ws/status") {
|
|
2455
2455
|
const dirRaw = url.searchParams.get("path");
|
|
2456
2456
|
if (!dirRaw) return new Response("missing ?path=<workspace dir>", { status: 400 });
|
|
2457
|
-
const ws = await import("./ws-
|
|
2457
|
+
const ws = await import("./ws-CH8GzcQn.js");
|
|
2458
2458
|
let prov;
|
|
2459
2459
|
try {
|
|
2460
2460
|
prov = await ws.loadProvision();
|
|
@@ -2476,7 +2476,7 @@ Options:
|
|
|
2476
2476
|
}
|
|
2477
2477
|
}
|
|
2478
2478
|
if (req.method === "GET" && p === "/api/ws/repos") {
|
|
2479
|
-
const ws = await import("./ws-
|
|
2479
|
+
const ws = await import("./ws-CH8GzcQn.js");
|
|
2480
2480
|
try {
|
|
2481
2481
|
await ws.loadProvision();
|
|
2482
2482
|
} catch (e) {
|
|
@@ -2557,7 +2557,7 @@ Options:
|
|
|
2557
2557
|
const m = /^([A-Za-z0-9_.-]+)\/([A-Za-z0-9_.-]+)$/.exec(repoParam);
|
|
2558
2558
|
if (!m || m[1] === "." || m[1] === ".." || m[2] === "." || m[2] === "..") return new Response("missing/invalid ?repo=<owner>/<repo>", { status: 400 });
|
|
2559
2559
|
const [, owner, repo] = m;
|
|
2560
|
-
const ws = await import("./ws-
|
|
2560
|
+
const ws = await import("./ws-CH8GzcQn.js");
|
|
2561
2561
|
let prov;
|
|
2562
2562
|
try {
|
|
2563
2563
|
prov = await ws.loadProvision();
|
|
@@ -3465,7 +3465,7 @@ Options:
|
|
|
3465
3465
|
const perm = body.perm ?? "r";
|
|
3466
3466
|
if (perm !== "r" && perm !== "rw") return new Response(`invalid perm ${perm} (want r or rw)`, { status: 400 });
|
|
3467
3467
|
try {
|
|
3468
|
-
const { createScopedShare } = await import("./agentShare-
|
|
3468
|
+
const { createScopedShare } = await import("./agentShare-g6N1A6A_.js");
|
|
3469
3469
|
const share = await createScopedShare({
|
|
3470
3470
|
agent: body.agent,
|
|
3471
3471
|
perm,
|
|
@@ -3480,12 +3480,12 @@ Options:
|
|
|
3480
3480
|
}
|
|
3481
3481
|
}
|
|
3482
3482
|
if (req.method === "GET" && p === "/api/shares") {
|
|
3483
|
-
const { listShares } = await import("./agentShare-
|
|
3483
|
+
const { listShares } = await import("./agentShare-g6N1A6A_.js");
|
|
3484
3484
|
return Response.json(listShares());
|
|
3485
3485
|
}
|
|
3486
3486
|
const revokeM = /^\/api\/share\/([^/]+)$/.exec(p);
|
|
3487
3487
|
if (req.method === "DELETE" && revokeM) {
|
|
3488
|
-
const { revokeShare } = await import("./agentShare-
|
|
3488
|
+
const { revokeShare } = await import("./agentShare-g6N1A6A_.js");
|
|
3489
3489
|
const ok = revokeShare(decodeURIComponent(revokeM[1]));
|
|
3490
3490
|
return new Response(ok ? "revoked" : "no such share", { status: ok ? 200 : 404 });
|
|
3491
3491
|
}
|
|
@@ -3745,7 +3745,7 @@ Options:
|
|
|
3745
3745
|
const persistNote = explicitUrl ? "\n" : ` (persistent room — same link across restarts; delete ~/.agent-yes/.share-room to rotate)\n\n`;
|
|
3746
3746
|
process.stdout.write(`${wantHttp ? "\n" : ""}${lead}:\n ${link}\n` + persistNote);
|
|
3747
3747
|
if (!rotated) {
|
|
3748
|
-
const { offerOpenInBrowser } = await import("./openBrowser-
|
|
3748
|
+
const { offerOpenInBrowser } = await import("./openBrowser-Cw8hg7ok.js");
|
|
3749
3749
|
await offerOpenInBrowser(link);
|
|
3750
3750
|
}
|
|
3751
3751
|
} else {
|
|
@@ -3787,7 +3787,7 @@ Options:
|
|
|
3787
3787
|
const shutdown = (resolve) => {
|
|
3788
3788
|
if (heartbeat) clearInterval(heartbeat);
|
|
3789
3789
|
closeShare?.();
|
|
3790
|
-
import("./agentShare-
|
|
3790
|
+
import("./agentShare-g6N1A6A_.js").then((m) => m.revokeAllShares()).catch(() => {});
|
|
3791
3791
|
server?.stop();
|
|
3792
3792
|
Promise.resolve(releaseHostLock?.()).catch(() => {}).then(resolve);
|
|
3793
3793
|
};
|
|
@@ -3800,4 +3800,4 @@ Options:
|
|
|
3800
3800
|
|
|
3801
3801
|
//#endregion
|
|
3802
3802
|
export { cmdServe, loadTokenReadOnly, mintScopedTermToken, resolveDaemonHttpBase, resolveLocalServeUrl };
|
|
3803
|
-
//# sourceMappingURL=serve-
|
|
3803
|
+
//# sourceMappingURL=serve-CpGJD2Kt.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { c as getWorkspaceRoot, p as setWorkspaceRoot } from "./workspaceConfig-
|
|
1
|
+
import { c as getWorkspaceRoot, p as setWorkspaceRoot } from "./workspaceConfig-BDqp7fYl.js";
|
|
2
2
|
import { existsSync } from "node:fs";
|
|
3
3
|
import { stdin, stdout } from "node:process";
|
|
4
4
|
import { createInterface } from "node:readline/promises";
|
|
@@ -31,7 +31,7 @@ async function cmdSetup(rest) {
|
|
|
31
31
|
process.stdout.write(`workspace root: ${abs}\n`);
|
|
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
|
try {
|
|
34
|
-
const { linkBunBinsToSystemPath } = await import("./systemPathLink-
|
|
34
|
+
const { linkBunBinsToSystemPath } = await import("./systemPathLink-CjLmiPbB.js");
|
|
35
35
|
const r = linkBunBinsToSystemPath();
|
|
36
36
|
if (r && (r.linked.length || r.refreshed.length)) {
|
|
37
37
|
const n = r.linked.length + r.refreshed.length;
|
|
@@ -40,7 +40,7 @@ async function cmdSetup(rest) {
|
|
|
40
40
|
} catch {}
|
|
41
41
|
if (noShare) return 0;
|
|
42
42
|
process.stdout.write(`\nsharing this machine to agent-yes.com…\n`);
|
|
43
|
-
const { cmdServe } = await import("./serve-
|
|
43
|
+
const { cmdServe } = await import("./serve-CpGJD2Kt.js");
|
|
44
44
|
return cmdServe([
|
|
45
45
|
"install",
|
|
46
46
|
"--share",
|
|
@@ -50,4 +50,4 @@ async function cmdSetup(rest) {
|
|
|
50
50
|
|
|
51
51
|
//#endregion
|
|
52
52
|
export { cmdSetup };
|
|
53
|
-
//# sourceMappingURL=setup-
|
|
53
|
+
//# sourceMappingURL=setup-B-iQKsQW.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { i as readGlobalPids } from "./globalPidIndex-Dq4KY2IV.js";
|
|
2
|
-
import { n as getMaxAgents, r as getMinFreeMb, s as getSpawnWaitMs } from "./workspaceConfig-
|
|
2
|
+
import { n as getMaxAgents, r as getMinFreeMb, s as getSpawnWaitMs } from "./workspaceConfig-BDqp7fYl.js";
|
|
3
3
|
import { readFile } from "fs/promises";
|
|
4
4
|
|
|
5
5
|
//#region ts/spawnGate.ts
|
|
@@ -104,4 +104,4 @@ async function waitForSpawnCapacity(opts) {
|
|
|
104
104
|
|
|
105
105
|
//#endregion
|
|
106
106
|
export { waitForSpawnCapacity as i, spawnGateEnabled as n, spawnRejectionReason as r, memAvailableMb as t };
|
|
107
|
-
//# sourceMappingURL=spawnGate-
|
|
107
|
+
//# sourceMappingURL=spawnGate-BmsTv340.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
2
|
import "./globalPidIndex-Dq4KY2IV.js";
|
|
3
|
-
import { i as waitForSpawnCapacity, n as spawnGateEnabled, r as spawnRejectionReason, t as memAvailableMb } from "./spawnGate-
|
|
3
|
+
import { i as waitForSpawnCapacity, n as spawnGateEnabled, r as spawnRejectionReason, t as memAvailableMb } from "./spawnGate-BmsTv340.js";
|
|
4
4
|
|
|
5
5
|
export { waitForSpawnCapacity };
|
|
@@ -5,7 +5,7 @@ import { a as updateGlobalPidStatus, i as readGlobalPids } from "./globalPidInde
|
|
|
5
5
|
import { a as recordOutbox, i as recordMessage, n as readMailbox, t as partyMatches } from "./messageLog-BYFwioFY.js";
|
|
6
6
|
import { t as loadSharedCliDefaults } from "./configShared-DtHMBCl7.js";
|
|
7
7
|
import { n as isWebrtcSpec } from "./webrtcLink-CS4D-3G1.js";
|
|
8
|
-
import { a as resolveRemoteSpec, i as readRemotes } from "./remotes-
|
|
8
|
+
import { a as resolveRemoteSpec, i as readRemotes } from "./remotes-iIvqiFWK.js";
|
|
9
9
|
import { spawn } from "child_process";
|
|
10
10
|
import ms from "ms";
|
|
11
11
|
import yargs from "yargs";
|
|
@@ -1403,6 +1403,8 @@ const SUBCOMMANDS = new Set([
|
|
|
1403
1403
|
"cat",
|
|
1404
1404
|
"tail",
|
|
1405
1405
|
"head",
|
|
1406
|
+
"hist",
|
|
1407
|
+
"history",
|
|
1406
1408
|
"send",
|
|
1407
1409
|
"msgs",
|
|
1408
1410
|
"key",
|
|
@@ -1528,6 +1530,8 @@ async function runSubcommand(argv) {
|
|
|
1528
1530
|
case "cat": return await cmdRead(rest, { mode: "cat" });
|
|
1529
1531
|
case "tail": return await cmdRead(rest, { mode: "tail" });
|
|
1530
1532
|
case "head": return await cmdRead(rest, { mode: "head" });
|
|
1533
|
+
case "hist":
|
|
1534
|
+
case "history": return await (await import("./hist-CoXBBjJt.js")).cmdHist(rest);
|
|
1531
1535
|
case "send": return await cmdSend(rest);
|
|
1532
1536
|
case "msgs": return await cmdMsgs(rest);
|
|
1533
1537
|
case "key": return await cmdKey(rest);
|
|
@@ -1539,7 +1543,7 @@ async function runSubcommand(argv) {
|
|
|
1539
1543
|
case "restart": return await cmdRestart(rest);
|
|
1540
1544
|
case "note": return await cmdNote(rest);
|
|
1541
1545
|
case "todo": {
|
|
1542
|
-
const { runTodoSubcommand } = await import("./todoCli-
|
|
1546
|
+
const { runTodoSubcommand } = await import("./todoCli-DZmOmcvd.js");
|
|
1543
1547
|
return runTodoSubcommand(rest);
|
|
1544
1548
|
}
|
|
1545
1549
|
case "ch":
|
|
@@ -1548,39 +1552,39 @@ async function runSubcommand(argv) {
|
|
|
1548
1552
|
return cmdCh(rest);
|
|
1549
1553
|
}
|
|
1550
1554
|
case "term": {
|
|
1551
|
-
const { cmdTerm } = await import("./terminal-
|
|
1555
|
+
const { cmdTerm } = await import("./terminal-CybRgMZu.js");
|
|
1552
1556
|
return cmdTerm(rest);
|
|
1553
1557
|
}
|
|
1554
1558
|
case "widget": {
|
|
1555
|
-
const { cmdWidget } = await import("./widget-
|
|
1559
|
+
const { cmdWidget } = await import("./widget-y5Bpvwsa.js");
|
|
1556
1560
|
return cmdWidget(rest);
|
|
1557
1561
|
}
|
|
1558
1562
|
case "mint": {
|
|
1559
|
-
const { cmdMint } = await import("./widget-
|
|
1563
|
+
const { cmdMint } = await import("./widget-y5Bpvwsa.js");
|
|
1560
1564
|
return cmdMint(rest);
|
|
1561
1565
|
}
|
|
1562
1566
|
case "serve": {
|
|
1563
|
-
const { cmdServe } = await import("./serve-
|
|
1567
|
+
const { cmdServe } = await import("./serve-CpGJD2Kt.js");
|
|
1564
1568
|
return cmdServe(rest);
|
|
1565
1569
|
}
|
|
1566
1570
|
case "tray": {
|
|
1567
|
-
const { cmdTray } = await import("./trayApp-
|
|
1571
|
+
const { cmdTray } = await import("./trayApp-CmwwBg8v.js");
|
|
1568
1572
|
return cmdTray(rest);
|
|
1569
1573
|
}
|
|
1570
1574
|
case "setup": {
|
|
1571
|
-
const { cmdSetup } = await import("./setup-
|
|
1575
|
+
const { cmdSetup } = await import("./setup-B-iQKsQW.js");
|
|
1572
1576
|
return cmdSetup(rest);
|
|
1573
1577
|
}
|
|
1574
1578
|
case "ws": {
|
|
1575
|
-
const { cmdWs } = await import("./ws-
|
|
1579
|
+
const { cmdWs } = await import("./ws-CH8GzcQn.js");
|
|
1576
1580
|
return cmdWs(rest);
|
|
1577
1581
|
}
|
|
1578
1582
|
case "schedule": {
|
|
1579
|
-
const { cmdSchedule } = await import("./schedule-
|
|
1583
|
+
const { cmdSchedule } = await import("./schedule-i4o5SJ_h.js");
|
|
1580
1584
|
return cmdSchedule(rest);
|
|
1581
1585
|
}
|
|
1582
1586
|
case "remote": {
|
|
1583
|
-
const { cmdRemote } = await import("./remotes-
|
|
1587
|
+
const { cmdRemote } = await import("./remotes-DWVw-Q7V.js");
|
|
1584
1588
|
return cmdRemote(rest);
|
|
1585
1589
|
}
|
|
1586
1590
|
case "expose": {
|
|
@@ -1588,7 +1592,7 @@ async function runSubcommand(argv) {
|
|
|
1588
1592
|
return cmdExpose(rest);
|
|
1589
1593
|
}
|
|
1590
1594
|
case "callback": {
|
|
1591
|
-
const { cmdCallback } = await import("./callback-
|
|
1595
|
+
const { cmdCallback } = await import("./callback-L4k-v2GG.js");
|
|
1592
1596
|
return cmdCallback(rest);
|
|
1593
1597
|
}
|
|
1594
1598
|
case "reap":
|
|
@@ -1659,7 +1663,7 @@ async function cmdHelp(managerCommands = true) {
|
|
|
1659
1663
|
const wsLines = managerCommands ? " ay ws ls [--status] list <owner>/<repo>/tree/<branch> workspaces\n ay ws new <owner>/<repo>[@branch] clone/refresh a workspace (ay ws help for more)\n" : ``;
|
|
1660
1664
|
const self = process.env.AGENT_YES_PID ? await resolveSender() : null;
|
|
1661
1665
|
const agentSection = self ? await buildAgentContextSection(self) : "";
|
|
1662
|
-
process.stdout.write(agentSection + "ay - agent-yes CLI\n\nManagement:\n ay ls [keyword] list running agents\n ay tail [-f] [-n N] <keyword> last N lines (96), -f to follow\n ay read <keyword> [page opts] paginate: --last/--head N, --range A:B,\n --before-line L [--limit N]\n ay cat <keyword> full log\n ay head <keyword> first N lines\n ay send <keyword> <msg> send a message (keyword '.' = agent in this cwd)\n ay msgs [keyword] [--in|--out] inter-agent message log (sent + received)\n ay ch mk|join|send|read|tail <topic> local-first E2E channels: AI ↔ humans on a topic (ay ch help)\n ay term embed <pid> <script> to embed a live read-only agent terminal in a page (ay term help)\n ay widget ls | read selection|dom read an opted-in page widget's context (selection/DOM) (ay widget help)\n ay mint <target> --caps ... mint a scoped, short-TTL capability token (embeddable in a page)\n ay key <keyword> <key...> send raw keystrokes (down/up/enter/esc/…) — drives menus\n ay select <keyword> <N> pick option N of a needs_input selection menu\n ay attach <keyword> interactive attach (detach: Ctrl-\\)\n ay stop <keyword> graceful shutdown (/exit for claude/codex)\n ay exit <keyword> [reason] graceful shutdown, recording who/why (= 'ay send <kw> exit')\n ay restart <keyword> [--fresh] stop (if live) + relaunch resuming the session; --fresh replays the prompt\n ay status <keyword> agent status snapshot\n ay whoami [--json] (inside an agent) your own registry identity + reply address\n ay result <keyword> [--wait] pull an agent's structured result envelope\n ay result set '<json>' (inside an agent) deposit your result envelope\n ay reap kill process groups leaked by dead agents\n ay deepseek|ds [-- <codex args>] run codex via the local DeepSeek adapter (DEEPSEEK_API_KEY)\n" + wsLines + "\nRemote:\n" + setupLine + " ay schedule <when> <cli> -- <msg> run an agent on a schedule (HH:MM or cron)\n ay serve [--port N] start HTTP API server (prints token)\n ay serve status show serve daemon/server status\n ay remote add <alias> http://<token>@<host>:<port>\n ay remote ls / rm <alias> manage saved remotes\n ay expose <port> share localhost:<port> at https://<id>.agent-yes.com (private link)\n ay callback --expires 7d mint an embeddable message-me widget for one agent\n ay ls <token>@<host>:<port> connect inline (no alias needed)\n ay send <token>@<host>:<port>:<kw> <msg>\n\nRun an agent (naming a CLI is what launches one — bare 'ay' shows this help):\n ay <claude|codex|gemini|...> [options] -- [prompt]\n ay claude -- \"fix the bug in auth.ts\"\n cy [options] -- [prompt] shortcut for 'ay claude' (bare 'cy' starts claude)\n ay claude --help full agent-runner options\n\nLabs (examples at https://github.com/snomiao/agent-yes/tree/main/lab):\n local-role-play/ designer + builder on one machine\n http-remote/ ay serve remote access demo\n p2p-pairing/ libp2p P2P (needs: cargo build --features swarm)\n");
|
|
1666
|
+
process.stdout.write(agentSection + "ay - agent-yes CLI\n\nManagement:\n ay ls [keyword] list running agents\n ay tail [-f] [-n N] <keyword> last N lines (96), -f to follow\n ay read <keyword> [page opts] paginate: --last/--head N, --range A:B,\n --before-line L [--limit N]\n ay cat <keyword> full log\n ay head <keyword> first N lines\n ay hist [-n 6] [--all] [--json] past agent conversations (claude/codex\n transcripts, incl. exited sessions);\n this cwd unless --all\n ay send <keyword> <msg> send a message (keyword '.' = agent in this cwd)\n ay msgs [keyword] [--in|--out] inter-agent message log (sent + received)\n ay ch mk|join|send|read|tail <topic> local-first E2E channels: AI ↔ humans on a topic (ay ch help)\n ay term embed <pid> <script> to embed a live read-only agent terminal in a page (ay term help)\n ay widget ls | read selection|dom read an opted-in page widget's context (selection/DOM) (ay widget help)\n ay mint <target> --caps ... mint a scoped, short-TTL capability token (embeddable in a page)\n ay key <keyword> <key...> send raw keystrokes (down/up/enter/esc/…) — drives menus\n ay select <keyword> <N> pick option N of a needs_input selection menu\n ay attach <keyword> interactive attach (detach: Ctrl-\\)\n ay stop <keyword> graceful shutdown (/exit for claude/codex)\n ay exit <keyword> [reason] graceful shutdown, recording who/why (= 'ay send <kw> exit')\n ay restart <keyword> [--fresh] stop (if live) + relaunch resuming the session; --fresh replays the prompt\n ay status <keyword> agent status snapshot\n ay whoami [--json] (inside an agent) your own registry identity + reply address\n ay result <keyword> [--wait] pull an agent's structured result envelope\n ay result set '<json>' (inside an agent) deposit your result envelope\n ay reap kill process groups leaked by dead agents\n ay deepseek|ds [-- <codex args>] run codex via the local DeepSeek adapter (DEEPSEEK_API_KEY)\n" + wsLines + "\nRemote:\n" + setupLine + " ay schedule <when> <cli> -- <msg> run an agent on a schedule (HH:MM or cron)\n ay serve [--port N] start HTTP API server (prints token)\n ay serve status show serve daemon/server status\n ay remote add <alias> http://<token>@<host>:<port>\n ay remote ls / rm <alias> manage saved remotes\n ay expose <port> share localhost:<port> at https://<id>.agent-yes.com (private link)\n ay callback --expires 7d mint an embeddable message-me widget for one agent\n ay ls <token>@<host>:<port> connect inline (no alias needed)\n ay send <token>@<host>:<port>:<kw> <msg>\n\nRun an agent (naming a CLI is what launches one — bare 'ay' shows this help):\n ay <claude|codex|gemini|...> [options] -- [prompt]\n ay claude -- \"fix the bug in auth.ts\"\n cy [options] -- [prompt] shortcut for 'ay claude' (bare 'cy' starts claude)\n ay claude --help full agent-runner options\n\nLabs (examples at https://github.com/snomiao/agent-yes/tree/main/lab):\n local-role-play/ designer + builder on one machine\n http-remote/ ay serve remote access demo\n p2p-pairing/ libp2p P2P (needs: cargo build --features swarm)\n");
|
|
1663
1667
|
return 0;
|
|
1664
1668
|
}
|
|
1665
1669
|
function matchKeyword(record, keyword) {
|
|
@@ -2039,7 +2043,7 @@ async function fetchRemoteRecordsRaw(url, token, opts) {
|
|
|
2039
2043
|
let base = url;
|
|
2040
2044
|
let bearer = token;
|
|
2041
2045
|
if (isWebrtcSpec(url)) {
|
|
2042
|
-
const { startWebrtcBridge } = await import("./webrtcRemote-
|
|
2046
|
+
const { startWebrtcBridge } = await import("./webrtcRemote-zQybN9IR.js");
|
|
2043
2047
|
bridge = await startWebrtcBridge(url);
|
|
2044
2048
|
base = bridge.baseUrl;
|
|
2045
2049
|
bearer = bridge.token;
|
|
@@ -4076,7 +4080,7 @@ async function cmdAttach(rest) {
|
|
|
4076
4080
|
const winsizeDir = path.join(ayHome, "winsize");
|
|
4077
4081
|
await mkdir(winsizeDir, { recursive: true });
|
|
4078
4082
|
const winsizePath = path.join(winsizeDir, String(record.pid));
|
|
4079
|
-
const { resolveDaemonHttpBase, loadTokenReadOnly } = await import("./serve-
|
|
4083
|
+
const { resolveDaemonHttpBase, loadTokenReadOnly } = await import("./serve-CpGJD2Kt.js");
|
|
4080
4084
|
const daemonBase = await resolveDaemonHttpBase().catch(() => null);
|
|
4081
4085
|
const daemonToken = daemonBase ? await loadTokenReadOnly().catch(() => null) ?? "" : "";
|
|
4082
4086
|
const capViewer = `attach:${process.pid}`;
|
|
@@ -4786,7 +4790,7 @@ async function cmdNotify(rest) {
|
|
|
4786
4790
|
}
|
|
4787
4791
|
const ensure = async () => {
|
|
4788
4792
|
if (!argv["ensure-daemon"]) return;
|
|
4789
|
-
const { ensureDaemon } = await import("./notifyDaemon-
|
|
4793
|
+
const { ensureDaemon } = await import("./notifyDaemon-BL1tmxUK.js");
|
|
4790
4794
|
await ensureDaemon().catch(() => null);
|
|
4791
4795
|
};
|
|
4792
4796
|
await heartbeatWatcher(parent, selfStartedAt);
|
|
@@ -4860,7 +4864,7 @@ async function cmdNotifyCursor(args) {
|
|
|
4860
4864
|
}
|
|
4861
4865
|
async function cmdNotifyd(rest) {
|
|
4862
4866
|
const sub = rest[0] ?? "status";
|
|
4863
|
-
const daemon = await import("./notifyDaemon-
|
|
4867
|
+
const daemon = await import("./notifyDaemon-BL1tmxUK.js");
|
|
4864
4868
|
switch (sub) {
|
|
4865
4869
|
case "run": return daemon.runDaemon();
|
|
4866
4870
|
case "once": return daemon.runDaemon({ once: true });
|
|
@@ -4887,4 +4891,4 @@ async function cmdNotifyd(rest) {
|
|
|
4887
4891
|
|
|
4888
4892
|
//#endregion
|
|
4889
4893
|
export { isTransientLockMkdirError as $, readLogForRender as A, resolveResumeArgs as B, isUnknownManagerToken as C, matchKeyword as D, listRecords as E, renderLogTailLines as F, stopTipForCli as G, runSubcommand as H, renderRawLog as I, writeKeysPaced as J, submitAndConfirm as K, renderRawLogLines as L, readPtysize as M, recentMessageEdges as N, menuSelectKeys as O, recentReadEdges as P, hostId as Q, resolveOne as R, isSubcommand as S, lastStdinAt as T, snapshotStatus as U, restartHintLines as V, stdinActivityPath as W, appendEvent as X, writeToIpc as Y, gcInboxes as Z, isAgentStuck as _, backoffWhileTyping as a, daemonLockOwnerPath as at, isPidAlive as b, controlCodeFromName as c, deriveLiveStatus as d, listInboxParents as et, extractBadges as f, finalizedLines as g, extractTaskCounts as h, TYPING_WINDOW_MS as i, daemonLockDir as it, readNotes as j, readAgentPtysize as k, cursorAbs as l, extractNeedsInput as m, MAX_RENDER_BYTES as n, readInbox as nt, cmdDeepseek as o, notifyDir as ot, extractMenu as p, waitForLogQuiet as q, READ_PAGE_DEFAULT as r, shouldStealLock as rt, cmdHelp as s, TYPING_BADGE as st, GRACEFUL_EXIT_COMMANDS as t, liveWatchers as tt, deriveLiveState as u, isBareManagerInvocation as v, isUserTyping as w, isSlashCommand as x, isExitRequest as y, resolveReadWindow as z };
|
|
4890
|
-
//# sourceMappingURL=subcommands-
|
|
4894
|
+
//# sourceMappingURL=subcommands-CQPnT5qu.js.map
|
|
@@ -3,8 +3,8 @@ import "./globalPidIndex-Dq4KY2IV.js";
|
|
|
3
3
|
import "./messageLog-BYFwioFY.js";
|
|
4
4
|
import "./e2e-CUMZC53I.js";
|
|
5
5
|
import "./configShared-DtHMBCl7.js";
|
|
6
|
-
import { A as readLogForRender, B as resolveResumeArgs, C as isUnknownManagerToken, D as matchKeyword, E as listRecords, F as renderLogTailLines, G as stopTipForCli, H as runSubcommand, I as renderRawLog, J as writeKeysPaced, K as submitAndConfirm, L as renderRawLogLines, M as readPtysize, N as recentMessageEdges, O as menuSelectKeys, P as recentReadEdges, R as resolveOne, S as isSubcommand, T as lastStdinAt, U as snapshotStatus, V as restartHintLines, W as stdinActivityPath, Y as writeToIpc, _ as isAgentStuck, a as backoffWhileTyping, b as isPidAlive, c as controlCodeFromName, d as deriveLiveStatus, f as extractBadges, g as finalizedLines, h as extractTaskCounts, i as TYPING_WINDOW_MS, j as readNotes, k as readAgentPtysize, l as cursorAbs, m as extractNeedsInput, n as MAX_RENDER_BYTES, o as cmdDeepseek, p as extractMenu, q as waitForLogQuiet, r as READ_PAGE_DEFAULT, s as cmdHelp, t as GRACEFUL_EXIT_COMMANDS, u as deriveLiveState, v as isBareManagerInvocation, w as isUserTyping, x as isSlashCommand, y as isExitRequest, z as resolveReadWindow } from "./subcommands-
|
|
6
|
+
import { A as readLogForRender, B as resolveResumeArgs, C as isUnknownManagerToken, D as matchKeyword, E as listRecords, F as renderLogTailLines, G as stopTipForCli, H as runSubcommand, I as renderRawLog, J as writeKeysPaced, K as submitAndConfirm, L as renderRawLogLines, M as readPtysize, N as recentMessageEdges, O as menuSelectKeys, P as recentReadEdges, R as resolveOne, S as isSubcommand, T as lastStdinAt, U as snapshotStatus, V as restartHintLines, W as stdinActivityPath, Y as writeToIpc, _ as isAgentStuck, a as backoffWhileTyping, b as isPidAlive, c as controlCodeFromName, d as deriveLiveStatus, f as extractBadges, g as finalizedLines, h as extractTaskCounts, i as TYPING_WINDOW_MS, j as readNotes, k as readAgentPtysize, l as cursorAbs, m as extractNeedsInput, n as MAX_RENDER_BYTES, o as cmdDeepseek, p as extractMenu, q as waitForLogQuiet, r as READ_PAGE_DEFAULT, s as cmdHelp, t as GRACEFUL_EXIT_COMMANDS, u as deriveLiveState, v as isBareManagerInvocation, w as isUserTyping, x as isSlashCommand, y as isExitRequest, z as resolveReadWindow } from "./subcommands-CQPnT5qu.js";
|
|
7
7
|
import "./webrtcLink-CS4D-3G1.js";
|
|
8
|
-
import "./remotes-
|
|
8
|
+
import "./remotes-iIvqiFWK.js";
|
|
9
9
|
|
|
10
10
|
export { cmdHelp, isBareManagerInvocation, isSubcommand, isUnknownManagerToken, runSubcommand };
|
|
@@ -98,7 +98,7 @@ async function cmdTermMint(args) {
|
|
|
98
98
|
if (flags.ro && flags.interactive) throw new Error("--ro and --interactive are mutually exclusive");
|
|
99
99
|
const ttlSec = parseTtlSec(typeof flags.ttl === "string" ? flags.ttl : "15m");
|
|
100
100
|
const canSend = flags.interactive === true;
|
|
101
|
-
const { mintScopedTermToken } = await import("./serve-
|
|
101
|
+
const { mintScopedTermToken } = await import("./serve-CpGJD2Kt.js");
|
|
102
102
|
const r = await mintScopedTermToken(pid, {
|
|
103
103
|
ttlSec,
|
|
104
104
|
canSend
|
|
@@ -135,4 +135,4 @@ async function cmdTerm(args) {
|
|
|
135
135
|
|
|
136
136
|
//#endregion
|
|
137
137
|
export { cmdTerm };
|
|
138
|
-
//# sourceMappingURL=terminal-
|
|
138
|
+
//# sourceMappingURL=terminal-CybRgMZu.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as findTrayLauncher } from "./rustBinary-
|
|
1
|
+
import { n as findTrayLauncher } from "./rustBinary-DSVRhDzO.js";
|
|
2
2
|
import { t as agentYesHome } from "./agentYesHome-CtmsY6I-.js";
|
|
3
3
|
import { existsSync } from "node:fs";
|
|
4
4
|
import path from "node:path";
|
|
@@ -97,4 +97,4 @@ async function cmdTray(args) {
|
|
|
97
97
|
|
|
98
98
|
//#endregion
|
|
99
99
|
export { trayHiddenMarker as a, launchTray as i, hasDesktop as n, isTrayHidden as r, cmdTray as t };
|
|
100
|
-
//# sourceMappingURL=trayApp-
|
|
100
|
+
//# sourceMappingURL=trayApp-UglHbk_m.js.map
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import { n as __esmMin, r as __exportAll } from "./chunk-cZBX9HZv.js";
|
|
2
2
|
import { n as logger, t as addTransport } from "./logger-CDIsZ-Pp.js";
|
|
3
|
-
import { r as getInstalledPackage } from "./versionChecker-
|
|
3
|
+
import { r as getInstalledPackage } from "./versionChecker-CMOLbEEi.js";
|
|
4
4
|
import { t as agentYesHome } from "./agentYesHome-CtmsY6I-.js";
|
|
5
5
|
import { d as openStore, p as LIFECYCLES, x as removeControlCharacters } from "./todoAutomation-BQRW614S.js";
|
|
6
6
|
import { i as shouldUseLock, r as releaseLock, t as acquireLock } from "./runningLock-DBoONoM-.js";
|
|
@@ -2299,4 +2299,4 @@ function sleep(ms) {
|
|
|
2299
2299
|
|
|
2300
2300
|
//#endregion
|
|
2301
2301
|
export { hasTodoStore as a, permissionBadge as c, answerAsk as i, AgentContext as l, agentYes as n, listAsks as o, config as r, listAsksForProject as s, CLIS_CONFIG as t, CLAUDE_SESSION_PIN_ENV as u };
|
|
2302
|
-
//# sourceMappingURL=ts-
|
|
2302
|
+
//# sourceMappingURL=ts-nuUnrVcf.js.map
|
|
@@ -7,7 +7,7 @@ import { fileURLToPath } from "url";
|
|
|
7
7
|
|
|
8
8
|
//#region package.json
|
|
9
9
|
var name = "agent-yes";
|
|
10
|
-
var version = "1.265.
|
|
10
|
+
var version = "1.265.4";
|
|
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-CMOLbEEi.js.map
|
|
@@ -28,7 +28,7 @@ function parseFlags(args, known) {
|
|
|
28
28
|
}
|
|
29
29
|
/** Resolve the local daemon base URL + token (flags override discovery). */
|
|
30
30
|
async function daemonTarget(flags) {
|
|
31
|
-
const { resolveDaemonHttpBase, loadTokenReadOnly } = await import("./serve-
|
|
31
|
+
const { resolveDaemonHttpBase, loadTokenReadOnly } = await import("./serve-CpGJD2Kt.js");
|
|
32
32
|
const base = typeof flags.base === "string" ? flags.base : await resolveDaemonHttpBase();
|
|
33
33
|
if (!base) throw new Error("no running ay serve daemon found — start `ay serve` or pass --base <url> (e.g. http://127.0.0.1:PORT)");
|
|
34
34
|
const token = typeof flags.token === "string" ? flags.token : await loadTokenReadOnly() ?? "";
|
|
@@ -186,7 +186,7 @@ async function cmdMint(args) {
|
|
|
186
186
|
const bad = caps.filter((c) => !KNOWN_CAPS.has(c));
|
|
187
187
|
if (bad.length) throw new Error(`unknown cap(s): ${bad.join(", ")} (valid: ${[...KNOWN_CAPS].join(", ")})`);
|
|
188
188
|
const ttlSec = parseTtlSec(typeof flags.ttl === "string" ? flags.ttl : "15m");
|
|
189
|
-
const { mintScopedTermToken } = await import("./serve-
|
|
189
|
+
const { mintScopedTermToken } = await import("./serve-CpGJD2Kt.js");
|
|
190
190
|
const r = await mintScopedTermToken(target, {
|
|
191
191
|
ttlSec,
|
|
192
192
|
caps
|
|
@@ -202,4 +202,4 @@ async function cmdMint(args) {
|
|
|
202
202
|
|
|
203
203
|
//#endregion
|
|
204
204
|
export { cmdMint, cmdWidget };
|
|
205
|
-
//# sourceMappingURL=widget-
|
|
205
|
+
//# sourceMappingURL=widget-y5Bpvwsa.js.map
|
|
@@ -215,4 +215,4 @@ function allowsSkipPermissions() {
|
|
|
215
215
|
|
|
216
216
|
//#endregion
|
|
217
217
|
export { getProvisionRoot as a, getWorkspaceRoot as c, isProvisionAllowed as d, resolveSpawnCwd as f, getProvisionHook as i, hasProvisionHook as l, getMaxAgents as n, getSpawnHook as o, setWorkspaceRoot as p, getMinFreeMb as r, getSpawnWaitMs as s, allowsSkipPermissions as t, hasSpawnHook as u };
|
|
218
|
-
//# sourceMappingURL=workspaceConfig-
|
|
218
|
+
//# sourceMappingURL=workspaceConfig-BDqp7fYl.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { E as listRecords } from "./subcommands-
|
|
2
|
-
import { a as getProvisionRoot } from "./workspaceConfig-
|
|
1
|
+
import { E as listRecords } from "./subcommands-CQPnT5qu.js";
|
|
2
|
+
import { a as getProvisionRoot } from "./workspaceConfig-BDqp7fYl.js";
|
|
3
3
|
import { existsSync } from "fs";
|
|
4
4
|
import { lstat, opendir } from "fs/promises";
|
|
5
5
|
import path from "path";
|
|
@@ -426,4 +426,4 @@ async function cmdWs(args) {
|
|
|
426
426
|
|
|
427
427
|
//#endregion
|
|
428
428
|
export { isPathInside as a, walkWorkspaces as c, importProvisionModule as i, workspaceStatus as l, cmdWs as n, loadProvision as o, collectWorkspaces as r, resolveOperand as s, WS_JSON_SCHEMA as t };
|
|
429
|
-
//# sourceMappingURL=ws-
|
|
429
|
+
//# sourceMappingURL=ws-BrLV-AlH.js.map
|
|
@@ -3,9 +3,9 @@ import "./globalPidIndex-Dq4KY2IV.js";
|
|
|
3
3
|
import "./messageLog-BYFwioFY.js";
|
|
4
4
|
import "./e2e-CUMZC53I.js";
|
|
5
5
|
import "./configShared-DtHMBCl7.js";
|
|
6
|
-
import "./subcommands-
|
|
6
|
+
import "./subcommands-CQPnT5qu.js";
|
|
7
7
|
import "./webrtcLink-CS4D-3G1.js";
|
|
8
|
-
import "./remotes-
|
|
9
|
-
import { a as isPathInside, c as walkWorkspaces, i as importProvisionModule, l as workspaceStatus, n as cmdWs, o as loadProvision, r as collectWorkspaces, s as resolveOperand, t as WS_JSON_SCHEMA } from "./ws-
|
|
8
|
+
import "./remotes-iIvqiFWK.js";
|
|
9
|
+
import { a as isPathInside, c as walkWorkspaces, i as importProvisionModule, l as workspaceStatus, n as cmdWs, o as loadProvision, r as collectWorkspaces, s as resolveOperand, t as WS_JSON_SCHEMA } from "./ws-BrLV-AlH.js";
|
|
10
10
|
|
|
11
11
|
export { WS_JSON_SCHEMA, cmdWs, collectWorkspaces, isPathInside, loadProvision, walkWorkspaces, workspaceStatus };
|
package/package.json
CHANGED
package/ts/hist.spec.ts
CHANGED
|
@@ -54,9 +54,9 @@ describe("snippet", () => {
|
|
|
54
54
|
describe("renderRecord", () => {
|
|
55
55
|
it("labels the human as user and the agent by its source", () => {
|
|
56
56
|
expect(renderRecord(rec, { color: false, max: 0 })).toContain("user");
|
|
57
|
-
expect(
|
|
58
|
-
|
|
59
|
-
)
|
|
57
|
+
expect(renderRecord({ ...rec, role: "assistant" }, { color: false, max: 0 })).toContain(
|
|
58
|
+
"claude",
|
|
59
|
+
);
|
|
60
60
|
expect(
|
|
61
61
|
renderRecord({ ...rec, role: "assistant", source: "codex" }, { color: false, max: 0 }),
|
|
62
62
|
).toContain("codex");
|
|
@@ -68,6 +68,21 @@ describe("renderRecord", () => {
|
|
|
68
68
|
expect(/\x1b\[/.test(out)).toBe(false);
|
|
69
69
|
});
|
|
70
70
|
|
|
71
|
+
it("stays ANSI-free when color is off AND the turn is truncated", () => {
|
|
72
|
+
// The truncation note carried hardcoded dim/reset, so `ay hist | cat` leaked
|
|
73
|
+
// escapes on exactly the turns long enough to be shortened. The max:0 case
|
|
74
|
+
// above never truncates, so it cannot catch this.
|
|
75
|
+
const out = renderRecord({ ...rec, text: "x".repeat(900) }, { color: false, max: 600 });
|
|
76
|
+
expect(out).toContain("(+300 chars");
|
|
77
|
+
// eslint-disable-next-line no-control-regex
|
|
78
|
+
expect(/\x1b\[/.test(out)).toBe(false);
|
|
79
|
+
});
|
|
80
|
+
|
|
81
|
+
it("still tints the truncation note when color is on", () => {
|
|
82
|
+
const out = renderRecord({ ...rec, text: "x".repeat(900) }, { color: true, max: 600 });
|
|
83
|
+
expect(out).toContain(`${"\x1b[2m"}(+300 chars`);
|
|
84
|
+
});
|
|
85
|
+
|
|
71
86
|
it("colors user and agent turns differently when color is on", () => {
|
|
72
87
|
const user = renderRecord(rec, { color: true, max: 0 });
|
|
73
88
|
const agent = renderRecord({ ...rec, role: "assistant" }, { color: true, max: 0 });
|
package/ts/hist.ts
CHANGED
|
@@ -28,13 +28,22 @@ function shortTime(ts: string | null): string {
|
|
|
28
28
|
return sameDay ? hhmm : `${d.toISOString().slice(5, 10)} ${hhmm}`;
|
|
29
29
|
}
|
|
30
30
|
|
|
31
|
-
/**
|
|
32
|
-
|
|
31
|
+
/**
|
|
32
|
+
* Collapse a turn to `max` chars, noting how much was withheld.
|
|
33
|
+
*
|
|
34
|
+
* `color` gates the dim tint on that note. Everything else in the renderer
|
|
35
|
+
* already honours it, but this note hardcoded the escapes — so `ay hist | cat`
|
|
36
|
+
* stayed clean only until a turn was long enough to truncate, i.e. the common
|
|
37
|
+
* case. Defaults true so a direct `snippet()` call keeps its old look.
|
|
38
|
+
*/
|
|
39
|
+
export function snippet(text: string, max: number, color = true): string {
|
|
33
40
|
const trimmed = text.trim();
|
|
34
41
|
if (max <= 0 || trimmed.length <= max) return trimmed;
|
|
35
42
|
const head = trimmed.slice(0, max);
|
|
36
43
|
const hiddenLines = trimmed.slice(max).split("\n").length;
|
|
37
|
-
|
|
44
|
+
const dim = color ? DIM : "";
|
|
45
|
+
const off = color ? RESET : "";
|
|
46
|
+
return `${head}… ${dim}(+${trimmed.length - max} chars, ${hiddenLines} more lines)${off}`;
|
|
38
47
|
}
|
|
39
48
|
|
|
40
49
|
export function renderRecord(r: HistRecord, opts: { color: boolean; max: number }): string {
|
|
@@ -42,7 +51,7 @@ export function renderRecord(r: HistRecord, opts: { color: boolean; max: number
|
|
|
42
51
|
const tint = opts.color ? (r.role === "user" ? CYAN : GREEN) : "";
|
|
43
52
|
const dim = opts.color ? DIM : "";
|
|
44
53
|
const off = opts.color ? RESET : "";
|
|
45
|
-
const body = snippet(r.text, opts.max)
|
|
54
|
+
const body = snippet(r.text, opts.max, opts.color)
|
|
46
55
|
.split("\n")
|
|
47
56
|
.map((l) => ` ${l}`)
|
|
48
57
|
.join("\n");
|