@wirecat/zoom-cli 0.71.0 → 0.72.0
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/answers.d.ts +56 -0
- package/dist/answers.d.ts.map +1 -1
- package/dist/bin/zm.js +2 -2
- package/dist/bundle/{all-profiles-O4YNVPZX.js → all-profiles-XFIPF4GF.js} +12 -12
- package/dist/bundle/answer-policy-AT6CDEE5.js +110 -0
- package/dist/bundle/{anthropic-7GGRX3RX.js → anthropic-SSUBR3BC.js} +18 -11
- package/dist/bundle/{app-server-CPMKM3HI.js → app-server-7DJHHF2F.js} +68 -56
- package/dist/bundle/{bun-POHZKEPV.js → bun-6HBYWQIX.js} +2 -2
- package/dist/bundle/{bun-sqlite-PGYMBPEL.js → bun-sqlite-4L3Q55NB.js} +10 -6
- package/dist/bundle/{chunk-Q2SUFGSH.js → chunk-23J2ANZ7.js} +2 -2
- package/dist/bundle/{chunk-FSHCAWZS.js → chunk-24OFZNRC.js} +13119 -10386
- package/dist/bundle/{chunk-LE7MDAQG.js → chunk-2MIBRVSV.js} +2 -2
- package/dist/bundle/{chunk-DIQLXAAZ.js → chunk-37NF5CBJ.js} +4 -4
- package/dist/bundle/chunk-3KRTEX5M.js +53 -0
- package/dist/bundle/{chunk-IED3NS7G.js → chunk-4SY67IUA.js} +30 -30
- package/dist/bundle/{chunk-CKPCVEXU.js → chunk-4XQWF3U2.js} +6 -6
- package/dist/bundle/{chunk-CT4WVR4N.js → chunk-4YIGXTBP.js} +3 -3
- package/dist/bundle/{chunk-YPO2U2YB.js → chunk-5AELTC52.js} +388 -143
- package/dist/bundle/{chunk-USQ23X5V.js → chunk-5MGICK47.js} +750 -734
- package/dist/bundle/{chunk-DK6ICIGL.js → chunk-5X4IY5JH.js} +2025 -1302
- package/dist/bundle/{chunk-EOSVN2ER.js → chunk-63QXCE5Z.js} +242 -242
- package/dist/bundle/{chunk-OE7EIP5L.js → chunk-6DCLZLGX.js} +1 -1
- package/dist/bundle/chunk-7GLJSJ7M.js +16 -0
- package/dist/bundle/{chunk-X3ZDN3U7.js → chunk-7IFO43Q5.js} +2 -2
- package/dist/bundle/{chunk-YD2RYVMK.js → chunk-7JYMGXLI.js} +41 -39
- package/dist/bundle/{chunk-DSVZEXYJ.js → chunk-7OD3522V.js} +3541 -3346
- package/dist/bundle/{chunk-2FV5JUQU.js → chunk-7S4D5SM2.js} +41 -35
- package/dist/bundle/{chunk-VRH7VRTK.js → chunk-7SUWPMZG.js} +10 -15
- package/dist/bundle/{chunk-4QPQ7MDA.js → chunk-ADKMBXY4.js} +1 -1
- package/dist/bundle/{chunk-MRI6QMZ3.js → chunk-B3SILJBU.js} +18 -18
- package/dist/bundle/{chunk-7ROXXRGG.js → chunk-CANRIRNZ.js} +6678 -5185
- package/dist/bundle/{chunk-DRBQDCDU.js → chunk-CW46FWKW.js} +38 -123
- package/dist/bundle/{chunk-GXF5HFFP.js → chunk-D24OQAHM.js} +4 -4
- package/dist/bundle/{chunk-ZBKWRYRS.js → chunk-D5EUMWD5.js} +3 -3
- package/dist/bundle/{chunk-QVSLSWAL.js → chunk-DEPXZJ2V.js} +21 -150
- package/dist/bundle/{chunk-TM4JSVGQ.js → chunk-DOCVEKP2.js} +39 -44
- package/dist/bundle/{chunk-BBTQIVFP.js → chunk-EFF2XBHP.js} +2 -2
- package/dist/bundle/{chunk-XRFHQGOD.js → chunk-EG25AY4L.js} +1 -1
- package/dist/bundle/{chunk-FEM2JQN2.js → chunk-ELJUBPY4.js} +1 -1
- package/dist/bundle/{chunk-2U6SER67.js → chunk-ERJYJ36F.js} +2 -2
- package/dist/bundle/chunk-FSCPQQS5.js +244 -0
- package/dist/bundle/{chunk-P3XC6EDU.js → chunk-H53WFZBN.js} +11 -130
- package/dist/bundle/{chunk-RN4EHCC5.js → chunk-I7CUMZD6.js} +3 -3
- package/dist/bundle/{chunk-ALIT5QFT.js → chunk-IACWKZWS.js} +1 -1
- package/dist/bundle/{chunk-MW4EGDDV.js → chunk-IFBIXU6C.js} +2 -2
- package/dist/bundle/{chunk-5K7OGPGA.js → chunk-IU4DUUB3.js} +7 -7
- package/dist/bundle/{chunk-INVTDIF6.js → chunk-IXO4SCKE.js} +1 -1
- package/dist/bundle/{chunk-OHWMIUCT.js → chunk-JAEPK457.js} +244 -245
- package/dist/bundle/{chunk-HB6XJQ3Y.js → chunk-JFPUYQSP.js} +5 -5
- package/dist/bundle/{chunk-IAV5BG3I.js → chunk-JG4MNYG2.js} +1 -1
- package/dist/bundle/{chunk-ZBFL5JPT.js → chunk-JRCH4YZP.js} +16 -10
- package/dist/bundle/{chunk-M76MXMLY.js → chunk-JZ4XNNL7.js} +1 -1
- package/dist/bundle/chunk-K6HR6HCO.js +32 -0
- package/dist/bundle/{chunk-DHWBSXG3.js → chunk-KFZL67JP.js} +323 -55
- package/dist/bundle/{chunk-X4GWR6GO.js → chunk-KPIQXFNB.js} +375 -10
- package/dist/bundle/{chunk-OWEBWDHV.js → chunk-KWURWGGB.js} +80 -5
- package/dist/bundle/{chunk-Q5PI72CR.js → chunk-LA6QUVGQ.js} +3 -2
- package/dist/bundle/{chunk-5J4AMBMM.js → chunk-LLUNHAZ7.js} +4 -4
- package/dist/bundle/{chunk-2RUAMDVV.js → chunk-LTWJM3ED.js} +17 -17
- package/dist/bundle/{chunk-2U27KIKU.js → chunk-M3DMXDX6.js} +6 -6
- package/dist/bundle/{chunk-VW6BF6M7.js → chunk-MCPOZNWG.js} +1 -1
- package/dist/bundle/{chunk-CRFOGYDG.js → chunk-MSQHSW4C.js} +2 -2
- package/dist/bundle/chunk-N4QNYWWG.js +71 -0
- package/dist/bundle/chunk-NMZQTYKJ.js +18 -0
- package/dist/bundle/{chunk-2KESWII5.js → chunk-OHCLQJOV.js} +3 -3
- package/dist/bundle/{chunk-4QUFFB2U.js → chunk-OP5PGE2N.js} +4 -4
- package/dist/bundle/{chunk-Q3XLZIY3.js → chunk-OY6N2ABP.js} +29 -23
- package/dist/bundle/chunk-PJWSGXOB.js +185 -0
- package/dist/bundle/{chunk-633QXP57.js → chunk-QA6KIL7Q.js} +10 -8
- package/dist/bundle/{chunk-N2FNMION.js → chunk-QQUY4MZY.js} +1 -1
- package/dist/bundle/{chunk-X277FBTF.js → chunk-QW7YTRV2.js} +3 -3
- package/dist/bundle/chunk-RJTGENHZ.js +109 -0
- package/dist/bundle/{chunk-ULDXZ6LH.js → chunk-RLCVPECY.js} +63 -63
- package/dist/bundle/{chunk-BGTEVIW4.js → chunk-RN5SU2RN.js} +6 -6
- package/dist/bundle/{chunk-P3ASN72F.js → chunk-RX5CJ55S.js} +1 -1
- package/dist/bundle/{chunk-7QC4M4HS.js → chunk-RZUJMAMK.js} +4 -4
- package/dist/bundle/{chunk-OORMSM6O.js → chunk-S7SXSHRC.js} +21 -21
- package/dist/bundle/{chunk-GGS6D4W4.js → chunk-SXZGCD6E.js} +3 -3
- package/dist/bundle/{chunk-64ZHF6PJ.js → chunk-T27IMG6X.js} +3 -1
- package/dist/bundle/{chunk-VJXHIUFP.js → chunk-TF2WKPNW.js} +15 -15
- package/dist/bundle/{chunk-QTHIU7CO.js → chunk-U32VL3MA.js} +1 -1
- package/dist/bundle/{chunk-RQG5VOGH.js → chunk-U3NJBGLA.js} +3 -3
- package/dist/bundle/{chunk-WOIHSQAL.js → chunk-UVZLK3M4.js} +33 -9
- package/dist/bundle/{chunk-XI3VIQKW.js → chunk-VIV64MQM.js} +560 -537
- package/dist/bundle/{chunk-CFQF6IGY.js → chunk-W3YTVEWV.js} +69 -6
- package/dist/bundle/{chunk-54YDWBYG.js → chunk-WLVG4RBZ.js} +1 -1
- package/dist/bundle/{chunk-77TCCHMP.js → chunk-WOAYHCM2.js} +1 -1
- package/dist/bundle/{chunk-5LJTU4LY.js → chunk-WXTYYWZI.js} +13 -13
- package/dist/bundle/{chunk-MEED7YFG.js → chunk-WZGKHTA4.js} +2 -2
- package/dist/bundle/{chunk-I4DFFR7F.js → chunk-X2MP634F.js} +14 -5
- package/dist/bundle/{chunk-RGJ7OWHU.js → chunk-XPWZSW6Y.js} +61 -21
- package/dist/bundle/{chunk-SELXER2Q.js → chunk-YVVJ6Y5C.js} +7 -7
- package/dist/bundle/{chunk-4LAQDZXU.js → chunk-ZHA56THL.js} +790 -70
- package/dist/bundle/{chunk-ZVI6TFQR.js → chunk-ZVFYGTGJ.js} +17 -17
- package/dist/bundle/{chunk-GL3MYFMX.js → chunk-ZW5KHKMA.js} +5 -5
- package/dist/bundle/{cli-KHMEUXNG.js → cli-IYYI7GAM.js} +158 -96
- package/dist/bundle/command-contract-TX7NSUBM.js +42 -0
- package/dist/bundle/command-server-entry-FXX4LJWF.js +171 -0
- package/dist/bundle/config-YKNM33J7.js +96 -0
- package/dist/bundle/{decode-7RP4HSVE.js → decode-SRGOOGBW.js} +6 -6
- package/dist/bundle/{dispatch-IZCAK47P.js → dispatch-OUHRPFUL.js} +11 -11
- package/dist/bundle/{dist-BFT2SUBV.js → dist-UZLNLAIO.js} +52 -31
- package/dist/bundle/{echarts-T2BSQ2YV.js → echarts-7CM2MCMW.js} +2 -2
- package/dist/bundle/{embed-BAS6YPDT.js → embed-VEE56BOB.js} +7 -7
- package/dist/bundle/{embedder-5XD5FCAO.js → embedder-SZFYR543.js} +10 -10
- package/dist/bundle/{failure-R2OIHCE5.js → failure-MZBNM7M5.js} +3 -3
- package/dist/bundle/first-run-KWC7RKF2.js +29 -0
- package/dist/bundle/first-screen-DWKMNSEI.js +40 -0
- package/dist/bundle/{folders-ZXTOFY4T.js → folders-UQXRSDJJ.js} +5 -5
- package/dist/bundle/{instructions-XZPROPKY.js → instructions-R7OHVAWH.js} +1 -1
- package/dist/bundle/{main-TZXKGL3L.js → main-EFUN2O3K.js} +21 -20
- package/dist/bundle/{mcp-M4QN2E7R.js → mcp-7KQUJNFN.js} +2 -2
- package/dist/bundle/{meetings-JB2ISPND.js → meetings-5I2BDNTA.js} +7 -7
- package/dist/bundle/{node-A3B3MJWX.js → node-3N2JGZ7V.js} +2 -2
- package/dist/bundle/{node-sqlite-QVWDLGDX.js → node-sqlite-2UVEE2WM.js} +11 -7
- package/dist/bundle/{oauth-YA6IYV4O.js → oauth-AYGD7UU3.js} +8 -8
- package/dist/bundle/{open-SY7TXJBS.js → open-3GUVDLGD.js} +6 -6
- package/dist/bundle/openai-NHCDLWWY.js +28 -0
- package/dist/bundle/{output-file-YGQYZCBJ.js → output-file-72JFXVHQ.js} +6 -6
- package/dist/bundle/{process-6HNBTJIY.js → process-YAHHUFR5.js} +1 -1
- package/dist/bundle/{program-77BUCJ4H.js → program-OSZROCTK.js} +97 -91
- package/dist/bundle/{prompt-YDG73YDS.js → prompt-HMCW4XQJ.js} +6 -6
- package/dist/bundle/{recognize-ECXDGTB7.js → recognize-VF5CA7EM.js} +5 -5
- package/dist/bundle/{remote-K4JHGBVJ.js → remote-5C6VTPR2.js} +10 -8
- package/dist/bundle/{rerank-IU2YYD4T.js → rerank-ER7NEDOI.js} +8 -8
- package/dist/bundle/run-log-JKTLKXSK.js +124 -0
- package/dist/bundle/{serve-3XWIF3HI.js → serve-QJWXJOM7.js} +10 -10
- package/dist/bundle/{server-56VYOHWP.js → server-KCIK3Y2P.js} +50 -48
- package/dist/bundle/server-LLGFDLLJ.js +75 -0
- package/dist/bundle/{services-X7IPEGQ5.js → services-LQMYJQG3.js} +62 -45
- package/dist/bundle/{speech-E2OBQWYA.js → speech-74GJQNQH.js} +20 -17
- package/dist/bundle/{state-4GMJYK4H.js → state-4XDGCHDF.js} +7 -7
- package/dist/bundle/{store-LA4TV4DM.js → store-5Y5HK2L2.js} +22 -19
- package/dist/bundle/{store-KPI7GB5Y.js → store-Y56AHJ2Y.js} +42 -27
- package/dist/bundle/store-connection-4WI32AYU.js +89 -0
- package/dist/bundle/store-maintenance-command-PCXO5AH4.js +65 -0
- package/dist/bundle/{streaming-EJ3NM2C2.js → streaming-E5CR6HSR.js} +7 -7
- package/dist/bundle/{tokens-BE6CJMR5.js → tokens-E2QNVC4F.js} +7 -7
- package/dist/bundle/zm.js +34 -10
- package/dist/bundle/{zoom-app-QEJBTIJ4.js → zoom-app-NVL7HEAX.js} +8 -8
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/package.json +3 -3
- package/dist/bundle/answer-policy-PPSPMCLH.js +0 -104
- package/dist/bundle/chunk-KMV7GZB6.js +0 -35
- package/dist/bundle/chunk-UG447QY2.js +0 -27
- package/dist/bundle/command-contract-4K6XXZYE.js +0 -41
- package/dist/bundle/config-EEDB632I.js +0 -90
- package/dist/bundle/first-run-23WWZ2PW.js +0 -28
- package/dist/bundle/first-screen-6HFUYVFR.js +0 -39
- package/dist/bundle/openai-2AU24NRN.js +0 -25
- package/dist/bundle/run-log-LFEXNZ74.js +0 -118
- package/dist/bundle/server-YSTMUZ22.js +0 -72
- package/dist/bundle/store-connection-AZTIF6IH.js +0 -83
- package/dist/bundle/store-maintenance-command-LR572PS4.js +0 -61
- /package/dist/bundle/{chunk-VOXIGICJ.js → chunk-YVNHQFLC.js} +0 -0
|
@@ -1,22 +1,16 @@
|
|
|
1
1
|
import { createRequire as __bundleRequire } from "node:module";
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
|
-
import {
|
|
4
|
-
LEVELS
|
|
5
|
-
} from "./chunk-Q5PI72CR.js";
|
|
6
3
|
import {
|
|
7
4
|
WORD_BODY,
|
|
8
5
|
e164Of
|
|
9
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-ZHA56THL.js";
|
|
10
7
|
import {
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
providerLabel,
|
|
14
|
-
providerNamed
|
|
15
|
-
} from "./chunk-XI3VIQKW.js";
|
|
8
|
+
LEVELS
|
|
9
|
+
} from "./chunk-LA6QUVGQ.js";
|
|
16
10
|
import {
|
|
17
11
|
resolvePaths,
|
|
18
12
|
writeSecurely
|
|
19
|
-
} from "./chunk-
|
|
13
|
+
} from "./chunk-S7SXSHRC.js";
|
|
20
14
|
import {
|
|
21
15
|
array,
|
|
22
16
|
getDotPath,
|
|
@@ -35,124 +29,18 @@ import {
|
|
|
35
29
|
string,
|
|
36
30
|
transform,
|
|
37
31
|
unknown
|
|
38
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-UVZLK3M4.js";
|
|
39
33
|
import {
|
|
40
34
|
CliError
|
|
41
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-ELJUBPY4.js";
|
|
42
36
|
import {
|
|
43
|
-
singleLine,
|
|
44
37
|
visibleControls
|
|
45
|
-
} from "./chunk-
|
|
38
|
+
} from "./chunk-6DCLZLGX.js";
|
|
46
39
|
import {
|
|
47
40
|
__name
|
|
48
41
|
} from "./chunk-ZVVMGPBJ.js";
|
|
49
42
|
|
|
50
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
51
|
-
var TAKES = {
|
|
52
|
-
chat: "a chat: chat:<provider>/<account>/<chat>, its id or its title",
|
|
53
|
-
message: "a message: msg:<provider>/<account>/<chat>/<message>, or a chat and the message's id"
|
|
54
|
-
};
|
|
55
|
-
var article = /* @__PURE__ */ __name((word) => /^[aeiou]/.test(word) ? "an" : "a", "article");
|
|
56
|
-
var wrongKind = /* @__PURE__ */ __name((text, kind, takes) => new CliError("validation_error", `${text} names ${article(kind)} ${kind}; this takes ${TAKES[takes]}`, {
|
|
57
|
-
reason: "ref.wrong-kind"
|
|
58
|
-
}), "wrongKind");
|
|
59
|
-
var wrongProvider = /* @__PURE__ */ __name((text, provider, kind) => {
|
|
60
|
-
const entry = providerNamed(provider);
|
|
61
|
-
const command = entry?.command;
|
|
62
|
-
const opens = kind === "entity" ? void 0 : entry?.opens?.[kind];
|
|
63
|
-
const how = command && opens ? `open it with ${command} <profile> ${opens} ${text}` : "open it with its own CLI";
|
|
64
|
-
const label = providerLabel(provider);
|
|
65
|
-
return new CliError("validation_error", `${text} is ${article(label.toLowerCase())} ${label} ${kind}; ${how}`, {
|
|
66
|
-
reason: "ref.wrong-provider"
|
|
67
|
-
});
|
|
68
|
-
}, "wrongProvider");
|
|
69
|
-
var chatReferenceOf = /* @__PURE__ */ __name((text, provider, takes = "chat") => {
|
|
70
|
-
const trimmed = text.trim();
|
|
71
|
-
if (!looksLikeReference(trimmed))
|
|
72
|
-
return void 0;
|
|
73
|
-
const reference = parseReference(trimmed);
|
|
74
|
-
if (reference.type !== "chat" && reference.type !== "message")
|
|
75
|
-
throw wrongKind(trimmed, reference.type, takes);
|
|
76
|
-
if (reference.provider !== provider)
|
|
77
|
-
throw wrongProvider(trimmed, reference.provider, reference.type);
|
|
78
|
-
const found = {
|
|
79
|
-
text: trimmed,
|
|
80
|
-
provider: reference.provider,
|
|
81
|
-
account: reference.account,
|
|
82
|
-
chat: reference.chat,
|
|
83
|
-
...reference.type === "message" ? { message: reference.message } : {}
|
|
84
|
-
};
|
|
85
|
-
return found;
|
|
86
|
-
}, "chatReferenceOf");
|
|
87
|
-
var contactReferenceOf = /* @__PURE__ */ __name((text, provider) => {
|
|
88
|
-
const trimmed = text.trim();
|
|
89
|
-
if (!trimmed.startsWith("contact:"))
|
|
90
|
-
return void 0;
|
|
91
|
-
const reference = parseReference(trimmed);
|
|
92
|
-
if (reference.type !== "contact")
|
|
93
|
-
return void 0;
|
|
94
|
-
if (provider !== void 0 && reference.provider !== provider)
|
|
95
|
-
throw wrongProvider(trimmed, reference.provider, reference.type);
|
|
96
|
-
return reference.id;
|
|
97
|
-
}, "contactReferenceOf");
|
|
98
|
-
var wrongAccount = /* @__PURE__ */ __name((reference, scope, profiles) => {
|
|
99
|
-
const here = scope.account === void 0 ? "the account of this profile is not known yet" : `${scope.profile === void 0 ? "this profile" : `profile ${scope.profile}`} is account ${scope.account}`;
|
|
100
|
-
const others = profiles === void 0 ? "" : `. Profiles signed in to ${reference.account}: ${profiles.length > 0 ? profiles.join(", ") : "none here"}`;
|
|
101
|
-
return new CliError("validation_error", `${reference.text} belongs to account ${reference.account}; ${here}${others}`, { reason: "ref.wrong-account" });
|
|
102
|
-
}, "wrongAccount");
|
|
103
|
-
var ensureAccount = /* @__PURE__ */ __name(async (reference, scope, profilesOn) => {
|
|
104
|
-
if (scope.account !== void 0 && scope.account === reference.account)
|
|
105
|
-
return;
|
|
106
|
-
const profiles = await profilesOn?.(reference.account).catch(() => void 0);
|
|
107
|
-
throw wrongAccount(reference, scope, profiles);
|
|
108
|
-
}, "ensureAccount");
|
|
109
|
-
|
|
110
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.620.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_737712cd0065e7e21fd5896a79d0773d/node_modules/@wirecat/cli-core/dist/resolve.js
|
|
111
|
-
var isId = /* @__PURE__ */ __name((reference) => /^-?\d+$/.test(reference.trim()), "isId");
|
|
112
|
-
var foldName = /* @__PURE__ */ __name((name) => name.normalize("NFC").replace(/[\uFE0E\uFE0F\u200D]/g, "").toLowerCase().replaceAll("\u0451", "\u0435"), "foldName");
|
|
113
|
-
var pickChat = /* @__PURE__ */ __name((reference, chats) => {
|
|
114
|
-
const wanted = foldName(reference.trim());
|
|
115
|
-
const matches = chats.filter((chat) => chat.title !== null && foldName(chat.title).includes(wanted));
|
|
116
|
-
if (matches.length === 1 && matches[0])
|
|
117
|
-
return matches[0];
|
|
118
|
-
if (matches.length === 0)
|
|
119
|
-
throw new CliError("not_found", `no chat matches "${reference}"`);
|
|
120
|
-
throw ambiguous(reference, "chats", matches.map((chat) => ({ id: chat.id, title: chat.title })), ({ title }) => singleLine(String(title)));
|
|
121
|
-
}, "pickChat");
|
|
122
|
-
var pickPerson = /* @__PURE__ */ __name((reference, people) => {
|
|
123
|
-
const trimmed = reference.trim();
|
|
124
|
-
const contact = contactReferenceOf(trimmed, people.provider);
|
|
125
|
-
if (contact !== void 0) {
|
|
126
|
-
const named = people.get(contact);
|
|
127
|
-
if (named)
|
|
128
|
-
return named;
|
|
129
|
-
throw new CliError("not_found", `no person ${contact} in what this account has seen`);
|
|
130
|
-
}
|
|
131
|
-
const known = people.get(trimmed);
|
|
132
|
-
if (known)
|
|
133
|
-
return known;
|
|
134
|
-
if (isId(trimmed))
|
|
135
|
-
throw new CliError("not_found", `no person ${trimmed} in what this account has seen`);
|
|
136
|
-
const wanted = foldName(trimmed.replace(/^@/, ""));
|
|
137
|
-
const everyone = people.all().toSorted((a, b) => (a.name ?? "").localeCompare(b.name ?? ""));
|
|
138
|
-
const fields = /* @__PURE__ */ __name((person) => [person.alias, person.name, person.username].filter(isPresent).map(foldName), "fields");
|
|
139
|
-
const exact = everyone.filter((person) => fields(person).includes(wanted));
|
|
140
|
-
const matches = exact.length > 0 ? exact : everyone.filter((person) => fields(person).some((one) => one.includes(wanted)));
|
|
141
|
-
if (matches.length === 1 && matches[0])
|
|
142
|
-
return matches[0];
|
|
143
|
-
if (matches.length === 0)
|
|
144
|
-
throw new CliError("not_found", `nobody matches "${reference}"`);
|
|
145
|
-
throw ambiguous(reference, "people", matches.map(({ id, name, username }) => ({ id, name, username })), ({ name, username }) => singleLine([name, username && `@${username}`].filter(isPresent).join(" ")));
|
|
146
|
-
}, "pickPerson");
|
|
147
|
-
var ambiguous = /* @__PURE__ */ __name((reference, what, candidates, label) => {
|
|
148
|
-
const width = Math.max(...candidates.map(({ id }) => id.length));
|
|
149
|
-
const lines = candidates.map((candidate) => ` ${candidate.id.padEnd(width)} ${label(candidate)}`).join("\n");
|
|
150
|
-
return new CliError("validation_error", `"${singleLine(reference)}" matches ${candidates.length} ${what} \u2014 name one by its id:
|
|
151
|
-
${lines}`, { candidates });
|
|
152
|
-
}, "ambiguous");
|
|
153
|
-
var isPresent = /* @__PURE__ */ __name((value) => value !== null && value !== void 0, "isPresent");
|
|
154
|
-
|
|
155
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.620.0_@wirecat+cli-base@0.80.8_commander@15.0.0_esbuild@0.28.2_type_737712cd0065e7e21fd5896a79d0773d/node_modules/@wirecat/cli-core/dist/domain/vcard.js
|
|
43
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/domain/vcard.js
|
|
156
44
|
import { createHash } from "node:crypto";
|
|
157
45
|
var MAX_ID = 512;
|
|
158
46
|
var AS_WORD = new RegExp(`^${WORD_BODY}$`);
|
|
@@ -383,7 +271,7 @@ var envelopeOfVcard = /* @__PURE__ */ __name((text, { provider, account, batchId
|
|
|
383
271
|
};
|
|
384
272
|
}, "envelopeOfVcard");
|
|
385
273
|
|
|
386
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
274
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/domain/formatting.js
|
|
387
275
|
var invalid = /* @__PURE__ */ __name(() => new CliError("validation_error", "the messenger formatter returned invalid text spans"), "invalid");
|
|
388
276
|
var validateFormattedText = /* @__PURE__ */ __name((formatted) => {
|
|
389
277
|
const { text, spans } = formatted;
|
|
@@ -443,7 +331,7 @@ var visibleFormattedText = /* @__PURE__ */ __name((formatted) => {
|
|
|
443
331
|
};
|
|
444
332
|
}, "visibleFormattedText");
|
|
445
333
|
|
|
446
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
334
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/moderation/check.js
|
|
447
335
|
var INVITE = /max\.ru\/join\/|(t|telegram)\.me\/(\+|joinchat\/)|tg:\/\/join/i;
|
|
448
336
|
var LINK = /https?:\/\/\S+/i;
|
|
449
337
|
var STRENGTH = { report: 0, delete: 1, remove: 2 };
|
|
@@ -631,7 +519,7 @@ var nextPoint = /* @__PURE__ */ __name((rows, found) => {
|
|
|
631
519
|
}, "nextPoint");
|
|
632
520
|
var someUndone = /* @__PURE__ */ __name((rows) => rows.some(undone), "someUndone");
|
|
633
521
|
|
|
634
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
522
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/moderation/rules.js
|
|
635
523
|
import { existsSync, readFileSync } from "node:fs";
|
|
636
524
|
import { join } from "node:path";
|
|
637
525
|
var RULE_ACTIONS = ["report", "delete", "remove"];
|
|
@@ -775,13 +663,6 @@ var assign = /* @__PURE__ */ __name((rules, key, value) => {
|
|
|
775
663
|
}, "assign");
|
|
776
664
|
|
|
777
665
|
export {
|
|
778
|
-
chatReferenceOf,
|
|
779
|
-
wrongAccount,
|
|
780
|
-
ensureAccount,
|
|
781
|
-
isId,
|
|
782
|
-
foldName,
|
|
783
|
-
pickChat,
|
|
784
|
-
pickPerson,
|
|
785
666
|
isVcard,
|
|
786
667
|
envelopeOfVcard,
|
|
787
668
|
validateFormattedText,
|
|
@@ -4,15 +4,15 @@ import {
|
|
|
4
4
|
MAX_SECRET_INPUT,
|
|
5
5
|
bufferedInput,
|
|
6
6
|
inputPolicy
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-EFF2XBHP.js";
|
|
8
8
|
import {
|
|
9
9
|
CliError
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-ELJUBPY4.js";
|
|
11
11
|
import {
|
|
12
12
|
__name
|
|
13
13
|
} from "./chunk-ZVVMGPBJ.js";
|
|
14
14
|
|
|
15
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
15
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/terminal/prompt.js
|
|
16
16
|
import { createInterface } from "node:readline";
|
|
17
17
|
import { Writable } from "node:stream";
|
|
18
18
|
var EMPTY_TRIES = 3;
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
__name
|
|
5
5
|
} from "./chunk-ZVVMGPBJ.js";
|
|
6
6
|
|
|
7
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/background/processes.js
|
|
8
8
|
import { execFileSync } from "node:child_process";
|
|
9
9
|
import { readdirSync, readFileSync, readlinkSync } from "node:fs";
|
|
10
10
|
var alive = /* @__PURE__ */ __name((pid) => {
|
|
@@ -8,12 +8,12 @@ import {
|
|
|
8
8
|
ACCESS_SECONDS,
|
|
9
9
|
REFRESH_SECONDS,
|
|
10
10
|
readStored
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-LLUNHAZ7.js";
|
|
12
12
|
import {
|
|
13
13
|
__name
|
|
14
14
|
} from "./chunk-ZVVMGPBJ.js";
|
|
15
15
|
|
|
16
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
16
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/mcp/http/oauth.js
|
|
17
17
|
import { createHash, randomBytes, randomInt, timingSafeEqual } from "node:crypto";
|
|
18
18
|
import { chmodSync, mkdirSync, renameSync, rmSync, writeFileSync } from "node:fs";
|
|
19
19
|
import { dirname } from "node:path";
|
|
@@ -2,25 +2,25 @@ import { createRequire as __bundleRequire } from "node:module";
|
|
|
2
2
|
const require = __bundleRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
storePath
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-3KRTEX5M.js";
|
|
6
6
|
import {
|
|
7
7
|
resolvePaths
|
|
8
|
-
} from "./chunk-
|
|
8
|
+
} from "./chunk-S7SXSHRC.js";
|
|
9
9
|
import {
|
|
10
10
|
CliError
|
|
11
|
-
} from "./chunk-
|
|
11
|
+
} from "./chunk-ELJUBPY4.js";
|
|
12
12
|
import {
|
|
13
13
|
singleLine
|
|
14
|
-
} from "./chunk-
|
|
14
|
+
} from "./chunk-6DCLZLGX.js";
|
|
15
15
|
import {
|
|
16
16
|
__name
|
|
17
17
|
} from "./chunk-ZVVMGPBJ.js";
|
|
18
18
|
|
|
19
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
19
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/store/shared-config.js
|
|
20
20
|
import { mkdirSync, readFileSync, renameSync, statSync, writeFileSync } from "node:fs";
|
|
21
21
|
import { dirname, join, resolve } from "node:path";
|
|
22
22
|
|
|
23
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
23
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/domain/task-categories.js
|
|
24
24
|
var DEFAULT_TASK_CATEGORIES = [
|
|
25
25
|
{
|
|
26
26
|
name: "taxes",
|
|
@@ -775,7 +775,7 @@ var storedTaskCategories = /* @__PURE__ */ __name((json) => {
|
|
|
775
775
|
}
|
|
776
776
|
}, "storedTaskCategories");
|
|
777
777
|
|
|
778
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
778
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/store/shared-config.js
|
|
779
779
|
var SECTION = "task_categories";
|
|
780
780
|
var sharedConfigPath = /* @__PURE__ */ __name((store, env = process.env) => {
|
|
781
781
|
const paths = resolvePaths({ appName: "WireCat", prefix: "WIRECAT", env });
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
__name
|
|
5
5
|
} from "./chunk-ZVVMGPBJ.js";
|
|
6
6
|
|
|
7
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
7
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.647.0_@wirecat+cli-base@0.93.0_commander@15.0.0_esbuild@0.28.2_type_a46df5420a4458268e3f15f3e8c41b99/node_modules/@wirecat/cli-core/dist/store/sqlite/drizzle/shared-55XJMTPA.js
|
|
8
8
|
var entityKind = /* @__PURE__ */ Symbol.for("drizzle:entityKind");
|
|
9
9
|
var kindsByConstructor = /* @__PURE__ */ new WeakMap();
|
|
10
10
|
function collectKinds(ctor) {
|