agent-yes 1.253.1-beta.602.1 → 1.253.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-Ceu0-pXf.js → SUPPORTED_CLIS-DVSWBBiE.js} +3 -3
- package/dist/{SUPPORTED_CLIS-BV-aHdvI.js → SUPPORTED_CLIS-nQwnN3Up.js} +2 -2
- package/dist/{agentShare-oH2EunVY.js → agentShare-BhHEV1Ts.js} +2 -2
- package/dist/{callback-BYVMtJGd.js → callback-6o6tVezi.js} +2 -2
- package/dist/{callback-Dc901oSh.js → callback-CINvGucS.js} +3 -3
- package/dist/cli.js +5 -5
- package/dist/index.js +2 -2
- package/dist/{notifyDaemon-CVf2__zd.js → notifyDaemon-BEGl3P1o.js} +2 -2
- package/dist/{rustBinary-0QseeYod.js → rustBinary-CTdch_JN.js} +2 -2
- package/dist/{schedule-xV0upo7Y.js → schedule-FN5orHbi.js} +4 -4
- package/dist/{serve-IetelaBt.js → serve-CFn09opX.js} +14 -14
- package/dist/{setup-ocUWNttF.js → setup-DFgCFV89.js} +2 -2
- package/dist/{subcommands-B9LNKzz1.js → subcommands-BqTqhrz1.js} +14 -20
- package/dist/{subcommands-DKxW993O.js → subcommands-eV1RpdlZ.js} +1 -1
- package/dist/{terminal-Ddabl7Rd.js → terminal-CBQPCkBW.js} +2 -2
- package/dist/{trayApp-i1p102VD.js → trayApp-DqnZ0NIu.js} +2 -2
- package/dist/trayApp-IIKYh-U1.js +5 -0
- package/dist/{ts-CyHZlZW6.js → ts-DwRdbutj.js} +2 -2
- package/dist/{versionChecker-DlDcL7wO.js → versionChecker-NNCGAAMY.js} +2 -2
- package/dist/{widget-DDRL6gyD.js → widget-D3py_Par.js} +3 -3
- package/dist/{ws-BHJUZz6e.js → ws-Cp_elVzz.js} +2 -2
- package/lab/ui/index.html +57 -238
- package/package.json +1 -1
- package/ts/subcommands.ts +1 -9
- package/dist/trayApp-oHn-g05d.js +0 -5
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import "./versionChecker-
|
|
3
|
-
import "./ts-
|
|
2
|
+
import "./versionChecker-NNCGAAMY.js";
|
|
3
|
+
import "./ts-DwRdbutj.js";
|
|
4
4
|
import "./todoAutomation-Buo457VO.js";
|
|
5
5
|
import "./JsonlStore-CPGIR0Wy.js";
|
|
6
6
|
import "./globalPidIndex-D9DOSd-c.js";
|
|
7
7
|
import "./pidStore-vnX0bgra.js";
|
|
8
8
|
import "./messageLog-C-YIzhRj.js";
|
|
9
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
9
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-nQwnN3Up.js";
|
|
10
10
|
|
|
11
11
|
export { SUPPORTED_CLIS };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { t as CLIS_CONFIG } from "./ts-
|
|
1
|
+
import { t as CLIS_CONFIG } from "./ts-DwRdbutj.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-nQwnN3Up.js.map
|
|
@@ -3,7 +3,7 @@ import "./globalPidIndex-D9DOSd-c.js";
|
|
|
3
3
|
import "./messageLog-C-YIzhRj.js";
|
|
4
4
|
import "./e2e-CEIdJGZ7.js";
|
|
5
5
|
import "./configShared-IBbnn9b8.js";
|
|
6
|
-
import { P as resolveOne } from "./subcommands-
|
|
6
|
+
import { P as resolveOne } from "./subcommands-BqTqhrz1.js";
|
|
7
7
|
import "./webrtcLink-BMYneHbu.js";
|
|
8
8
|
import "./remotes-a0bGDae9.js";
|
|
9
9
|
import { a as startShare } from "./share-BGl3wutJ.js";
|
|
@@ -229,4 +229,4 @@ function transformEvent(rawEvent, agentId, forwarded) {
|
|
|
229
229
|
|
|
230
230
|
//#endregion
|
|
231
231
|
export { createScopedShare, listShares, revokeAllShares, revokeShare };
|
|
232
|
-
//# sourceMappingURL=agentShare-
|
|
232
|
+
//# sourceMappingURL=agentShare-BhHEV1Ts.js.map
|
|
@@ -3,10 +3,10 @@ import "./globalPidIndex-D9DOSd-c.js";
|
|
|
3
3
|
import "./messageLog-C-YIzhRj.js";
|
|
4
4
|
import "./e2e-CEIdJGZ7.js";
|
|
5
5
|
import "./configShared-IBbnn9b8.js";
|
|
6
|
-
import "./subcommands-
|
|
6
|
+
import "./subcommands-BqTqhrz1.js";
|
|
7
7
|
import "./webrtcLink-BMYneHbu.js";
|
|
8
8
|
import "./remotes-a0bGDae9.js";
|
|
9
9
|
import "./callbackCore-Dd28_cBM.js";
|
|
10
|
-
import { i as loadOrCreateCallbackSecret, n as isCallbackRevoked, r as loadCallbackSecretReadOnly, t as cmdCallback } from "./callback-
|
|
10
|
+
import { i as loadOrCreateCallbackSecret, n as isCallbackRevoked, r as loadCallbackSecretReadOnly, t as cmdCallback } from "./callback-CINvGucS.js";
|
|
11
11
|
|
|
12
12
|
export { cmdCallback };
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as agentYesHome } from "./agentYesHome-CtmsY6I-.js";
|
|
2
|
-
import { P as resolveOne } from "./subcommands-
|
|
2
|
+
import { P as resolveOne } from "./subcommands-BqTqhrz1.js";
|
|
3
3
|
import { a as mintCapability, o as parseExpires } from "./callbackCore-Dd28_cBM.js";
|
|
4
4
|
import { randomBytes } from "node:crypto";
|
|
5
5
|
import { chmodSync, readFileSync, renameSync, writeFileSync } from "node:fs";
|
|
@@ -72,7 +72,7 @@ async function resolveBase(flag) {
|
|
|
72
72
|
if (flag) return flag;
|
|
73
73
|
if (process.env.AGENT_YES_CALLBACK_BASE) return process.env.AGENT_YES_CALLBACK_BASE;
|
|
74
74
|
try {
|
|
75
|
-
const { resolveLocalServeUrl } = await import("./serve-
|
|
75
|
+
const { resolveLocalServeUrl } = await import("./serve-CFn09opX.js");
|
|
76
76
|
const url = await resolveLocalServeUrl();
|
|
77
77
|
if (url) return url;
|
|
78
78
|
} catch {}
|
|
@@ -187,4 +187,4 @@ async function cmdCallback(rest) {
|
|
|
187
187
|
|
|
188
188
|
//#endregion
|
|
189
189
|
export { loadOrCreateCallbackSecret as i, isCallbackRevoked as n, loadCallbackSecretReadOnly as r, cmdCallback as t };
|
|
190
|
-
//# sourceMappingURL=callback-
|
|
190
|
+
//# sourceMappingURL=callback-CINvGucS.js.map
|
package/dist/cli.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
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, t as checkAndAutoUpdate } from "./versionChecker-
|
|
5
|
-
import { r as getRustBinary } from "./rustBinary-
|
|
4
|
+
import { i as versionString, n as displayVersion, t as checkAndAutoUpdate } from "./versionChecker-NNCGAAMY.js";
|
|
5
|
+
import { r as getRustBinary } from "./rustBinary-CTdch_JN.js";
|
|
6
6
|
import { argv } from "process";
|
|
7
7
|
import { spawn } from "child_process";
|
|
8
8
|
import ms from "ms";
|
|
@@ -285,7 +285,7 @@ function buildRustArgs(argv, cliFromScript, supportedClis) {
|
|
|
285
285
|
const rawArg = process.argv[2];
|
|
286
286
|
const managerCommands = !invokedCliName(process.argv);
|
|
287
287
|
const isHelpFlag = rawArg === "-h" || rawArg === "--help";
|
|
288
|
-
const { isSubcommand, runSubcommand, cmdHelp, isUnknownManagerToken } = await import("./subcommands-
|
|
288
|
+
const { isSubcommand, runSubcommand, cmdHelp, isUnknownManagerToken } = await import("./subcommands-eV1RpdlZ.js");
|
|
289
289
|
if (isHelpFlag && process.argv.length === 3) {
|
|
290
290
|
await cmdHelp(managerCommands);
|
|
291
291
|
process.exit(0);
|
|
@@ -295,7 +295,7 @@ function buildRustArgs(argv, cliFromScript, supportedClis) {
|
|
|
295
295
|
process.exit(code ?? 0);
|
|
296
296
|
}
|
|
297
297
|
{
|
|
298
|
-
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-
|
|
298
|
+
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-DVSWBBiE.js");
|
|
299
299
|
if (isUnknownManagerToken(rawArg, managerCommands, SUPPORTED_CLIS)) {
|
|
300
300
|
process.stderr.write(`ay: unknown subcommand or CLI '${rawArg}'.\n See 'ay help' for subcommands. To run an agent, name a CLI:\n 'ay <cli> …' (e.g. 'ay claude …') or 'ay --cli <cli> …'.\n`);
|
|
301
301
|
process.exit(1);
|
|
@@ -346,7 +346,7 @@ if (config.useRust) {
|
|
|
346
346
|
}
|
|
347
347
|
}
|
|
348
348
|
if (rustBinary) {
|
|
349
|
-
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-
|
|
349
|
+
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-DVSWBBiE.js");
|
|
350
350
|
const rustArgs = buildRustArgs(process.argv, config.cli, SUPPORTED_CLIS);
|
|
351
351
|
if (config.verbose) {
|
|
352
352
|
console.log(`[rust] Using binary: ${rustBinary}`);
|
package/dist/index.js
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import "./versionChecker-
|
|
3
|
-
import { a as hasTodoStore, i as answerAsk, l as AgentContext, n as agentYes, o as listAsks, r as config, s as listAsksForProject, t as CLIS_CONFIG } from "./ts-
|
|
2
|
+
import "./versionChecker-NNCGAAMY.js";
|
|
3
|
+
import { a as hasTodoStore, i as answerAsk, l as AgentContext, n as agentYes, o as listAsks, r as config, s as listAsksForProject, t as CLIS_CONFIG } from "./ts-DwRdbutj.js";
|
|
4
4
|
import { _ as isKnownKind, a as renderTree, b as statesOf, c as monitorHint, d as openStore, f as DONE_STATE, g as initialState, h as canTransition, i as renderDigest, l as CycleError, m as ORPHANED_STATE, o as unblockedTasks, p as LIFECYCLES, r as openBlockers, s as describeBlock, t as reconcileTodos, u as TodoStore, v as nextStates, x as removeControlCharacters, y as requiredGate } from "./todoAutomation-Buo457VO.js";
|
|
5
5
|
import "./JsonlStore-CPGIR0Wy.js";
|
|
6
6
|
import "./globalPidIndex-D9DOSd-c.js";
|
|
@@ -3,7 +3,7 @@ import "./globalPidIndex-D9DOSd-c.js";
|
|
|
3
3
|
import "./messageLog-C-YIzhRj.js";
|
|
4
4
|
import "./e2e-CEIdJGZ7.js";
|
|
5
5
|
import "./configShared-IBbnn9b8.js";
|
|
6
|
-
import { $ as shouldStealLock, C as listRecords, J as hostId, K as appendEvent, Q as readInbox, X as listInboxParents, Z as liveWatchers, _ as isPidAlive, c as deriveLiveState, et as daemonLockDir, j as renderLogTailLines, nt as notifyDir, q as gcInboxes, tt as daemonLockOwnerPath } from "./subcommands-
|
|
6
|
+
import { $ as shouldStealLock, C as listRecords, J as hostId, K as appendEvent, Q as readInbox, X as listInboxParents, Z as liveWatchers, _ as isPidAlive, c as deriveLiveState, et as daemonLockDir, j as renderLogTailLines, nt as notifyDir, q as gcInboxes, tt as daemonLockOwnerPath } from "./subcommands-BqTqhrz1.js";
|
|
7
7
|
import "./webrtcLink-BMYneHbu.js";
|
|
8
8
|
import "./remotes-a0bGDae9.js";
|
|
9
9
|
import { mkdir, readFile, rename, rm, stat, writeFile } from "fs/promises";
|
|
@@ -836,4 +836,4 @@ async function ensureDaemon() {
|
|
|
836
836
|
|
|
837
837
|
//#endregion
|
|
838
838
|
export { daemonStatus, ensureDaemon, requestDaemonStop, runDaemon };
|
|
839
|
-
//# sourceMappingURL=notifyDaemon-
|
|
839
|
+
//# sourceMappingURL=notifyDaemon-BEGl3P1o.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { r as getInstalledPackage } from "./versionChecker-
|
|
1
|
+
import { r as getInstalledPackage } from "./versionChecker-NNCGAAMY.js";
|
|
2
2
|
import { execFileSync } from "child_process";
|
|
3
3
|
import { existsSync, mkdirSync, unlinkSync } from "fs";
|
|
4
4
|
import { chmod, copyFile } from "fs/promises";
|
|
@@ -243,4 +243,4 @@ async function getRustBinary(options = {}) {
|
|
|
243
243
|
|
|
244
244
|
//#endregion
|
|
245
245
|
export { findTrayLauncher as n, getRustBinary as r, findSpawnHiddenLauncher as t };
|
|
246
|
-
//# sourceMappingURL=rustBinary-
|
|
246
|
+
//# sourceMappingURL=rustBinary-CTdch_JN.js.map
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import "./versionChecker-
|
|
3
|
-
import "./ts-
|
|
2
|
+
import "./versionChecker-NNCGAAMY.js";
|
|
3
|
+
import "./ts-DwRdbutj.js";
|
|
4
4
|
import "./todoAutomation-Buo457VO.js";
|
|
5
5
|
import "./JsonlStore-CPGIR0Wy.js";
|
|
6
6
|
import "./globalPidIndex-D9DOSd-c.js";
|
|
7
7
|
import "./pidStore-vnX0bgra.js";
|
|
8
8
|
import "./messageLog-C-YIzhRj.js";
|
|
9
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
9
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-nQwnN3Up.js";
|
|
10
10
|
import { f as resolveSpawnCwd } from "./workspaceConfig-CpilQzMY.js";
|
|
11
11
|
import { n as liveEnv, t as ensureNodeRuntime } from "./nodeRuntime-BtL6Oo1o.js";
|
|
12
12
|
import { createHash } from "node:crypto";
|
|
@@ -153,4 +153,4 @@ async function cmdSchedule(rest) {
|
|
|
153
153
|
|
|
154
154
|
//#endregion
|
|
155
155
|
export { cmdSchedule };
|
|
156
|
-
//# sourceMappingURL=schedule-
|
|
156
|
+
//# sourceMappingURL=schedule-FN5orHbi.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-NNCGAAMY.js";
|
|
3
|
+
import { t as findSpawnHiddenLauncher } from "./rustBinary-CTdch_JN.js";
|
|
4
|
+
import { c as permissionBadge, i as answerAsk, o as listAsks, u as CLAUDE_SESSION_PIN_ENV } from "./ts-DwRdbutj.js";
|
|
5
5
|
import { t as agentYesHome$1 } from "./agentYesHome-CtmsY6I-.js";
|
|
6
6
|
import { x as removeControlCharacters } from "./todoAutomation-Buo457VO.js";
|
|
7
7
|
import "./JsonlStore-CPGIR0Wy.js";
|
|
@@ -11,16 +11,16 @@ import { r as recordInbox } from "./messageLog-C-YIzhRj.js";
|
|
|
11
11
|
import { t as pgidForWrapper } from "./reaper-DP49VCKx.js";
|
|
12
12
|
import "./e2e-CEIdJGZ7.js";
|
|
13
13
|
import "./configShared-IBbnn9b8.js";
|
|
14
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
15
|
-
import { A as recentReadEdges, C as listRecords, D as readNotes, G as writeToIpc, M as renderRawLog, N as renderRawLogLines, O as readPtysize, P as resolveOne, Y as isTransientLockMkdirError, f as extractNeedsInput, j as renderLogTailLines, k as recentMessageEdges, l as deriveLiveStatus, o as controlCodeFromName, p as extractTaskCounts, rt as TYPING_BADGE, u as extractBadges, x as isUserTyping, z as snapshotStatus } from "./subcommands-
|
|
14
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-nQwnN3Up.js";
|
|
15
|
+
import { A as recentReadEdges, C as listRecords, D as readNotes, G as writeToIpc, M as renderRawLog, N as renderRawLogLines, O as readPtysize, P as resolveOne, Y as isTransientLockMkdirError, f as extractNeedsInput, j as renderLogTailLines, k as recentMessageEdges, l as deriveLiveStatus, o as controlCodeFromName, p as extractTaskCounts, rt as TYPING_BADGE, u as extractBadges, x as isUserTyping, z as snapshotStatus } from "./subcommands-BqTqhrz1.js";
|
|
16
16
|
import "./webrtcLink-BMYneHbu.js";
|
|
17
17
|
import "./remotes-a0bGDae9.js";
|
|
18
18
|
import { i as frameVisitorMessage, s as verifyCapability, t as MAX_CALLBACK_MSG_BYTES } from "./callbackCore-Dd28_cBM.js";
|
|
19
|
-
import { n as isCallbackRevoked, r as loadCallbackSecretReadOnly } from "./callback-
|
|
19
|
+
import { n as isCallbackRevoked, r as loadCallbackSecretReadOnly } from "./callback-CINvGucS.js";
|
|
20
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-CpilQzMY.js";
|
|
21
21
|
import { n as liveEnv, t as ensureNodeRuntime } from "./nodeRuntime-BtL6Oo1o.js";
|
|
22
22
|
import { r as spawnRejectionReason } from "./spawnGate-BFJPdHCQ.js";
|
|
23
|
-
import { i as launchTray } from "./trayApp-
|
|
23
|
+
import { i as launchTray } from "./trayApp-DqnZ0NIu.js";
|
|
24
24
|
import yargs from "yargs";
|
|
25
25
|
import { appendFile, mkdir, open, readFile, readdir, rename, rm, stat, unlink, writeFile } from "fs/promises";
|
|
26
26
|
import { arch, cpus, freemem, homedir, hostname, loadavg, platform, totalmem, uptime, userInfo } from "os";
|
|
@@ -2367,7 +2367,7 @@ Options:
|
|
|
2367
2367
|
}
|
|
2368
2368
|
});
|
|
2369
2369
|
if (req.method === "GET" && p === "/api/ws") {
|
|
2370
|
-
const ws = await import("./ws-
|
|
2370
|
+
const ws = await import("./ws-Cp_elVzz.js");
|
|
2371
2371
|
try {
|
|
2372
2372
|
await ws.loadProvision();
|
|
2373
2373
|
} catch (e) {
|
|
@@ -2387,7 +2387,7 @@ Options:
|
|
|
2387
2387
|
if (req.method === "GET" && p === "/api/ws/status") {
|
|
2388
2388
|
const dirRaw = url.searchParams.get("path");
|
|
2389
2389
|
if (!dirRaw) return new Response("missing ?path=<workspace dir>", { status: 400 });
|
|
2390
|
-
const ws = await import("./ws-
|
|
2390
|
+
const ws = await import("./ws-Cp_elVzz.js");
|
|
2391
2391
|
let prov;
|
|
2392
2392
|
try {
|
|
2393
2393
|
prov = await ws.loadProvision();
|
|
@@ -3144,7 +3144,7 @@ Options:
|
|
|
3144
3144
|
const perm = body.perm ?? "r";
|
|
3145
3145
|
if (perm !== "r" && perm !== "rw") return new Response(`invalid perm ${perm} (want r or rw)`, { status: 400 });
|
|
3146
3146
|
try {
|
|
3147
|
-
const { createScopedShare } = await import("./agentShare-
|
|
3147
|
+
const { createScopedShare } = await import("./agentShare-BhHEV1Ts.js");
|
|
3148
3148
|
const share = await createScopedShare({
|
|
3149
3149
|
agent: body.agent,
|
|
3150
3150
|
perm,
|
|
@@ -3159,12 +3159,12 @@ Options:
|
|
|
3159
3159
|
}
|
|
3160
3160
|
}
|
|
3161
3161
|
if (req.method === "GET" && p === "/api/shares") {
|
|
3162
|
-
const { listShares } = await import("./agentShare-
|
|
3162
|
+
const { listShares } = await import("./agentShare-BhHEV1Ts.js");
|
|
3163
3163
|
return Response.json(listShares());
|
|
3164
3164
|
}
|
|
3165
3165
|
const revokeM = /^\/api\/share\/([^/]+)$/.exec(p);
|
|
3166
3166
|
if (req.method === "DELETE" && revokeM) {
|
|
3167
|
-
const { revokeShare } = await import("./agentShare-
|
|
3167
|
+
const { revokeShare } = await import("./agentShare-BhHEV1Ts.js");
|
|
3168
3168
|
const ok = revokeShare(decodeURIComponent(revokeM[1]));
|
|
3169
3169
|
return new Response(ok ? "revoked" : "no such share", { status: ok ? 200 : 404 });
|
|
3170
3170
|
}
|
|
@@ -3466,7 +3466,7 @@ Options:
|
|
|
3466
3466
|
const shutdown = (resolve) => {
|
|
3467
3467
|
if (heartbeat) clearInterval(heartbeat);
|
|
3468
3468
|
closeShare?.();
|
|
3469
|
-
import("./agentShare-
|
|
3469
|
+
import("./agentShare-BhHEV1Ts.js").then((m) => m.revokeAllShares()).catch(() => {});
|
|
3470
3470
|
server?.stop();
|
|
3471
3471
|
Promise.resolve(releaseHostLock?.()).catch(() => {}).then(resolve);
|
|
3472
3472
|
};
|
|
@@ -3479,4 +3479,4 @@ Options:
|
|
|
3479
3479
|
|
|
3480
3480
|
//#endregion
|
|
3481
3481
|
export { cmdServe, loadTokenReadOnly, mintScopedTermToken, resolveDaemonHttpBase, resolveLocalServeUrl };
|
|
3482
|
-
//# sourceMappingURL=serve-
|
|
3482
|
+
//# sourceMappingURL=serve-CFn09opX.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-CFn09opX.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-DFgCFV89.js.map
|
|
@@ -1340,35 +1340,35 @@ async function runSubcommand(argv) {
|
|
|
1340
1340
|
return cmdCh(rest);
|
|
1341
1341
|
}
|
|
1342
1342
|
case "term": {
|
|
1343
|
-
const { cmdTerm } = await import("./terminal-
|
|
1343
|
+
const { cmdTerm } = await import("./terminal-CBQPCkBW.js");
|
|
1344
1344
|
return cmdTerm(rest);
|
|
1345
1345
|
}
|
|
1346
1346
|
case "widget": {
|
|
1347
|
-
const { cmdWidget } = await import("./widget-
|
|
1347
|
+
const { cmdWidget } = await import("./widget-D3py_Par.js");
|
|
1348
1348
|
return cmdWidget(rest);
|
|
1349
1349
|
}
|
|
1350
1350
|
case "mint": {
|
|
1351
|
-
const { cmdMint } = await import("./widget-
|
|
1351
|
+
const { cmdMint } = await import("./widget-D3py_Par.js");
|
|
1352
1352
|
return cmdMint(rest);
|
|
1353
1353
|
}
|
|
1354
1354
|
case "serve": {
|
|
1355
|
-
const { cmdServe } = await import("./serve-
|
|
1355
|
+
const { cmdServe } = await import("./serve-CFn09opX.js");
|
|
1356
1356
|
return cmdServe(rest);
|
|
1357
1357
|
}
|
|
1358
1358
|
case "tray": {
|
|
1359
|
-
const { cmdTray } = await import("./trayApp-
|
|
1359
|
+
const { cmdTray } = await import("./trayApp-IIKYh-U1.js");
|
|
1360
1360
|
return cmdTray(rest);
|
|
1361
1361
|
}
|
|
1362
1362
|
case "setup": {
|
|
1363
|
-
const { cmdSetup } = await import("./setup-
|
|
1363
|
+
const { cmdSetup } = await import("./setup-DFgCFV89.js");
|
|
1364
1364
|
return cmdSetup(rest);
|
|
1365
1365
|
}
|
|
1366
1366
|
case "ws": {
|
|
1367
|
-
const { cmdWs } = await import("./ws-
|
|
1367
|
+
const { cmdWs } = await import("./ws-Cp_elVzz.js");
|
|
1368
1368
|
return cmdWs(rest);
|
|
1369
1369
|
}
|
|
1370
1370
|
case "schedule": {
|
|
1371
|
-
const { cmdSchedule } = await import("./schedule-
|
|
1371
|
+
const { cmdSchedule } = await import("./schedule-FN5orHbi.js");
|
|
1372
1372
|
return cmdSchedule(rest);
|
|
1373
1373
|
}
|
|
1374
1374
|
case "remote": {
|
|
@@ -1380,7 +1380,7 @@ async function runSubcommand(argv) {
|
|
|
1380
1380
|
return cmdExpose(rest);
|
|
1381
1381
|
}
|
|
1382
1382
|
case "callback": {
|
|
1383
|
-
const { cmdCallback } = await import("./callback-
|
|
1383
|
+
const { cmdCallback } = await import("./callback-6o6tVezi.js");
|
|
1384
1384
|
return cmdCallback(rest);
|
|
1385
1385
|
}
|
|
1386
1386
|
case "reap":
|
|
@@ -3150,11 +3150,6 @@ async function cmdSend(rest) {
|
|
|
3150
3150
|
default: false,
|
|
3151
3151
|
alias: "async",
|
|
3152
3152
|
description: "Fire-and-forget: skip the paste-settle wait and submit confirmation, don't retry a swallowed Enter (also: AGENT_YES_SEND_NO_WAIT=1)"
|
|
3153
|
-
}).option("raw", {
|
|
3154
|
-
type: "boolean",
|
|
3155
|
-
default: false,
|
|
3156
|
-
alias: "no-wrap",
|
|
3157
|
-
description: "Send the body verbatim: omit the <ay-msg …> attribution wrapper that agent senders add by default (also: AGENT_YES_SEND_RAW=1)"
|
|
3158
3153
|
}).help(false).version(false).exitProcess(false).parseAsync();
|
|
3159
3154
|
const opts = {
|
|
3160
3155
|
all: argv.all,
|
|
@@ -3183,7 +3178,6 @@ async function cmdSend(rest) {
|
|
|
3183
3178
|
body = Buffer.concat(chunks).toString("utf-8").trimEnd();
|
|
3184
3179
|
} else body = rawMessage;
|
|
3185
3180
|
const force = Boolean(argv.force) || process.env.AGENT_YES_FORCE_SEND === "1";
|
|
3186
|
-
const raw = Boolean(argv.raw) || process.env.AGENT_YES_SEND_RAW === "1";
|
|
3187
3181
|
const sender = await enforceSendGuards(record, force);
|
|
3188
3182
|
if (isExitRequest(body)) {
|
|
3189
3183
|
const reason = sender.agent ? `requested by ${sender.agent.cli} #${sender.agent.pid} @ ${shortenPath(sender.agent.cwd)}` : `requested via 'ay send ${keyword} exit'`;
|
|
@@ -3195,7 +3189,7 @@ async function cmdSend(rest) {
|
|
|
3195
3189
|
let prefix = "";
|
|
3196
3190
|
let suffix = "";
|
|
3197
3191
|
let nonce;
|
|
3198
|
-
if (sender.agent && !isSlashCommand(body)
|
|
3192
|
+
if (sender.agent && !isSlashCommand(body)) {
|
|
3199
3193
|
nonce = randomBytes$1(4).toString("hex");
|
|
3200
3194
|
prefix = `<ay-msg ${nonce} from ${sender.agent.cli} #${sender.agent.pid} @ ${shortenPath(sender.agent.cwd)} — reply: ay send ${replyTarget} "...">\n`;
|
|
3201
3195
|
suffix = `\n</ay-msg ${nonce}>`;
|
|
@@ -3789,7 +3783,7 @@ async function cmdAttach(rest) {
|
|
|
3789
3783
|
const winsizeDir = path.join(ayHome, "winsize");
|
|
3790
3784
|
await mkdir(winsizeDir, { recursive: true });
|
|
3791
3785
|
const winsizePath = path.join(winsizeDir, String(record.pid));
|
|
3792
|
-
const { resolveDaemonHttpBase, loadTokenReadOnly } = await import("./serve-
|
|
3786
|
+
const { resolveDaemonHttpBase, loadTokenReadOnly } = await import("./serve-CFn09opX.js");
|
|
3793
3787
|
const daemonBase = await resolveDaemonHttpBase().catch(() => null);
|
|
3794
3788
|
const daemonToken = daemonBase ? await loadTokenReadOnly().catch(() => null) ?? "" : "";
|
|
3795
3789
|
const capViewer = `attach:${process.pid}`;
|
|
@@ -4499,7 +4493,7 @@ async function cmdNotify(rest) {
|
|
|
4499
4493
|
}
|
|
4500
4494
|
const ensure = async () => {
|
|
4501
4495
|
if (!argv["ensure-daemon"]) return;
|
|
4502
|
-
const { ensureDaemon } = await import("./notifyDaemon-
|
|
4496
|
+
const { ensureDaemon } = await import("./notifyDaemon-BEGl3P1o.js");
|
|
4503
4497
|
await ensureDaemon().catch(() => null);
|
|
4504
4498
|
};
|
|
4505
4499
|
await heartbeatWatcher(parent, selfStartedAt);
|
|
@@ -4573,7 +4567,7 @@ async function cmdNotifyCursor(args) {
|
|
|
4573
4567
|
}
|
|
4574
4568
|
async function cmdNotifyd(rest) {
|
|
4575
4569
|
const sub = rest[0] ?? "status";
|
|
4576
|
-
const daemon = await import("./notifyDaemon-
|
|
4570
|
+
const daemon = await import("./notifyDaemon-BEGl3P1o.js");
|
|
4577
4571
|
switch (sub) {
|
|
4578
4572
|
case "run": return daemon.runDaemon();
|
|
4579
4573
|
case "once": return daemon.runDaemon({ once: true });
|
|
@@ -4600,4 +4594,4 @@ async function cmdNotifyd(rest) {
|
|
|
4600
4594
|
|
|
4601
4595
|
//#endregion
|
|
4602
4596
|
export { shouldStealLock as $, recentReadEdges as A, stdinActivityPath as B, listRecords as C, readNotes as D, readAgentPtysize as E, resolveReadWindow as F, writeToIpc as G, submitAndConfirm as H, resolveResumeArgs as I, hostId as J, appendEvent as K, restartHintLines as L, renderRawLog as M, renderRawLogLines as N, readPtysize as O, resolveOne as P, readInbox as Q, runSubcommand as R, lastStdinAt as S, menuSelectKeys as T, waitForLogQuiet as U, stopTipForCli as V, writeKeysPaced as W, listInboxParents as X, isTransientLockMkdirError as Y, liveWatchers as Z, isPidAlive as _, cmdHelp as a, isUnknownManagerToken as b, deriveLiveState as c, extractMenu as d, daemonLockDir as et, extractNeedsInput as f, isExitRequest as g, isAgentStuck as h, backoffWhileTyping as i, renderLogTailLines as j, recentMessageEdges as k, deriveLiveStatus as l, finalizedLines as m, READ_PAGE_DEFAULT as n, notifyDir as nt, controlCodeFromName as o, extractTaskCounts as p, gcInboxes as q, TYPING_WINDOW_MS as r, TYPING_BADGE as rt, cursorAbs as s, GRACEFUL_EXIT_COMMANDS as t, daemonLockOwnerPath as tt, extractBadges as u, isSlashCommand as v, matchKeyword as w, isUserTyping as x, isSubcommand as y, snapshotStatus as z };
|
|
4603
|
-
//# sourceMappingURL=subcommands-
|
|
4597
|
+
//# sourceMappingURL=subcommands-BqTqhrz1.js.map
|
|
@@ -3,7 +3,7 @@ import "./globalPidIndex-D9DOSd-c.js";
|
|
|
3
3
|
import "./messageLog-C-YIzhRj.js";
|
|
4
4
|
import "./e2e-CEIdJGZ7.js";
|
|
5
5
|
import "./configShared-IBbnn9b8.js";
|
|
6
|
-
import { A as recentReadEdges, B as stdinActivityPath, C as listRecords, D as readNotes, E as readAgentPtysize, F as resolveReadWindow, G as writeToIpc, H as submitAndConfirm, I as resolveResumeArgs, L as restartHintLines, M as renderRawLog, N as renderRawLogLines, O as readPtysize, P as resolveOne, R as runSubcommand, S as lastStdinAt, T as menuSelectKeys, U as waitForLogQuiet, V as stopTipForCli, W as writeKeysPaced, _ as isPidAlive, a as cmdHelp, b as isUnknownManagerToken, c as deriveLiveState, d as extractMenu, f as extractNeedsInput, g as isExitRequest, h as isAgentStuck, i as backoffWhileTyping, j as renderLogTailLines, k as recentMessageEdges, l as deriveLiveStatus, m as finalizedLines, n as READ_PAGE_DEFAULT, o as controlCodeFromName, p as extractTaskCounts, r as TYPING_WINDOW_MS, s as cursorAbs, t as GRACEFUL_EXIT_COMMANDS, u as extractBadges, v as isSlashCommand, w as matchKeyword, x as isUserTyping, y as isSubcommand, z as snapshotStatus } from "./subcommands-
|
|
6
|
+
import { A as recentReadEdges, B as stdinActivityPath, C as listRecords, D as readNotes, E as readAgentPtysize, F as resolveReadWindow, G as writeToIpc, H as submitAndConfirm, I as resolveResumeArgs, L as restartHintLines, M as renderRawLog, N as renderRawLogLines, O as readPtysize, P as resolveOne, R as runSubcommand, S as lastStdinAt, T as menuSelectKeys, U as waitForLogQuiet, V as stopTipForCli, W as writeKeysPaced, _ as isPidAlive, a as cmdHelp, b as isUnknownManagerToken, c as deriveLiveState, d as extractMenu, f as extractNeedsInput, g as isExitRequest, h as isAgentStuck, i as backoffWhileTyping, j as renderLogTailLines, k as recentMessageEdges, l as deriveLiveStatus, m as finalizedLines, n as READ_PAGE_DEFAULT, o as controlCodeFromName, p as extractTaskCounts, r as TYPING_WINDOW_MS, s as cursorAbs, t as GRACEFUL_EXIT_COMMANDS, u as extractBadges, v as isSlashCommand, w as matchKeyword, x as isUserTyping, y as isSubcommand, z as snapshotStatus } from "./subcommands-BqTqhrz1.js";
|
|
7
7
|
import "./webrtcLink-BMYneHbu.js";
|
|
8
8
|
import "./remotes-a0bGDae9.js";
|
|
9
9
|
|
|
@@ -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-CFn09opX.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-CBQPCkBW.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { n as findTrayLauncher } from "./rustBinary-
|
|
1
|
+
import { n as findTrayLauncher } from "./rustBinary-CTdch_JN.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-DqnZ0NIu.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-NNCGAAMY.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-Buo457VO.js";
|
|
6
6
|
import { i as shouldUseLock, r as releaseLock, t as acquireLock } from "./runningLock-DBoONoM-.js";
|
|
@@ -2155,4 +2155,4 @@ function sleep(ms) {
|
|
|
2155
2155
|
|
|
2156
2156
|
//#endregion
|
|
2157
2157
|
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 };
|
|
2158
|
-
//# sourceMappingURL=ts-
|
|
2158
|
+
//# sourceMappingURL=ts-DwRdbutj.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.253.1
|
|
10
|
+
var version = "1.253.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-NNCGAAMY.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-CFn09opX.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-CFn09opX.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-D3py_Par.js.map
|
|
@@ -3,7 +3,7 @@ import "./globalPidIndex-D9DOSd-c.js";
|
|
|
3
3
|
import "./messageLog-C-YIzhRj.js";
|
|
4
4
|
import "./e2e-CEIdJGZ7.js";
|
|
5
5
|
import "./configShared-IBbnn9b8.js";
|
|
6
|
-
import { C as listRecords } from "./subcommands-
|
|
6
|
+
import { C as listRecords } from "./subcommands-BqTqhrz1.js";
|
|
7
7
|
import "./webrtcLink-BMYneHbu.js";
|
|
8
8
|
import "./remotes-a0bGDae9.js";
|
|
9
9
|
import { a as getProvisionRoot } from "./workspaceConfig-CpilQzMY.js";
|
|
@@ -418,4 +418,4 @@ async function cmdWs(args) {
|
|
|
418
418
|
|
|
419
419
|
//#endregion
|
|
420
420
|
export { WS_JSON_SCHEMA, cmdWs, collectWorkspaces, isPathInside, loadProvision, workspaceStatus };
|
|
421
|
-
//# sourceMappingURL=ws-
|
|
421
|
+
//# sourceMappingURL=ws-Cp_elVzz.js.map
|
package/lab/ui/index.html
CHANGED
|
@@ -1593,32 +1593,6 @@
|
|
|
1593
1593
|
.log .xterm-viewport {
|
|
1594
1594
|
background: transparent !important;
|
|
1595
1595
|
}
|
|
1596
|
-
/* Jump-to-latest pill: thumb-reachable, bottom-right of the terminal,
|
|
1597
|
-
only visible while scrolled up (JS toggles [hidden]). Sits clear of the
|
|
1598
|
-
home-indicator / safe area so a one-handed tap always lands. */
|
|
1599
|
-
.jumpbtn {
|
|
1600
|
-
position: absolute;
|
|
1601
|
-
right: max(12px, var(--sar));
|
|
1602
|
-
bottom: max(12px, var(--sab));
|
|
1603
|
-
z-index: 9;
|
|
1604
|
-
width: 40px;
|
|
1605
|
-
height: 40px;
|
|
1606
|
-
border-radius: 50%;
|
|
1607
|
-
border: 1px solid var(--border, #30363d);
|
|
1608
|
-
background: color-mix(in srgb, var(--panel) 92%, transparent);
|
|
1609
|
-
color: var(--fg);
|
|
1610
|
-
font-size: 20px;
|
|
1611
|
-
line-height: 1;
|
|
1612
|
-
cursor: pointer;
|
|
1613
|
-
box-shadow: 0 2px 10px rgba(0, 0, 0, 0.35);
|
|
1614
|
-
display: flex;
|
|
1615
|
-
align-items: center;
|
|
1616
|
-
justify-content: center;
|
|
1617
|
-
padding: 0;
|
|
1618
|
-
}
|
|
1619
|
-
.jumpbtn[hidden] {
|
|
1620
|
-
display: none;
|
|
1621
|
-
}
|
|
1622
1596
|
.placeholder {
|
|
1623
1597
|
display: flex;
|
|
1624
1598
|
align-items: center;
|
|
@@ -5923,33 +5897,26 @@ my.translate = async (text, lang) => {
|
|
|
5923
5897
|
/* addon CDN blocked — selection still works, copy falls back to menus */
|
|
5924
5898
|
}
|
|
5925
5899
|
term.open(logEl);
|
|
5926
|
-
// ── touch
|
|
5927
|
-
//
|
|
5928
|
-
//
|
|
5929
|
-
//
|
|
5930
|
-
//
|
|
5931
|
-
//
|
|
5932
|
-
//
|
|
5933
|
-
//
|
|
5934
|
-
//
|
|
5935
|
-
//
|
|
5936
|
-
//
|
|
5937
|
-
// • double-tap → select word, triple-tap → select line (xterm keys off
|
|
5938
|
-
// MouseEvent.detail 2/3), each opening the same menu.
|
|
5939
|
-
// • a plain tap stays a click (focus, links); the second finger hands
|
|
5940
|
-
// off to the pinch/pan block.
|
|
5941
|
-
// In a mouse-tracking TUI (claude) a 1-finger vertical drag is forwarded
|
|
5942
|
-
// as a WHEEL so the app's own view scrolls, and selection/switch are
|
|
5943
|
-
// suppressed so the app keeps its gestures.
|
|
5900
|
+
// ── touch text selection ────────────────────────────────────────────
|
|
5901
|
+
// xterm gives touch no selection path at all — a drag only scrolled.
|
|
5902
|
+
// New scheme: ONE finger drags SELECT (scrolling moved to two-finger
|
|
5903
|
+
// pan — see the pinch/pan block). The drag is replayed to xterm as
|
|
5904
|
+
// synthetic mouse events, so both worlds work with one mechanism: a
|
|
5905
|
+
// mouse-tracking TUI (claude) receives the drag and runs its own
|
|
5906
|
+
// selection (copying via OSC 52 → addon above), while a plain buffer
|
|
5907
|
+
// gets xterm's local selection, auto-copied on release. A stationary
|
|
5908
|
+
// long-press still raises the browser's contextmenu → our terminal
|
|
5909
|
+
// menu, and a plain tap stays a click (links, focus) — we only take
|
|
5910
|
+
// over once the finger has clearly moved.
|
|
5944
5911
|
(function touchSelBoot(t) {
|
|
5945
5912
|
const el = t.element;
|
|
5946
5913
|
if (!el) return;
|
|
5914
|
+
let sx = 0,
|
|
5915
|
+
sy = 0,
|
|
5916
|
+
tracking = false, // 1-finger gesture in flight
|
|
5917
|
+
selecting = false; // …and past the slop → we own it
|
|
5947
5918
|
const screen = () => el.querySelector(".xterm-screen") || el;
|
|
5948
|
-
|
|
5949
|
-
// count: 1 = range drag, 2 = word, 3 = line — xterm's SelectionService
|
|
5950
|
-
// keys word/line selection off exactly that (synthetic events default
|
|
5951
|
-
// to detail 0 and are silently ignored, so it must be set).
|
|
5952
|
-
const fire = (type, x, y, buttons, detail = 1) =>
|
|
5919
|
+
const fire = (type, x, y, buttons) =>
|
|
5953
5920
|
screen().dispatchEvent(
|
|
5954
5921
|
new MouseEvent(type, {
|
|
5955
5922
|
bubbles: true,
|
|
@@ -5958,221 +5925,73 @@ my.translate = async (text, lang) => {
|
|
|
5958
5925
|
clientY: y,
|
|
5959
5926
|
button: 0,
|
|
5960
5927
|
buttons,
|
|
5961
|
-
|
|
5928
|
+
// xterm's SelectionService starts a selection only for
|
|
5929
|
+
// event.detail === 1 (single click) — synthetic events
|
|
5930
|
+
// default to 0 and are silently ignored without this.
|
|
5931
|
+
detail: 1,
|
|
5962
5932
|
}),
|
|
5963
5933
|
);
|
|
5964
|
-
const wheelAt = (x, y, dy) =>
|
|
5965
|
-
screen().dispatchEvent(
|
|
5966
|
-
new WheelEvent("wheel", {
|
|
5967
|
-
bubbles: true,
|
|
5968
|
-
cancelable: true,
|
|
5969
|
-
deltaY: dy,
|
|
5970
|
-
deltaMode: 0,
|
|
5971
|
-
clientX: x,
|
|
5972
|
-
clientY: y,
|
|
5973
|
-
}),
|
|
5974
|
-
);
|
|
5975
|
-
const isTui = () => {
|
|
5976
|
-
const mt = t.modes && t.modes.mouseTrackingMode;
|
|
5977
|
-
return !!(mt && mt !== "none");
|
|
5978
|
-
};
|
|
5979
|
-
const buzz = (ms) => {
|
|
5980
|
-
try {
|
|
5981
|
-
navigator.vibrate && navigator.vibrate(ms);
|
|
5982
|
-
} catch {}
|
|
5983
|
-
};
|
|
5984
|
-
|
|
5985
|
-
const SLOP = 14; // px before a drag is "real" (loosened for a moving hand)
|
|
5986
|
-
const LONG_MS = 450; // press-and-hold to begin a word selection
|
|
5987
|
-
const SWITCH_MIN = 60; // horizontal travel that commits an agent switch
|
|
5988
|
-
const DBL_MS = 300; // max gap between taps for a double/triple
|
|
5989
|
-
const DBL_SLOP = 24; // max spread for a multi-tap to count as "same spot"
|
|
5990
|
-
|
|
5991
|
-
let sx = 0,
|
|
5992
|
-
sy = 0,
|
|
5993
|
-
lastY = 0,
|
|
5994
|
-
// '' undecided | scroll | select | switch | tui | done
|
|
5995
|
-
mode = "";
|
|
5996
|
-
let longTimer = null;
|
|
5997
|
-
let tapCount = 0,
|
|
5998
|
-
lastTapAt = 0,
|
|
5999
|
-
lastTapX = 0,
|
|
6000
|
-
lastTapY = 0;
|
|
6001
|
-
const clearLong = () => {
|
|
6002
|
-
if (longTimer) {
|
|
6003
|
-
clearTimeout(longTimer);
|
|
6004
|
-
longTimer = null;
|
|
6005
|
-
}
|
|
6006
|
-
};
|
|
6007
|
-
// After a double/triple-tap selection, remember the text (mobile tap
|
|
6008
|
-
// emulation can collapse the live xterm selection before the menu
|
|
6009
|
-
// reads it) and pop the Copy/Paste/quick-cmd menu at the tap.
|
|
6010
|
-
const afterQuickSelect = (x, y) => {
|
|
6011
|
-
if (t.hasSelection && t.hasSelection()) {
|
|
6012
|
-
const s = t.getSelection();
|
|
6013
|
-
if (s.trim()) recentTouchSel = { text: s, at: Date.now() };
|
|
6014
|
-
showTermMenu({ preventDefault() {}, clientX: x, clientY: y }, t);
|
|
6015
|
-
}
|
|
6016
|
-
};
|
|
6017
|
-
|
|
6018
5934
|
el.addEventListener(
|
|
6019
5935
|
"touchstart",
|
|
6020
5936
|
(ev) => {
|
|
6021
5937
|
if (ev.touches.length !== 1) {
|
|
6022
|
-
// second finger →
|
|
6023
|
-
|
|
6024
|
-
|
|
6025
|
-
mode = "done";
|
|
5938
|
+
// second finger → this became a pan/pinch; abandon selection
|
|
5939
|
+
if (selecting) fire("mouseup", sx, sy, 0);
|
|
5940
|
+
tracking = selecting = false;
|
|
6026
5941
|
return;
|
|
6027
5942
|
}
|
|
5943
|
+
tracking = true;
|
|
5944
|
+
selecting = false;
|
|
6028
5945
|
sx = ev.touches[0].clientX;
|
|
6029
|
-
sy =
|
|
6030
|
-
if (isTui()) {
|
|
6031
|
-
mode = "tui";
|
|
6032
|
-
return;
|
|
6033
|
-
}
|
|
6034
|
-
mode = "";
|
|
6035
|
-
clearLong();
|
|
6036
|
-
longTimer = setTimeout(() => {
|
|
6037
|
-
if (mode !== "") return; // the finger already moved → not a hold
|
|
6038
|
-
mode = "select";
|
|
6039
|
-
fire("mousedown", sx, sy, 1, 2); // detail 2 → select word, WORD-extend mode
|
|
6040
|
-
buzz(10);
|
|
6041
|
-
}, LONG_MS);
|
|
5946
|
+
sy = ev.touches[0].clientY;
|
|
6042
5947
|
},
|
|
6043
5948
|
{ passive: true },
|
|
6044
5949
|
);
|
|
6045
|
-
|
|
6046
5950
|
el.addEventListener(
|
|
6047
5951
|
"touchmove",
|
|
6048
5952
|
(ev) => {
|
|
6049
|
-
if (ev.touches.length !== 1
|
|
5953
|
+
if (!tracking || ev.touches.length !== 1) return;
|
|
5954
|
+
// preventDefault from the FIRST move: once the browser commits
|
|
5955
|
+
// to a native scroll, later preventDefault calls are ignored —
|
|
5956
|
+
// single-finger drags must never scroll under the selection.
|
|
5957
|
+
ev.preventDefault();
|
|
6050
5958
|
const x = ev.touches[0].clientX,
|
|
6051
5959
|
y = ev.touches[0].clientY;
|
|
6052
|
-
|
|
6053
|
-
|
|
6054
|
-
|
|
6055
|
-
|
|
6056
|
-
// No scrollback in an alt-screen app — forward the drag as a
|
|
6057
|
-
// wheel so the app's OWN view (claude's chat) scrolls instead.
|
|
6058
|
-
ev.preventDefault();
|
|
6059
|
-
const ddy = y - lastY;
|
|
6060
|
-
lastY = y;
|
|
6061
|
-
if (ddy) wheelAt(x, y, -ddy);
|
|
6062
|
-
return;
|
|
6063
|
-
}
|
|
6064
|
-
if (mode === "select") {
|
|
6065
|
-
ev.preventDefault();
|
|
6066
|
-
fire("mousemove", x, y, 1); // extend the word selection
|
|
6067
|
-
return;
|
|
6068
|
-
}
|
|
6069
|
-
if (mode === "") {
|
|
6070
|
-
if (Math.hypot(dx, dy) <= SLOP) return; // still within tap/hold slop
|
|
6071
|
-
clearLong();
|
|
6072
|
-
// Axis lock: a decisively horizontal, far-enough flick switches
|
|
6073
|
-
// agents; anything else falls through to native vertical scroll.
|
|
6074
|
-
if (Math.abs(dx) > Math.abs(dy) * 1.4 && Math.abs(dx) >= SWITCH_MIN) {
|
|
6075
|
-
mode = "switch";
|
|
6076
|
-
ev.preventDefault();
|
|
6077
|
-
// ← left = next (forward), → right = prev (back)
|
|
6078
|
-
try {
|
|
6079
|
-
stepSelection(dx < 0 ? 1 : -1);
|
|
6080
|
-
} catch {}
|
|
6081
|
-
buzz(12);
|
|
6082
|
-
} else {
|
|
6083
|
-
// Let the browser scroll `.xterm-viewport` natively (momentum,
|
|
6084
|
-
// and honouring an already-committed scroll) — do NOT
|
|
6085
|
-
// preventDefault here, that's what keeps the flick smooth.
|
|
6086
|
-
mode = "scroll";
|
|
6087
|
-
}
|
|
6088
|
-
return;
|
|
5960
|
+
if (!selecting) {
|
|
5961
|
+
if (Math.hypot(x - sx, y - sy) <= 10) return; // tap / long-press slop
|
|
5962
|
+
selecting = true;
|
|
5963
|
+
fire("mousedown", sx, sy, 1); // anchor at the touch ORIGIN
|
|
6089
5964
|
}
|
|
5965
|
+
fire("mousemove", x, y, 1);
|
|
6090
5966
|
},
|
|
6091
5967
|
{ passive: false },
|
|
6092
5968
|
);
|
|
6093
|
-
|
|
6094
5969
|
const end = (ev) => {
|
|
6095
|
-
|
|
6096
|
-
|
|
5970
|
+
const was = selecting;
|
|
5971
|
+
tracking = selecting = false;
|
|
5972
|
+
if (!was) return;
|
|
6097
5973
|
const p = (ev.changedTouches && ev.changedTouches[0]) || { clientX: sx, clientY: sy };
|
|
6098
|
-
|
|
6099
|
-
|
|
6100
|
-
if (
|
|
6101
|
-
|
|
6102
|
-
|
|
6103
|
-
|
|
6104
|
-
|
|
6105
|
-
|
|
6106
|
-
|
|
6107
|
-
|
|
6108
|
-
|
|
6109
|
-
|
|
6110
|
-
|
|
6111
|
-
|
|
6112
|
-
|
|
6113
|
-
|
|
6114
|
-
|
|
6115
|
-
}
|
|
6116
|
-
// finished === "" → nothing moved and no hold fired: a TAP. Fold it
|
|
6117
|
-
// into double/triple-tap word/line selection; a lone tap is left as a
|
|
6118
|
-
// native click so focus + link handling still work.
|
|
6119
|
-
const now = Date.now();
|
|
6120
|
-
const near =
|
|
6121
|
-
Math.abs(p.clientX - lastTapX) < DBL_SLOP && Math.abs(p.clientY - lastTapY) < DBL_SLOP;
|
|
6122
|
-
tapCount = now - lastTapAt < DBL_MS && near ? tapCount + 1 : 1;
|
|
6123
|
-
lastTapAt = now;
|
|
6124
|
-
lastTapX = p.clientX;
|
|
6125
|
-
lastTapY = p.clientY;
|
|
6126
|
-
if (isTui()) return; // let the app have its taps
|
|
6127
|
-
if (tapCount === 2) {
|
|
6128
|
-
fire("mousedown", p.clientX, p.clientY, 1, 2); // word
|
|
6129
|
-
fire("mouseup", p.clientX, p.clientY, 0, 2);
|
|
6130
|
-
afterQuickSelect(p.clientX, p.clientY);
|
|
6131
|
-
} else if (tapCount >= 3) {
|
|
6132
|
-
fire("mousedown", p.clientX, p.clientY, 1, 3); // line
|
|
6133
|
-
fire("mouseup", p.clientX, p.clientY, 0, 3);
|
|
6134
|
-
afterQuickSelect(p.clientX, p.clientY);
|
|
6135
|
-
tapCount = 0;
|
|
5974
|
+
fire("mouseup", p.clientX, p.clientY, 0);
|
|
5975
|
+
const mt = t.modes && t.modes.mouseTrackingMode;
|
|
5976
|
+
if (mt && mt !== "none") return; // the TUI owns selection + OSC 52 copy
|
|
5977
|
+
if (t.hasSelection()) {
|
|
5978
|
+
// Remember the selection for the long-press menu: on mobile the
|
|
5979
|
+
// browser's tap/long-press emulation can collapse the xterm
|
|
5980
|
+
// selection BEFORE the menu opens, which made selection-fed
|
|
5981
|
+
// commands (Translate, [selection]) run against empty text.
|
|
5982
|
+
const selTxt = t.getSelection();
|
|
5983
|
+
// whitespace-only cell selections aren't worth remembering
|
|
5984
|
+
if (selTxt.trim()) recentTouchSel = { text: selTxt, at: Date.now() };
|
|
5985
|
+
copyText(selTxt);
|
|
5986
|
+
const pill = document.createElement("div");
|
|
5987
|
+
pill.className = "updatebar";
|
|
5988
|
+
pill.textContent = "copied";
|
|
5989
|
+
document.body.appendChild(pill);
|
|
5990
|
+
setTimeout(() => pill.remove(), 900);
|
|
6136
5991
|
}
|
|
6137
5992
|
};
|
|
6138
5993
|
el.addEventListener("touchend", end);
|
|
6139
|
-
el.addEventListener("touchcancel",
|
|
6140
|
-
clearLong();
|
|
6141
|
-
mode = "";
|
|
6142
|
-
});
|
|
6143
|
-
})(term);
|
|
6144
|
-
// Jump-to-bottom affordance: while scrolled up, a thumb-reachable pill in
|
|
6145
|
-
// the bottom-right of the terminal snaps back to the live tail. Shown only
|
|
6146
|
-
// when the viewport isn't already pinned to the bottom (checked on every
|
|
6147
|
-
// scroll AND render, since new output grows baseY without an onScroll).
|
|
6148
|
-
(function jumpToBottomBoot(t) {
|
|
6149
|
-
const host = logEl;
|
|
6150
|
-
if (!host) return;
|
|
6151
|
-
const btn = document.createElement("button");
|
|
6152
|
-
btn.type = "button";
|
|
6153
|
-
btn.className = "jumpbtn";
|
|
6154
|
-
btn.setAttribute("aria-label", "Jump to latest output");
|
|
6155
|
-
btn.textContent = "⤓";
|
|
6156
|
-
btn.hidden = true;
|
|
6157
|
-
host.appendChild(btn);
|
|
6158
|
-
const atBottom = () => {
|
|
6159
|
-
const b = t.buffer && t.buffer.active;
|
|
6160
|
-
return !b || b.viewportY >= b.baseY;
|
|
6161
|
-
};
|
|
6162
|
-
const sync = () => {
|
|
6163
|
-
const hide = atBottom();
|
|
6164
|
-
if (btn.hidden !== hide) btn.hidden = hide;
|
|
6165
|
-
};
|
|
6166
|
-
try {
|
|
6167
|
-
t.onScroll(sync);
|
|
6168
|
-
t.onRender(sync);
|
|
6169
|
-
} catch {}
|
|
6170
|
-
btn.addEventListener("click", (ev) => {
|
|
6171
|
-
ev.preventDefault();
|
|
6172
|
-
t.scrollToBottom();
|
|
6173
|
-
sync();
|
|
6174
|
-
});
|
|
6175
|
-
sync();
|
|
5994
|
+
el.addEventListener("touchcancel", end);
|
|
6176
5995
|
})(term);
|
|
6177
5996
|
// Right-click opens our own menu (Copy / Paste / customizable quick
|
|
6178
5997
|
// commands like `/fork [selection]`) instead of copying outright. We
|
package/package.json
CHANGED
package/ts/subcommands.ts
CHANGED
|
@@ -3084,13 +3084,6 @@ async function cmdSend(rest: string[]): Promise<number> {
|
|
|
3084
3084
|
description:
|
|
3085
3085
|
"Fire-and-forget: skip the paste-settle wait and submit confirmation, don't retry a swallowed Enter (also: AGENT_YES_SEND_NO_WAIT=1)",
|
|
3086
3086
|
})
|
|
3087
|
-
.option("raw", {
|
|
3088
|
-
type: "boolean",
|
|
3089
|
-
default: false,
|
|
3090
|
-
alias: "no-wrap",
|
|
3091
|
-
description:
|
|
3092
|
-
"Send the body verbatim: omit the <ay-msg …> attribution wrapper that agent senders add by default (also: AGENT_YES_SEND_RAW=1)",
|
|
3093
|
-
})
|
|
3094
3087
|
.help(false)
|
|
3095
3088
|
.version(false)
|
|
3096
3089
|
.exitProcess(false);
|
|
@@ -3148,7 +3141,6 @@ async function cmdSend(rest: string[]): Promise<number> {
|
|
|
3148
3141
|
|
|
3149
3142
|
// Who's sending, and have they actually looked at this target recently?
|
|
3150
3143
|
const force = Boolean(argv.force) || process.env.AGENT_YES_FORCE_SEND === "1";
|
|
3151
|
-
const raw = Boolean(argv.raw) || process.env.AGENT_YES_SEND_RAW === "1";
|
|
3152
3144
|
const sender = await enforceSendGuards(record, force);
|
|
3153
3145
|
|
|
3154
3146
|
// A bare "exit" / "/exit" isn't a prompt to type — claude only honours the
|
|
@@ -3190,7 +3182,7 @@ async function cmdSend(rest: string[]): Promise<number> {
|
|
|
3190
3182
|
let prefix = "";
|
|
3191
3183
|
let suffix = "";
|
|
3192
3184
|
let nonce: string | undefined;
|
|
3193
|
-
if (sender.agent && !isSlashCommand(body)
|
|
3185
|
+
if (sender.agent && !isSlashCommand(body)) {
|
|
3194
3186
|
nonce = randomBytes(4).toString("hex");
|
|
3195
3187
|
prefix = `<ay-msg ${nonce} from ${sender.agent.cli} #${sender.agent.pid} @ ${shortenPath(sender.agent.cwd)} — reply: ay send ${replyTarget} "...">\n`;
|
|
3196
3188
|
suffix = `\n</ay-msg ${nonce}>`;
|
package/dist/trayApp-oHn-g05d.js
DELETED