agent-yes 1.304.1 → 1.304.2-beta.813.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-DRG5d-dl.js +12 -0
- package/dist/{SUPPORTED_CLIS-D1BObsKi.js → SUPPORTED_CLIS-Z026oWlt.js} +2 -2
- package/dist/{agentShare-pQedI_ay.js → agentShare-mG8mFEc3.js} +4 -4
- package/dist/{askCli-KmMf-3wA.js → askCli-Dtxxwl28.js} +3 -3
- package/dist/{callback-Bd_uX6c9.js → callback-BUwH7ySJ.js} +3 -3
- package/dist/{callback-WJ1STnzc.js → callback-cZ4e-KGt.js} +4 -4
- package/dist/cli.js +10 -10
- package/dist/{cmdKill-CzSBfWmx.js → cmdKill-DUyZ7Dch.js} +2 -2
- package/dist/{cmdPs-Bzld9JDB.js → cmdPs-BC8fGSpA.js} +4 -4
- package/dist/{cwdConflictWarn-y-epQyOj.js → cwdConflictWarn-ml6Qs3Qu.js} +2 -2
- package/dist/{forkNested-3heLs5XC.js → forkNested-DHuYbpaf.js} +3 -3
- package/dist/{globalPidIndex-BsjlId-h.js → globalPidIndex-C6p_AY4D.js} +5 -2
- package/dist/globalPidIndex-DmDCB_X7.js +4 -0
- package/dist/index.js +4 -4
- package/dist/{notifyDaemon-D_fT6Xht.js → notifyDaemon-ik_Y6sWw.js} +4 -4
- package/dist/{parentLink-MBUD3oY2.js → parentLink-B7_kEM1v.js} +2 -2
- package/dist/{parentLink-BcAYcO9L.js → parentLink-UiM6WoKm.js} +2 -2
- package/dist/{parentPingLoop-CVqnIzti.js → parentPingLoop-9INbUyK5.js} +4 -4
- package/dist/pidStore-B89BOF_T.js +6 -0
- package/dist/{pidStore-C50VPk3E.js → pidStore-DUXifdBr.js} +2 -2
- package/dist/{rustBinary-BEUXAC5F.js → rustBinary-Pf8XKYRk.js} +2 -2
- package/dist/{rustBinary-AJOmpsZY.js → rustBinary-xlvjV_pG.js} +2 -2
- package/dist/{schedule-CeSvliXR.js → schedule-DL_WFsLJ.js} +6 -6
- package/dist/{serve-Dn24AExp.js → serve-Do7L7okz.js} +27 -25
- package/dist/{setup-onxpwXOt.js → setup-DkT3oY30.js} +2 -2
- package/dist/{shareCmd-Bfxkzdm6.js → shareCmd-UV7Q6Ncm.js} +5 -5
- package/dist/{spawnGate-Dj_WaS29.js → spawnGate-3YSXiRFS.js} +2 -2
- package/dist/spawnGate-I4p2fbz7.js +5 -0
- package/dist/{subcommands-B-VG0io0.js → subcommands-CcjH2sFA.js} +3 -3
- package/dist/{subcommands--RGuFC68.js → subcommands-GdGWUii6.js} +103 -32
- package/dist/{terminal-Jsj7SgxD.js → terminal-C-RVcAbq.js} +2 -2
- package/dist/{todoCli-CU9vSJSJ.js → todoCli-uJ3nK9j4.js} +3 -3
- package/dist/{todoIdentity-CzS1e7VL.js → todoIdentity-DeDp7LKl.js} +2 -2
- package/dist/{trayApp-lEZ-Wa4D.js → trayApp-BumYIh0H.js} +2 -2
- package/dist/trayApp-CTS3AVOK.js +5 -0
- package/dist/{ts-DLPvUXQS.js → ts-D6Tu7Lev.js} +6 -6
- package/dist/{versionChecker-Dtj0d8dY.js → versionChecker-DHFAiPhh.js} +2 -2
- package/dist/{widget-CyoP4Stv.js → widget-rTAruZmb.js} +3 -3
- package/dist/{ws-CDZj5r8l.js → ws-DLhUK2dn.js} +2 -2
- package/dist/{ws-DtFNNKlC.js → ws-oRDepI0t.js} +4 -4
- package/lab/ui/console-logic.js +15 -7
- package/lab/ui/index.html +16 -11
- package/package.json +1 -1
- package/ts/serve.ts +6 -1
- package/ts/subcommands.ts +97 -10
- package/dist/SUPPORTED_CLIS-R2KdLsVb.js +0 -12
- package/dist/globalPidIndex-uoz8Esqz.js +0 -4
- package/dist/pidStore-COkPjpW8.js +0 -6
- package/dist/spawnGate-Dfj9V76w.js +0 -5
- package/dist/trayApp-Bngl2X4e.js +0 -5
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
import "./logger-CDIsZ-Pp.js";
|
|
2
|
+
import "./versionChecker-DHFAiPhh.js";
|
|
3
|
+
import "./ts-D6Tu7Lev.js";
|
|
4
|
+
import "./todoAutomation-CKlrxuZv.js";
|
|
5
|
+
import "./JsonlStore-CB_0sfdT.js";
|
|
6
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
7
|
+
import "./pidStore-DUXifdBr.js";
|
|
8
|
+
import "./messageLog-Dq_ka-Bt.js";
|
|
9
|
+
import "./todoStore-msRCEUi1.js";
|
|
10
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-Z026oWlt.js";
|
|
11
|
+
|
|
12
|
+
export { SUPPORTED_CLIS };
|
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import { t as CLIS_CONFIG } from "./ts-
|
|
1
|
+
import { t as CLIS_CONFIG } from "./ts-D6Tu7Lev.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-Z026oWlt.js.map
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
2
|
import "./JsonlStore-CB_0sfdT.js";
|
|
3
|
-
import "./globalPidIndex-
|
|
4
|
-
import "./pidStore-
|
|
3
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
4
|
+
import "./pidStore-DUXifdBr.js";
|
|
5
5
|
import "./messageLog-Dq_ka-Bt.js";
|
|
6
6
|
import "./e2e-BdLf8DvY.js";
|
|
7
7
|
import "./configShared-De4bR5hH.js";
|
|
8
|
-
import { ot as resolveOne } from "./subcommands
|
|
8
|
+
import { ot as resolveOne } from "./subcommands-GdGWUii6.js";
|
|
9
9
|
import "./webrtcLink-DcvacEci.js";
|
|
10
10
|
import "./remotes-BsMGvAay.js";
|
|
11
11
|
import "./roomReplyAlias-B-v76TA8.js";
|
|
@@ -234,4 +234,4 @@ function transformEvent(rawEvent, agentId, forwarded) {
|
|
|
234
234
|
|
|
235
235
|
//#endregion
|
|
236
236
|
export { createScopedShare, listShares, revokeAllShares, revokeShare };
|
|
237
|
-
//# sourceMappingURL=agentShare-
|
|
237
|
+
//# sourceMappingURL=agentShare-mG8mFEc3.js.map
|
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
2
|
import "./JsonlStore-CB_0sfdT.js";
|
|
3
|
-
import "./globalPidIndex-
|
|
3
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
4
4
|
import { r as openStore } from "./todoStore-msRCEUi1.js";
|
|
5
5
|
import { t as formatIdentity } from "./identity-Ckav3-Up.js";
|
|
6
|
-
import { a as resolveTodoRoot, i as resolveSelf } from "./todoIdentity-
|
|
6
|
+
import { a as resolveTodoRoot, i as resolveSelf } from "./todoIdentity-DeDp7LKl.js";
|
|
7
7
|
import yargs from "yargs";
|
|
8
8
|
import { randomBytes } from "crypto";
|
|
9
9
|
|
|
@@ -269,4 +269,4 @@ async function runAnswerSubcommand(rest, deps) {
|
|
|
269
269
|
|
|
270
270
|
//#endregion
|
|
271
271
|
export { runAnswerSubcommand, runAskSubcommand };
|
|
272
|
-
//# sourceMappingURL=askCli-
|
|
272
|
+
//# sourceMappingURL=askCli-Dtxxwl28.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { t as agentYesHome } from "./agentYesHome-JmJC28YX.js";
|
|
2
|
-
import { ot as resolveOne } from "./subcommands
|
|
2
|
+
import { ot as resolveOne } from "./subcommands-GdGWUii6.js";
|
|
3
3
|
import { a as mintCapability, o as parseExpires } from "./callbackCore-Deve5pv3.js";
|
|
4
4
|
import { chmodSync, readFileSync, renameSync, writeFileSync } from "node:fs";
|
|
5
5
|
import path from "node:path";
|
|
@@ -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-Do7L7okz.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-BUwH7ySJ.js.map
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
2
|
import "./JsonlStore-CB_0sfdT.js";
|
|
3
|
-
import "./globalPidIndex-
|
|
4
|
-
import "./pidStore-
|
|
3
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
4
|
+
import "./pidStore-DUXifdBr.js";
|
|
5
5
|
import "./messageLog-Dq_ka-Bt.js";
|
|
6
6
|
import "./e2e-BdLf8DvY.js";
|
|
7
7
|
import "./configShared-De4bR5hH.js";
|
|
8
|
-
import "./subcommands
|
|
8
|
+
import "./subcommands-GdGWUii6.js";
|
|
9
9
|
import "./webrtcLink-DcvacEci.js";
|
|
10
10
|
import "./remotes-BsMGvAay.js";
|
|
11
11
|
import "./roomReplyAlias-B-v76TA8.js";
|
|
12
12
|
import "./notifyStore-DIfkfKB2.js";
|
|
13
13
|
import "./senderAncestry-CVHeKk1Y.js";
|
|
14
14
|
import "./callbackCore-Deve5pv3.js";
|
|
15
|
-
import { i as loadOrCreateCallbackSecret, n as isCallbackRevoked, r as loadCallbackSecretReadOnly, t as cmdCallback } from "./callback-
|
|
15
|
+
import { i as loadOrCreateCallbackSecret, n as isCallbackRevoked, r as loadCallbackSecretReadOnly, t as cmdCallback } from "./callback-BUwH7ySJ.js";
|
|
16
16
|
|
|
17
17
|
export { cmdCallback };
|
package/dist/cli.js
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
#!/usr/bin/env bun
|
|
2
2
|
import { t as invokedCliName } from "./invokedCli-zdFbz1ST.js";
|
|
3
3
|
import { n as logger } from "./logger-CDIsZ-Pp.js";
|
|
4
|
-
import { a as versionString, r as displayVersion, t as checkAndAutoUpdate } from "./versionChecker-
|
|
5
|
-
import { m as getRustBinary } from "./rustBinary-
|
|
4
|
+
import { a as versionString, r as displayVersion, t as checkAndAutoUpdate } from "./versionChecker-DHFAiPhh.js";
|
|
5
|
+
import { m as getRustBinary } from "./rustBinary-xlvjV_pG.js";
|
|
6
6
|
import { statSync } from "node:fs";
|
|
7
7
|
import { isAbsolute } from "node:path";
|
|
8
8
|
import { argv } from "process";
|
|
@@ -378,7 +378,7 @@ function buildRustArgs(argv, cliFromScript, supportedClis) {
|
|
|
378
378
|
const rawArg = process.argv[2];
|
|
379
379
|
const managerCommands = !invokedCliName(process.argv);
|
|
380
380
|
const isHelpFlag = rawArg === "-h" || rawArg === "--help";
|
|
381
|
-
const { isSubcommand, runSubcommand, cmdHelp, isUnknownManagerToken, isBareManagerInvocation } = await import("./subcommands-
|
|
381
|
+
const { isSubcommand, runSubcommand, cmdHelp, isUnknownManagerToken, isBareManagerInvocation } = await import("./subcommands-CcjH2sFA.js");
|
|
382
382
|
if (isHelpFlag && process.argv.length === 3) {
|
|
383
383
|
await cmdHelp(managerCommands);
|
|
384
384
|
process.exit(0);
|
|
@@ -392,7 +392,7 @@ function buildRustArgs(argv, cliFromScript, supportedClis) {
|
|
|
392
392
|
process.exit(code ?? 0);
|
|
393
393
|
}
|
|
394
394
|
{
|
|
395
|
-
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-
|
|
395
|
+
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-DRG5d-dl.js");
|
|
396
396
|
if (isUnknownManagerToken(rawArg, managerCommands, SUPPORTED_CLIS)) {
|
|
397
397
|
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`);
|
|
398
398
|
process.exit(1);
|
|
@@ -411,7 +411,7 @@ await checkAndAutoUpdate();
|
|
|
411
411
|
logger.info(versionString());
|
|
412
412
|
const config = parseCliArgs(process.argv);
|
|
413
413
|
{
|
|
414
|
-
const { stripDetachFlag } = await import("./forkNested-
|
|
414
|
+
const { stripDetachFlag } = await import("./forkNested-DHuYbpaf.js");
|
|
415
415
|
const res = stripDetachFlag(process.argv.slice(2), Boolean(config.detach));
|
|
416
416
|
if (!res.ok) {
|
|
417
417
|
console.error(res.error);
|
|
@@ -437,7 +437,7 @@ if (config.tray) {
|
|
|
437
437
|
ensureTray();
|
|
438
438
|
}
|
|
439
439
|
if (!config.showVersion && !config.appendPrompt && !config.tray) {
|
|
440
|
-
const { waitForSpawnCapacity } = await import("./spawnGate-
|
|
440
|
+
const { waitForSpawnCapacity } = await import("./spawnGate-I4p2fbz7.js");
|
|
441
441
|
await waitForSpawnCapacity({
|
|
442
442
|
onWait: (reason, waitedMs) => {
|
|
443
443
|
if (config.verbose || waitedMs === 0) console.error(`[agent-yes] spawn gate: ${reason} — waiting…`);
|
|
@@ -446,7 +446,7 @@ if (!config.showVersion && !config.appendPrompt && !config.tray) {
|
|
|
446
446
|
});
|
|
447
447
|
}
|
|
448
448
|
if (!config.showVersion && !config.appendPrompt && !config.tray) {
|
|
449
|
-
const { warnIfCwdOccupied } = await import("./cwdConflictWarn-
|
|
449
|
+
const { warnIfCwdOccupied } = await import("./cwdConflictWarn-ml6Qs3Qu.js");
|
|
450
450
|
await warnIfCwdOccupied(process.argv);
|
|
451
451
|
}
|
|
452
452
|
if (config.useRust) {
|
|
@@ -464,14 +464,14 @@ if (config.useRust) {
|
|
|
464
464
|
process.exit(1);
|
|
465
465
|
}
|
|
466
466
|
if (rustBinary) {
|
|
467
|
-
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-
|
|
467
|
+
const { SUPPORTED_CLIS } = await import("./SUPPORTED_CLIS-DRG5d-dl.js");
|
|
468
468
|
const rustArgs = buildRustArgs(process.argv, config.cli, SUPPORTED_CLIS);
|
|
469
469
|
if (config.verbose) {
|
|
470
470
|
console.log(`[rust] Using binary: ${rustBinary}`);
|
|
471
471
|
console.log(`[rust] Args: ${rustArgs.join(" ")}`);
|
|
472
472
|
}
|
|
473
473
|
const attach = config.attach || process.env.AGENT_YES_ATTACH === "1";
|
|
474
|
-
const { shouldForkNested, buildSpawnTutorial, waitForRegistration, confirmAgentStarted, predictedLogPath } = await import("./forkNested-
|
|
474
|
+
const { shouldForkNested, buildSpawnTutorial, waitForRegistration, confirmAgentStarted, predictedLogPath } = await import("./forkNested-DHuYbpaf.js");
|
|
475
475
|
if (shouldForkNested({
|
|
476
476
|
isTTY: Boolean(process.stdout.isTTY),
|
|
477
477
|
ayPid: process.env.AGENT_YES_PID,
|
|
@@ -539,7 +539,7 @@ if (config.showVersion) {
|
|
|
539
539
|
process.exit(0);
|
|
540
540
|
}
|
|
541
541
|
if (config.appendPrompt) {
|
|
542
|
-
const { PidStore } = await import("./pidStore-
|
|
542
|
+
const { PidStore } = await import("./pidStore-B89BOF_T.js");
|
|
543
543
|
const ipcPath = await PidStore.findActiveFifo(process.cwd());
|
|
544
544
|
if (!ipcPath) {
|
|
545
545
|
console.error("No active agent with IPC found in current directory.");
|
|
@@ -54,7 +54,7 @@ async function cmdKill(rest) {
|
|
|
54
54
|
return 1;
|
|
55
55
|
}
|
|
56
56
|
const pid = Number(sel);
|
|
57
|
-
const { readGlobalPids, updateGlobalPidStatus } = await import("./globalPidIndex-
|
|
57
|
+
const { readGlobalPids, updateGlobalPidStatus } = await import("./globalPidIndex-DmDCB_X7.js");
|
|
58
58
|
const matches = (await readGlobalPids()).filter((r) => r.pid === pid);
|
|
59
59
|
if (matches.length !== 1) {
|
|
60
60
|
process.stderr.write(matches.length === 0 ? `ay kill: no registered agent has pid ${pid} (see: ay ls --all)\n` : `ay kill: ${matches.length} registry rows claim pid ${pid} — refusing an ambiguous kill\n`);
|
|
@@ -113,4 +113,4 @@ async function cmdKill(rest) {
|
|
|
113
113
|
|
|
114
114
|
//#endregion
|
|
115
115
|
export { cmdKill };
|
|
116
|
-
//# sourceMappingURL=cmdKill-
|
|
116
|
+
//# sourceMappingURL=cmdKill-DUyZ7Dch.js.map
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
2
|
import "./JsonlStore-CB_0sfdT.js";
|
|
3
|
-
import "./globalPidIndex-
|
|
4
|
-
import "./pidStore-
|
|
3
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
4
|
+
import "./pidStore-DUXifdBr.js";
|
|
5
5
|
import "./messageLog-Dq_ka-Bt.js";
|
|
6
6
|
import "./e2e-BdLf8DvY.js";
|
|
7
7
|
import "./configShared-De4bR5hH.js";
|
|
8
|
-
import { Dt as
|
|
8
|
+
import { Dt as buildAgentForest, G as listRecords, Ot as flattenForest, y as deriveLiveState } from "./subcommands-GdGWUii6.js";
|
|
9
9
|
import "./webrtcLink-DcvacEci.js";
|
|
10
10
|
import "./remotes-BsMGvAay.js";
|
|
11
11
|
import "./roomReplyAlias-B-v76TA8.js";
|
|
@@ -332,4 +332,4 @@ function readPpidSync(pid) {
|
|
|
332
332
|
|
|
333
333
|
//#endregion
|
|
334
334
|
export { cmdPs };
|
|
335
|
-
//# sourceMappingURL=cmdPs-
|
|
335
|
+
//# sourceMappingURL=cmdPs-BC8fGSpA.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import {
|
|
2
|
+
import { o as readGlobalPids } from "./globalPidIndex-C6p_AY4D.js";
|
|
3
3
|
import path from "path";
|
|
4
4
|
|
|
5
5
|
//#region ts/cwdConflictWarn.ts
|
|
@@ -77,4 +77,4 @@ async function warnIfCwdOccupied(rawArgv) {
|
|
|
77
77
|
|
|
78
78
|
//#endregion
|
|
79
79
|
export { warnIfCwdOccupied };
|
|
80
|
-
//# sourceMappingURL=cwdConflictWarn-
|
|
80
|
+
//# sourceMappingURL=cwdConflictWarn-ml6Qs3Qu.js.map
|
|
@@ -102,7 +102,7 @@ function buildSpawnTutorial(cli, pid) {
|
|
|
102
102
|
* fast instead of waiting out the whole window).
|
|
103
103
|
*/
|
|
104
104
|
async function waitForRegistration(pid, timeoutMs = 5e3, aborted) {
|
|
105
|
-
const { readGlobalPids } = await import("./globalPidIndex-
|
|
105
|
+
const { readGlobalPids } = await import("./globalPidIndex-DmDCB_X7.js");
|
|
106
106
|
const isRegistered = async () => (await readGlobalPids()).some((r) => r.pid === pid && r.status !== "exited");
|
|
107
107
|
const deadline = Date.now() + timeoutMs;
|
|
108
108
|
while (Date.now() < deadline) {
|
|
@@ -150,7 +150,7 @@ async function tailFile(file, max = 400) {
|
|
|
150
150
|
* success, keeping the previous behaviour for anything this can't decide.
|
|
151
151
|
*/
|
|
152
152
|
async function confirmAgentStarted(pid, graceMs = 1500, aborted) {
|
|
153
|
-
const { readGlobalPids } = await import("./globalPidIndex-
|
|
153
|
+
const { readGlobalPids } = await import("./globalPidIndex-DmDCB_X7.js");
|
|
154
154
|
const { stat } = await import("fs/promises");
|
|
155
155
|
const deadline = Date.now() + graceMs;
|
|
156
156
|
while (Date.now() < deadline) {
|
|
@@ -181,4 +181,4 @@ async function confirmAgentStarted(pid, graceMs = 1500, aborted) {
|
|
|
181
181
|
|
|
182
182
|
//#endregion
|
|
183
183
|
export { buildSpawnTutorial, confirmAgentStarted, predictedLogPath, shouldForkNested, stripDetachFlag, waitForRegistration };
|
|
184
|
-
//# sourceMappingURL=forkNested-
|
|
184
|
+
//# sourceMappingURL=forkNested-DHuYbpaf.js.map
|
|
@@ -16,6 +16,9 @@ function resolveGlobalDir() {
|
|
|
16
16
|
function resolveGlobalFile() {
|
|
17
17
|
return path.join(resolveGlobalDir(), "pids.jsonl");
|
|
18
18
|
}
|
|
19
|
+
function getGlobalPidIndexPath() {
|
|
20
|
+
return resolveGlobalFile();
|
|
21
|
+
}
|
|
19
22
|
async function withLock(file, fn) {
|
|
20
23
|
await mkdir(path.dirname(file), { recursive: true });
|
|
21
24
|
let release;
|
|
@@ -315,5 +318,5 @@ async function gcLogs(maxAgeMs = retentionMs()) {
|
|
|
315
318
|
}
|
|
316
319
|
|
|
317
320
|
//#endregion
|
|
318
|
-
export {
|
|
319
|
-
//# sourceMappingURL=globalPidIndex-
|
|
321
|
+
export { pruneOldLogs as a, updateGlobalPidStatus as c, maybeCompactGlobalPids as i, gcLogs as n, readGlobalPids as o, getGlobalPidIndexPath as r, sweepOrphanLogs as s, appendGlobalPid as t };
|
|
322
|
+
//# sourceMappingURL=globalPidIndex-C6p_AY4D.js.map
|
|
@@ -0,0 +1,4 @@
|
|
|
1
|
+
import "./logger-CDIsZ-Pp.js";
|
|
2
|
+
import { a as pruneOldLogs, c as updateGlobalPidStatus, i as maybeCompactGlobalPids, n as gcLogs, o as readGlobalPids, r as getGlobalPidIndexPath, s as sweepOrphanLogs, t as appendGlobalPid } from "./globalPidIndex-C6p_AY4D.js";
|
|
3
|
+
|
|
4
|
+
export { gcLogs, readGlobalPids, updateGlobalPidStatus };
|
package/dist/index.js
CHANGED
|
@@ -1,10 +1,10 @@
|
|
|
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-DHFAiPhh.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-D6Tu7Lev.js";
|
|
4
4
|
import { a as renderTree, c as describeBlock, i as renderDigest, l as monitorHint, o as unblockedTasks, r as openBlockers, t as reconcileTodos, u as removeControlCharacters } from "./todoAutomation-CKlrxuZv.js";
|
|
5
5
|
import "./JsonlStore-CB_0sfdT.js";
|
|
6
|
-
import "./globalPidIndex-
|
|
7
|
-
import "./pidStore-
|
|
6
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
7
|
+
import "./pidStore-DUXifdBr.js";
|
|
8
8
|
import "./messageLog-Dq_ka-Bt.js";
|
|
9
9
|
import { a as LIFECYCLES, c as initialState, d as requiredGate, f as statesOf, i as DONE_STATE, l as isKnownKind, n as TodoStore, o as ORPHANED_STATE, r as openStore, s as canTransition, t as CycleError, u as nextStates } from "./todoStore-msRCEUi1.js";
|
|
10
10
|
|
|
@@ -1,11 +1,11 @@
|
|
|
1
1
|
import { n as logger } from "./logger-CDIsZ-Pp.js";
|
|
2
2
|
import "./JsonlStore-CB_0sfdT.js";
|
|
3
|
-
import "./globalPidIndex-
|
|
4
|
-
import "./pidStore-
|
|
3
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
4
|
+
import "./pidStore-DUXifdBr.js";
|
|
5
5
|
import "./messageLog-Dq_ka-Bt.js";
|
|
6
6
|
import "./e2e-BdLf8DvY.js";
|
|
7
7
|
import "./configShared-De4bR5hH.js";
|
|
8
|
-
import { G as listRecords, I as isPidAlive, rt as renderLogTailLines, y as deriveLiveState } from "./subcommands
|
|
8
|
+
import { G as listRecords, I as isPidAlive, rt as renderLogTailLines, y as deriveLiveState } from "./subcommands-GdGWUii6.js";
|
|
9
9
|
import "./webrtcLink-DcvacEci.js";
|
|
10
10
|
import "./remotes-BsMGvAay.js";
|
|
11
11
|
import "./roomReplyAlias-B-v76TA8.js";
|
|
@@ -881,4 +881,4 @@ async function ensureDaemon() {
|
|
|
881
881
|
|
|
882
882
|
//#endregion
|
|
883
883
|
export { daemonStatus, ensureDaemon, requestDaemonStop, runDaemon };
|
|
884
|
-
//# sourceMappingURL=notifyDaemon-
|
|
884
|
+
//# sourceMappingURL=notifyDaemon-ik_Y6sWw.js.map
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import "./globalPidIndex-
|
|
3
|
-
import { n as spawnerFromRecords, t as resolveSpawner } from "./parentLink-
|
|
2
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
3
|
+
import { n as spawnerFromRecords, t as resolveSpawner } from "./parentLink-UiM6WoKm.js";
|
|
4
4
|
|
|
5
5
|
export { resolveSpawner };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { o as readGlobalPids } from "./globalPidIndex-C6p_AY4D.js";
|
|
2
2
|
|
|
3
3
|
//#region ts/parentLink.ts
|
|
4
4
|
/**
|
|
@@ -50,4 +50,4 @@ function spawnerFromRecords(records, parentPid) {
|
|
|
50
50
|
|
|
51
51
|
//#endregion
|
|
52
52
|
export { spawnerFromRecords as n, resolveSpawner as t };
|
|
53
|
-
//# sourceMappingURL=parentLink-
|
|
53
|
+
//# sourceMappingURL=parentLink-UiM6WoKm.js.map
|
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
import { n as logger } from "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import "./globalPidIndex-
|
|
2
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
3
3
|
import { t as classifyNeedsInput } from "./needsInput-hRiWFjGy.js";
|
|
4
4
|
import { n as replyTargetOf, r as shortenHome } from "./initMsg-BEVDWYnv.js";
|
|
5
|
-
import { t as resolveSpawner } from "./parentLink-
|
|
5
|
+
import { t as resolveSpawner } from "./parentLink-UiM6WoKm.js";
|
|
6
6
|
import { spawn } from "node:child_process";
|
|
7
7
|
|
|
8
8
|
//#region ts/parentPing.ts
|
|
@@ -338,7 +338,7 @@ async function isParentWatching(parentWrapperPid, parentAgentPid, selfAgentPid,
|
|
|
338
338
|
logger.debug("[parent-ping] watcher lookup failed:", error);
|
|
339
339
|
}
|
|
340
340
|
try {
|
|
341
|
-
const { lastReadAt, READ_WINDOW_MS } = await import("./subcommands-
|
|
341
|
+
const { lastReadAt, READ_WINDOW_MS } = await import("./subcommands-CcjH2sFA.js");
|
|
342
342
|
const last = await lastReadAt(`agent:${parentAgentPid}`, selfAgentPid);
|
|
343
343
|
if (last !== null && now - last <= READ_WINDOW_MS) return true;
|
|
344
344
|
} catch (error) {
|
|
@@ -466,4 +466,4 @@ function startParentPingLoop(opts) {
|
|
|
466
466
|
|
|
467
467
|
//#endregion
|
|
468
468
|
export { startParentPingLoop };
|
|
469
|
-
//# sourceMappingURL=parentPingLoop-
|
|
469
|
+
//# sourceMappingURL=parentPingLoop-9INbUyK5.js.map
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
import { n as logger } from "./logger-CDIsZ-Pp.js";
|
|
2
2
|
import { t as agentYesHome } from "./agentYesHome-JmJC28YX.js";
|
|
3
3
|
import { t as JsonlStore } from "./JsonlStore-CB_0sfdT.js";
|
|
4
|
-
import {
|
|
4
|
+
import { a as pruneOldLogs, c as updateGlobalPidStatus, i as maybeCompactGlobalPids, t as appendGlobalPid } from "./globalPidIndex-C6p_AY4D.js";
|
|
5
5
|
import { mkdir, writeFile } from "fs/promises";
|
|
6
6
|
import path from "path";
|
|
7
7
|
import { randomBytes } from "node:crypto";
|
|
@@ -197,4 +197,4 @@ pid-db/
|
|
|
197
197
|
|
|
198
198
|
//#endregion
|
|
199
199
|
export { PidStore as t };
|
|
200
|
-
//# sourceMappingURL=pidStore-
|
|
200
|
+
//# sourceMappingURL=pidStore-DUXifdBr.js.map
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import "./versionChecker-
|
|
2
|
-
import { a as ensureExecutable, c as findSpawnHiddenLauncher, d as getBinDir, f as getBinaryName, h as hasValidMacSignature, i as ensureAyrsBinary, l as findTrayLauncher, m as getRustBinary, n as devBuildInfo, o as findAyrsBinary, p as getDownloadUrl, r as downloadBinary, s as findRustBinary, t as chmodExtractedBinaries, u as gcOldBinaryDirs } from "./rustBinary-
|
|
1
|
+
import "./versionChecker-DHFAiPhh.js";
|
|
2
|
+
import { a as ensureExecutable, c as findSpawnHiddenLauncher, d as getBinDir, f as getBinaryName, h as hasValidMacSignature, i as ensureAyrsBinary, l as findTrayLauncher, m as getRustBinary, n as devBuildInfo, o as findAyrsBinary, p as getDownloadUrl, r as downloadBinary, s as findRustBinary, t as chmodExtractedBinaries, u as gcOldBinaryDirs } from "./rustBinary-xlvjV_pG.js";
|
|
3
3
|
|
|
4
4
|
export { ensureAyrsBinary, findAyrsBinary, gcOldBinaryDirs };
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { i as getInstalledPackage, n as compareVersions } from "./versionChecker-
|
|
1
|
+
import { i as getInstalledPackage, n as compareVersions } from "./versionChecker-DHFAiPhh.js";
|
|
2
2
|
import { execFileSync } from "child_process";
|
|
3
3
|
import { accessSync, chmodSync, constants, existsSync, mkdirSync, readdirSync, rmSync, statSync, unlinkSync } from "fs";
|
|
4
4
|
import { chmod, copyFile } from "fs/promises";
|
|
@@ -435,4 +435,4 @@ async function getRustBinary(options = {}) {
|
|
|
435
435
|
|
|
436
436
|
//#endregion
|
|
437
437
|
export { ensureExecutable as a, findSpawnHiddenLauncher as c, getBinDir as d, getBinaryName as f, hasValidMacSignature as h, ensureAyrsBinary as i, findTrayLauncher as l, getRustBinary as m, devBuildInfo as n, findAyrsBinary as o, getDownloadUrl as p, downloadBinary as r, findRustBinary as s, chmodExtractedBinaries as t, gcOldBinaryDirs as u };
|
|
438
|
-
//# sourceMappingURL=rustBinary-
|
|
438
|
+
//# sourceMappingURL=rustBinary-xlvjV_pG.js.map
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import "./versionChecker-
|
|
3
|
-
import "./ts-
|
|
2
|
+
import "./versionChecker-DHFAiPhh.js";
|
|
3
|
+
import "./ts-D6Tu7Lev.js";
|
|
4
4
|
import "./todoAutomation-CKlrxuZv.js";
|
|
5
5
|
import "./JsonlStore-CB_0sfdT.js";
|
|
6
|
-
import "./globalPidIndex-
|
|
7
|
-
import "./pidStore-
|
|
6
|
+
import "./globalPidIndex-C6p_AY4D.js";
|
|
7
|
+
import "./pidStore-DUXifdBr.js";
|
|
8
8
|
import "./messageLog-Dq_ka-Bt.js";
|
|
9
9
|
import "./todoStore-msRCEUi1.js";
|
|
10
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
10
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-Z026oWlt.js";
|
|
11
11
|
import { n as liveEnv, t as ensureNodeRuntime } from "./nodeRuntime-DGMQRTGT.js";
|
|
12
12
|
import { t as ensureBootAutostart } from "./oxmgrService-DlYHmqyI.js";
|
|
13
13
|
import { f as resolveSpawnCwd } from "./workspaceConfig-DBgsu81B.js";
|
|
@@ -125,4 +125,4 @@ async function cmdSchedule(rest) {
|
|
|
125
125
|
|
|
126
126
|
//#endregion
|
|
127
127
|
export { cmdSchedule };
|
|
128
|
-
//# sourceMappingURL=schedule-
|
|
128
|
+
//# sourceMappingURL=schedule-DL_WFsLJ.js.map
|
|
@@ -1,31 +1,31 @@
|
|
|
1
1
|
import "./logger-CDIsZ-Pp.js";
|
|
2
|
-
import { i as getInstalledPackage } from "./versionChecker-
|
|
3
|
-
import { c 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 { i as getInstalledPackage } from "./versionChecker-DHFAiPhh.js";
|
|
3
|
+
import { c as findSpawnHiddenLauncher } from "./rustBinary-xlvjV_pG.js";
|
|
4
|
+
import { c as permissionBadge, i as answerAsk, o as listAsks, u as CLAUDE_SESSION_PIN_ENV } from "./ts-D6Tu7Lev.js";
|
|
5
5
|
import { t as agentYesHome$1 } from "./agentYesHome-JmJC28YX.js";
|
|
6
6
|
import { u as removeControlCharacters } from "./todoAutomation-CKlrxuZv.js";
|
|
7
7
|
import "./JsonlStore-CB_0sfdT.js";
|
|
8
|
-
import {
|
|
9
|
-
import "./pidStore-
|
|
8
|
+
import { c as updateGlobalPidStatus } from "./globalPidIndex-C6p_AY4D.js";
|
|
9
|
+
import "./pidStore-DUXifdBr.js";
|
|
10
10
|
import { r as recordInbox, s as isTerminalReply } from "./messageLog-Dq_ka-Bt.js";
|
|
11
11
|
import "./todoStore-msRCEUi1.js";
|
|
12
12
|
import "./e2e-BdLf8DvY.js";
|
|
13
13
|
import "./configShared-De4bR5hH.js";
|
|
14
|
-
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-
|
|
15
|
-
import { $ as readNotes, Ct as
|
|
14
|
+
import { t as SUPPORTED_CLIS } from "./SUPPORTED_CLIS-Z026oWlt.js";
|
|
15
|
+
import { $ as readNotes, Ct as withIpcLock, D as extractNeedsInput, Et as TYPING_BADGE, G as listRecords, H as isUserTyping, L as isSlashCommand, O as extractTaskCounts, Q as readLogForRender, St as resolveWorkDir, T as extractBadges, Tt as shouldFramePaste, at as renderRawLogLines, b as deriveLiveStatus, et as readPtysize, g as controlCodeFromName, it as renderRawLog, nt as recentReadEdges, ot as resolveOne, p as cliDefaults, pt as snapshotStatus, rt as renderLogTailLines, tt as recentMessageEdges, wt as framePaste, xt as writeToIpc } from "./subcommands-GdGWUii6.js";
|
|
16
16
|
import { i as isWebrtcSpec, o as toWebrtcUrl } from "./webrtcLink-DcvacEci.js";
|
|
17
17
|
import "./remotes-BsMGvAay.js";
|
|
18
18
|
import "./roomReplyAlias-B-v76TA8.js";
|
|
19
19
|
import { c as isTransientLockMkdirError } from "./notifyStore-DIfkfKB2.js";
|
|
20
20
|
import "./senderAncestry-CVHeKk1Y.js";
|
|
21
21
|
import { i as frameVisitorMessage, s as verifyCapability, t as MAX_CALLBACK_MSG_BYTES } from "./callbackCore-Deve5pv3.js";
|
|
22
|
-
import { n as isCallbackRevoked, r as loadCallbackSecretReadOnly } from "./callback-
|
|
22
|
+
import { n as isCallbackRevoked, r as loadCallbackSecretReadOnly } from "./callback-BUwH7ySJ.js";
|
|
23
23
|
import { n as sampleTrees } from "./procStats-DwTxj3rs.js";
|
|
24
24
|
import { n as liveEnv, t as ensureNodeRuntime } from "./nodeRuntime-DGMQRTGT.js";
|
|
25
25
|
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-DBgsu81B.js";
|
|
26
|
-
import { i as importProvisionModule } from "./ws-
|
|
27
|
-
import { r as spawnRejectionReason } from "./spawnGate-
|
|
28
|
-
import { i as launchTray } from "./trayApp-
|
|
26
|
+
import { i as importProvisionModule } from "./ws-DLhUK2dn.js";
|
|
27
|
+
import { r as spawnRejectionReason } from "./spawnGate-3YSXiRFS.js";
|
|
28
|
+
import { i as launchTray } from "./trayApp-BumYIh0H.js";
|
|
29
29
|
import { existsSync, realpathSync, renameSync, watch, writeFileSync } from "node:fs";
|
|
30
30
|
import yargs from "yargs";
|
|
31
31
|
import { appendFile, mkdir, open, readFile, readdir, rename, rm, stat, unlink, writeFile } from "fs/promises";
|
|
@@ -1347,7 +1347,7 @@ async function warnStrayServeProcesses() {
|
|
|
1347
1347
|
}
|
|
1348
1348
|
async function daemonShareRuntime(args) {
|
|
1349
1349
|
const { daemonShareRuntime: decide } = await import("./serveRust-BfWkeL6T.js");
|
|
1350
|
-
const { findAyrsBinary } = await import("./rustBinary-
|
|
1350
|
+
const { findAyrsBinary } = await import("./rustBinary-Pf8XKYRk.js");
|
|
1351
1351
|
return decide(args, () => !!findAyrsBinary());
|
|
1352
1352
|
}
|
|
1353
1353
|
function explicitWebrtcUrl(args) {
|
|
@@ -1645,7 +1645,7 @@ async function cmdServeStatus(args) {
|
|
|
1645
1645
|
const token = await loadTokenReadOnly();
|
|
1646
1646
|
const daemonArgs = mgr ? await readDaemonServeArgs(mgr) : null;
|
|
1647
1647
|
const installed = daemonArgs !== null;
|
|
1648
|
-
const { daemonShareLink, foregroundAyrsShareLink } = await import("./shareCmd-
|
|
1648
|
+
const { daemonShareLink, foregroundAyrsShareLink } = await import("./shareCmd-UV7Q6Ncm.js");
|
|
1649
1649
|
const shareLink = (installed ? await daemonShareLink(daemonArgs) : await foregroundAyrsShareLink()) ?? await readShareLink();
|
|
1650
1650
|
const running = installed ? await readDaemonRunning(mgr) : false;
|
|
1651
1651
|
const a = daemonArgs ?? [];
|
|
@@ -1779,14 +1779,14 @@ Options:
|
|
|
1779
1779
|
const { planRustServe, SERVE_SUBCOMMANDS } = await import("./serveRust-BfWkeL6T.js");
|
|
1780
1780
|
const plan = planRustServe(rest);
|
|
1781
1781
|
if (plan.kind === "rust-only") {
|
|
1782
|
-
const { ensureAyrsBinary } = await import("./rustBinary-
|
|
1782
|
+
const { ensureAyrsBinary } = await import("./rustBinary-Pf8XKYRk.js");
|
|
1783
1783
|
const ayrs = await ensureAyrsBinary();
|
|
1784
1784
|
if (ayrs) return runAyrsServe(ayrs, plan.argv);
|
|
1785
1785
|
process.stderr.write(`ay serve: ${plan.feature} needs the Rust daemon (ayrs), which was not found (bun run build:rs, or reinstall)\n`);
|
|
1786
1786
|
return 1;
|
|
1787
1787
|
}
|
|
1788
1788
|
if (plan.kind === "rust") {
|
|
1789
|
-
const { ensureAyrsBinary } = await import("./rustBinary-
|
|
1789
|
+
const { ensureAyrsBinary } = await import("./rustBinary-Pf8XKYRk.js");
|
|
1790
1790
|
const ayrs = await ensureAyrsBinary();
|
|
1791
1791
|
if (ayrs) return runAyrsServe(ayrs, plan.argv);
|
|
1792
1792
|
process.stderr.write("ay serve: ayrs binary not found — running the TypeScript server (bun run build:rs, or reinstall, to get the Rust daemon)\n");
|
|
@@ -2166,15 +2166,17 @@ Options:
|
|
|
2166
2166
|
const question = status !== "exited" && !r.unresponsive ? await logNeedsInput(r.log_file, r.cli) : null;
|
|
2167
2167
|
const lastActiveAt = r.log_file ? await stat(r.log_file).then((s) => s.mtimeMs).catch(() => r.started_at) : r.started_at;
|
|
2168
2168
|
const lastStdinAt = status !== "exited" ? await resolveLastStdinAt(r) : null;
|
|
2169
|
+
const where = await resolveWorkDir(r);
|
|
2169
2170
|
return {
|
|
2170
2171
|
...r,
|
|
2172
|
+
...where,
|
|
2171
2173
|
last_active_at: lastActiveAt,
|
|
2172
2174
|
last_stdin_at: lastStdinAt,
|
|
2173
2175
|
status: status === "exited" ? status : r.unresponsive ? "stuck" : question ? "needs_input" : status,
|
|
2174
2176
|
question,
|
|
2175
2177
|
title: await logTitle(r.log_file),
|
|
2176
2178
|
status_text: status === "exited" ? null : await logStatusText(r.log_file),
|
|
2177
|
-
git: status === "exited" ? null : await gitStatus(
|
|
2179
|
+
git: status === "exited" ? null : await gitStatus(where.workdir),
|
|
2178
2180
|
tasks: status === "exited" ? null : await logTasks(r.log_file),
|
|
2179
2181
|
badges: status === "exited" ? [] : await logBadges(r.log_file).then(async (b) => await isUserTyping(r.pid) ? [...b, TYPING_BADGE.id] : b),
|
|
2180
2182
|
res: resField(r.pid)
|
|
@@ -2776,7 +2778,7 @@ Options:
|
|
|
2776
2778
|
}
|
|
2777
2779
|
});
|
|
2778
2780
|
if (req.method === "GET" && p === "/api/ws") {
|
|
2779
|
-
const ws = await import("./ws-
|
|
2781
|
+
const ws = await import("./ws-oRDepI0t.js");
|
|
2780
2782
|
try {
|
|
2781
2783
|
await ws.loadProvision();
|
|
2782
2784
|
} catch (e) {
|
|
@@ -2796,7 +2798,7 @@ Options:
|
|
|
2796
2798
|
if (req.method === "GET" && p === "/api/ws/status") {
|
|
2797
2799
|
const dirRaw = url.searchParams.get("path");
|
|
2798
2800
|
if (!dirRaw) return new Response("missing ?path=<workspace dir>", { status: 400 });
|
|
2799
|
-
const ws = await import("./ws-
|
|
2801
|
+
const ws = await import("./ws-oRDepI0t.js");
|
|
2800
2802
|
let prov;
|
|
2801
2803
|
try {
|
|
2802
2804
|
prov = await ws.loadProvision();
|
|
@@ -2818,7 +2820,7 @@ Options:
|
|
|
2818
2820
|
}
|
|
2819
2821
|
}
|
|
2820
2822
|
if (req.method === "GET" && p === "/api/ws/repos") {
|
|
2821
|
-
const ws = await import("./ws-
|
|
2823
|
+
const ws = await import("./ws-oRDepI0t.js");
|
|
2822
2824
|
try {
|
|
2823
2825
|
await ws.loadProvision();
|
|
2824
2826
|
} catch (e) {
|
|
@@ -2899,7 +2901,7 @@ Options:
|
|
|
2899
2901
|
const m = /^([A-Za-z0-9_.-]+)\/([A-Za-z0-9_.-]+)$/.exec(repoParam);
|
|
2900
2902
|
if (!m || m[1] === "." || m[1] === ".." || m[2] === "." || m[2] === "..") return new Response("missing/invalid ?repo=<owner>/<repo>", { status: 400 });
|
|
2901
2903
|
const [, owner, repo] = m;
|
|
2902
|
-
const ws = await import("./ws-
|
|
2904
|
+
const ws = await import("./ws-oRDepI0t.js");
|
|
2903
2905
|
let prov;
|
|
2904
2906
|
try {
|
|
2905
2907
|
prov = await ws.loadProvision();
|
|
@@ -3810,7 +3812,7 @@ Options:
|
|
|
3810
3812
|
const perm = body.perm ?? "r";
|
|
3811
3813
|
if (perm !== "r" && perm !== "rw") return new Response(`invalid perm ${perm} (want r or rw)`, { status: 400 });
|
|
3812
3814
|
try {
|
|
3813
|
-
const { createScopedShare } = await import("./agentShare-
|
|
3815
|
+
const { createScopedShare } = await import("./agentShare-mG8mFEc3.js");
|
|
3814
3816
|
const share = await createScopedShare({
|
|
3815
3817
|
agent: body.agent,
|
|
3816
3818
|
perm,
|
|
@@ -3825,12 +3827,12 @@ Options:
|
|
|
3825
3827
|
}
|
|
3826
3828
|
}
|
|
3827
3829
|
if (req.method === "GET" && p === "/api/shares") {
|
|
3828
|
-
const { listShares } = await import("./agentShare-
|
|
3830
|
+
const { listShares } = await import("./agentShare-mG8mFEc3.js");
|
|
3829
3831
|
return Response.json(listShares());
|
|
3830
3832
|
}
|
|
3831
3833
|
const revokeM = /^\/api\/share\/([^/]+)$/.exec(p);
|
|
3832
3834
|
if (req.method === "DELETE" && revokeM) {
|
|
3833
|
-
const { revokeShare } = await import("./agentShare-
|
|
3835
|
+
const { revokeShare } = await import("./agentShare-mG8mFEc3.js");
|
|
3834
3836
|
const ok = revokeShare(decodeURIComponent(revokeM[1]));
|
|
3835
3837
|
return new Response(ok ? "revoked" : "no such share", { status: ok ? 200 : 404 });
|
|
3836
3838
|
}
|
|
@@ -4142,7 +4144,7 @@ Options:
|
|
|
4142
4144
|
const shutdown = (resolve) => {
|
|
4143
4145
|
if (heartbeat) clearInterval(heartbeat);
|
|
4144
4146
|
closeShare?.();
|
|
4145
|
-
import("./agentShare-
|
|
4147
|
+
import("./agentShare-mG8mFEc3.js").then((m) => m.revokeAllShares()).catch(() => {});
|
|
4146
4148
|
server?.stop();
|
|
4147
4149
|
Promise.resolve(releaseHostLock?.()).catch(() => {}).then(resolve);
|
|
4148
4150
|
};
|
|
@@ -4155,4 +4157,4 @@ Options:
|
|
|
4155
4157
|
|
|
4156
4158
|
//#endregion
|
|
4157
4159
|
export { cmdServe, inspectServeDaemon, loadTokenReadOnly, mintScopedTermToken, resolveDaemonHttpBase, resolveLocalServeUrl };
|
|
4158
|
-
//# sourceMappingURL=serve-
|
|
4160
|
+
//# sourceMappingURL=serve-Do7L7okz.js.map
|