@wirecat/tg-cli 0.100.0 → 0.101.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/README.md +3 -3
- package/dist/bin/tg.js +1 -1
- package/dist/bundle/{adapter-2LVPMFKF.js → adapter-A3VD4Y6Z.js} +24 -24
- package/dist/bundle/{all-profiles-BLTK2AAB.js → all-profiles-UPVNHXB2.js} +16 -7
- package/dist/bundle/{anthropic-RJE4XEOO.js → anthropic-IRKNWPIB.js} +5 -5
- package/dist/bundle/{bot-api-4XM3NVWG.js → bot-api-UNTQG2M5.js} +48 -48
- package/dist/bundle/{bot-history-WVM5GEQN.js → bot-history-V4RTY5K7.js} +15 -15
- package/dist/bundle/{bun-UZXO2LRQ.js → bun-2JZPG2NL.js} +2 -2
- package/dist/bundle/{bun-sqlite-GJLGSQIT.js → bun-sqlite-TZHKM225.js} +4 -4
- package/dist/bundle/{chunk-V4JSVH4M.js → chunk-22PQUX72.js} +2 -2
- package/dist/bundle/{chunk-MQNFEVAH.js → chunk-2DGOFLDA.js} +2 -2
- package/dist/bundle/{chunk-2IM4M7Q2.js → chunk-2XBSVRT2.js} +1 -1
- package/dist/bundle/{chunk-HKT5EOT5.js → chunk-4ZS73HTJ.js} +1 -1
- package/dist/bundle/{chunk-SMJTL5U7.js → chunk-54R2GDQ3.js} +6 -4
- package/dist/bundle/{chunk-2MXQ2EUN.js → chunk-5GKXETRP.js} +21 -20
- package/dist/bundle/{chunk-GTURDJJD.js → chunk-5KU4UQBM.js} +1 -1
- package/dist/bundle/{chunk-JFJVS5JC.js → chunk-5TPT2S2Z.js} +2 -2
- package/dist/bundle/{chunk-SYPL4PHV.js → chunk-64DK7S4F.js} +1 -1
- package/dist/bundle/{chunk-BAIZAZ6Q.js → chunk-6IPY2QRG.js} +2 -2
- package/dist/bundle/{chunk-I6WZJVRT.js → chunk-7CBUCTB6.js} +55 -36
- package/dist/bundle/{chunk-LI7TXFLS.js → chunk-A5JSTZZZ.js} +3 -3
- package/dist/bundle/{chunk-OW3COBN5.js → chunk-ACGTFLEB.js} +9 -9
- package/dist/bundle/{chunk-Q26JMPBP.js → chunk-BX6HH4F6.js} +11 -11
- package/dist/bundle/{chunk-CV5ASHTW.js → chunk-BXQS5RCE.js} +45 -45
- package/dist/bundle/{chunk-MUEXF4ME.js → chunk-CJ6IYCYP.js} +12 -11
- package/dist/bundle/{chunk-GYEOQS2D.js → chunk-DG62L57H.js} +17 -17
- package/dist/bundle/{chunk-4U7QOFDA.js → chunk-DYNSP6FW.js} +445 -236
- package/dist/bundle/{chunk-HXTTDIL7.js → chunk-F7TDFWXY.js} +3 -3
- package/dist/bundle/{chunk-P26LWFNZ.js → chunk-G2US6LJB.js} +1 -1
- package/dist/bundle/{chunk-KE6L2UEG.js → chunk-G3ZRY436.js} +70 -61
- package/dist/bundle/{chunk-QY3YOOTP.js → chunk-G77QOTXE.js} +2 -2
- package/dist/bundle/{chunk-6YLT4YVJ.js → chunk-H6OXALTJ.js} +2 -2
- package/dist/bundle/{chunk-WKOY3POD.js → chunk-LPB2MDUW.js} +7 -7
- package/dist/bundle/{chunk-66E5QDLH.js → chunk-MLLJ74LM.js} +1 -1
- package/dist/bundle/{chunk-6VEOR6GD.js → chunk-N5UFBWDM.js} +6 -6
- package/dist/bundle/{chunk-THVNP6S6.js → chunk-NC5WS7OP.js} +2 -2
- package/dist/bundle/{chunk-YG7PNCSW.js → chunk-NKJJJAIJ.js} +10 -3
- package/dist/bundle/{chunk-DVOUKGFK.js → chunk-NMGO6LW6.js} +8 -8
- package/dist/bundle/{chunk-QU2FJMFB.js → chunk-ODSVNH3H.js} +798 -492
- package/dist/bundle/{chunk-WE3LBRMB.js → chunk-OEJ5DMCX.js} +7 -7
- package/dist/bundle/{chunk-3N6LXAPE.js → chunk-OILBDLWL.js} +10 -10
- package/dist/bundle/{chunk-U7LXA4SO.js → chunk-OPBTNQ35.js} +11 -11
- package/dist/bundle/{chunk-OOOV3JBZ.js → chunk-PUBS2F5J.js} +953 -677
- package/dist/bundle/{chunk-H3X5LS6U.js → chunk-PYTOIDSM.js} +4 -4
- package/dist/bundle/{chunk-RER6DAHP.js → chunk-QOWSVDPZ.js} +157 -145
- package/dist/bundle/{chunk-2XUGPE5W.js → chunk-QYVVRQTN.js} +3 -3
- package/dist/bundle/{chunk-RDQMV6EU.js → chunk-RF54YDBB.js} +4 -4
- package/dist/bundle/{chunk-3QDPV34J.js → chunk-RVCS7Q3A.js} +51 -47
- package/dist/bundle/{chunk-4YCLWWZ3.js → chunk-S2JSZWEC.js} +11 -11
- package/dist/bundle/{chunk-SGJYU3SB.js → chunk-S7ZNLLY5.js} +3 -3
- package/dist/bundle/{chunk-JSKT5UZX.js → chunk-TGREFJVA.js} +8 -8
- package/dist/bundle/{chunk-4VBDVZNE.js → chunk-U46UNBMT.js} +15 -15
- package/dist/bundle/{chunk-BL36RR34.js → chunk-UN6CKIBN.js} +4 -4
- package/dist/bundle/chunk-VA5YEJS3.js +161 -0
- package/dist/bundle/{chunk-DN4QUTWU.js → chunk-VCGL2ETF.js} +1 -1
- package/dist/bundle/{chunk-UMLPXNJI.js → chunk-VRSN7VLO.js} +1 -1
- package/dist/bundle/{chunk-ATZ44Z77.js → chunk-VYDTI254.js} +108 -29
- package/dist/bundle/{chunk-UD4DOZCN.js → chunk-W2336E7Y.js} +6 -6
- package/dist/bundle/{chunk-3S5CL55R.js → chunk-XCKD54TN.js} +6 -6
- package/dist/bundle/{chunk-A7OBVRJV.js → chunk-ZEOCU24Z.js} +3 -3
- package/dist/bundle/{chunk-BZANDKWT.js → chunk-ZJVZXJOG.js} +2 -2
- package/dist/bundle/{chunk-ASDZHG5I.js → chunk-ZV24I2UJ.js} +2 -2
- package/dist/bundle/command-contract-TKDI7E56.js +31 -0
- package/dist/bundle/{echarts-YHSYUWLY.js → echarts-QZ6PR3VC.js} +2 -2
- package/dist/bundle/{embed-3HGI2XIW.js → embed-UBXCXSRD.js} +4 -4
- package/dist/bundle/{embedder-2CJMZETJ.js → embedder-B4ZTKC23.js} +7 -7
- package/dist/bundle/{entry-UVE53OV3.js → entry-BTUTHO5M.js} +5 -5
- package/dist/bundle/{first-run-6GYC2QS3.js → first-run-UC4HRIFV.js} +9 -9
- package/dist/bundle/first-screen-SMCX6YKY.js +29 -0
- package/dist/bundle/{identity-HEV5E57G.js → identity-QSDEGDH7.js} +3 -3
- package/dist/bundle/{instructions-5UVAXSQV.js → instructions-BBGLZKO3.js} +1 -1
- package/dist/bundle/{mcp-NWXBVNUA.js → mcp-4Y37G2UY.js} +2 -2
- package/dist/bundle/{node-YHYEGYVE.js → node-LZZX22VR.js} +2 -2
- package/dist/bundle/{node-sqlite-CQ33A3R2.js → node-sqlite-BPGT6T5U.js} +4 -4
- package/dist/bundle/{oauth-OB3JFAD7.js → oauth-XNE2KPKJ.js} +6 -6
- package/dist/bundle/{open-JHGZIXU2.js → open-SXGYZLB5.js} +3 -3
- package/dist/bundle/{process-PSKS3N5B.js → process-GPUXC4PG.js} +1 -1
- package/dist/bundle/{program-RPYVPNRX.js → program-NEXEAL7T.js} +51 -51
- package/dist/bundle/{prompt-7BXUMJGG.js → prompt-SORGLEYI.js} +4 -4
- package/dist/bundle/{proxy-transport-3EEMW2HW.js → proxy-transport-G4MA6BGU.js} +4 -4
- package/dist/bundle/{recognize-YMZPL47R.js → recognize-UJBXORVD.js} +5 -5
- package/dist/bundle/{remote-LQ3Q22NG.js → remote-W72AR7KH.js} +5 -5
- package/dist/bundle/{rerank-SM7IYVXJ.js → rerank-3Y2VZM3J.js} +5 -5
- package/dist/bundle/{serve-GHUEP5H5.js → serve-VDZIVOPR.js} +23 -8
- package/dist/bundle/{server-K2BQPPHN.js → server-BERXP4GW.js} +52 -52
- package/dist/bundle/{server-A45HVXQY.js → server-ZFHN4GUF.js} +34 -34
- package/dist/bundle/{state-WIOL52GZ.js → state-DGR4EE3E.js} +9 -5
- package/dist/bundle/{store-XE5AKUJZ.js → store-MRCFSCZD.js} +10 -10
- package/dist/bundle/store-maintenance-command-DCMZDMYS.js +46 -0
- package/dist/bundle/tg.js +4 -4
- package/dist/commands/context.d.ts.map +1 -1
- package/dist/commands/context.js +2 -0
- package/dist/commands/context.js.map +1 -1
- package/dist/program.js +1 -1
- package/dist/program.js.map +1 -1
- package/dist/telegram/errors.js +1 -1
- package/dist/telegram/errors.js.map +1 -1
- package/dist/version.d.ts +1 -1
- package/dist/version.js +1 -1
- package/install/windows.ps1 +1 -1
- package/package.json +3 -3
- package/skills/tg-cli/SKILL.md +4 -4
- package/dist/bundle/chunk-Z2FHEIXN.js +0 -63
- package/dist/bundle/command-contract-AIVKJYIR.js +0 -31
- package/dist/bundle/first-screen-HRRLVLOG.js +0 -29
- package/dist/bundle/store-maintenance-command-YS5E7VUN.js +0 -46
- /package/dist/bundle/{chunk-3MVHRZWR.js → chunk-2SJOUK6J.js} +0 -0
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
__name
|
|
5
5
|
} from "./chunk-AFV74GK3.js";
|
|
6
6
|
|
|
7
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
7
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.64.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/errors.js
|
|
8
8
|
var errorCodes = [
|
|
9
9
|
"validation_error",
|
|
10
10
|
"configuration_error",
|
|
@@ -1918,7 +1918,7 @@ function toStandardJsonSchema(schema) {
|
|
|
1918
1918
|
}
|
|
1919
1919
|
__name(toStandardJsonSchema, "toStandardJsonSchema");
|
|
1920
1920
|
|
|
1921
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1921
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.64.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/registry.js
|
|
1922
1922
|
var word = pipe(string(), regex(/^[a-z][a-z0-9]*(-[a-z0-9]+)*$/, "a lower-case word, words joined by -"));
|
|
1923
1923
|
var SNAKE_CASE = /^[a-z][a-z0-9]*(_[a-z0-9]+)*$/;
|
|
1924
1924
|
var text = pipe(string(), regex(/\S/, "must not be empty"));
|
|
@@ -1960,7 +1960,7 @@ var fill = /* @__PURE__ */ __name((template, values) => template.replace(PLACEHO
|
|
|
1960
1960
|
return String(value);
|
|
1961
1961
|
}), "fill");
|
|
1962
1962
|
|
|
1963
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1963
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.64.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/effects.js
|
|
1964
1964
|
var EFFECT_LEVELS = ["none", "read", "write"];
|
|
1965
1965
|
var effectsSchema = strictObject({
|
|
1966
1966
|
remote: picklist(EFFECT_LEVELS),
|
|
@@ -1968,7 +1968,7 @@ var effectsSchema = strictObject({
|
|
|
1968
1968
|
});
|
|
1969
1969
|
var writes = /* @__PURE__ */ __name((effects) => effects === void 0 || effects.remote === "write" || effects.local === "write", "writes");
|
|
1970
1970
|
|
|
1971
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
1971
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.64.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/output.js
|
|
1972
1972
|
var MAX_NEXT_STEPS = 2;
|
|
1973
1973
|
var isoTime = pipe(string(), isoTimestamp("an ISO 8601 time in UTC"), endsWith("Z", "an ISO 8601 time in UTC, ending in `Z`"));
|
|
1974
1974
|
var reference = pipe(string(), regex(/^[a-z]+:\S+$/, "a reference such as `note:42`"));
|
|
@@ -2053,7 +2053,7 @@ var jsonlOf = /* @__PURE__ */ __name(({ items, page, meta }) => [
|
|
|
2053
2053
|
JSON.stringify({ type: "end", complete: meta.complete, ...meta.issues ? { issues: meta.issues } : {}, page })
|
|
2054
2054
|
].join("\n"), "jsonlOf");
|
|
2055
2055
|
|
|
2056
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
2056
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.64.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/errors.js
|
|
2057
2057
|
var CRASH_CODE = "internal_error";
|
|
2058
2058
|
var CRASH_REASON = "command.crashed";
|
|
2059
2059
|
var errorObjectSchema = strictObject({
|
|
@@ -2134,7 +2134,7 @@ var BASE_REASONS = defineReasons([
|
|
|
2134
2134
|
{ reason: CRASH_REASON, code: CRASH_CODE, message: "the command failed; this is a bug", details: [] }
|
|
2135
2135
|
]);
|
|
2136
2136
|
|
|
2137
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
2137
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.64.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/steps.js
|
|
2138
2138
|
var SAME_COMMAND = "*";
|
|
2139
2139
|
var commandPath = pipe(string(), regex(/^[a-z][a-z0-9-]*( [a-z][a-z0-9-]*)*$/, "a command path such as `messages sync`"));
|
|
2140
2140
|
var stepSchema = union([
|
|
@@ -2213,7 +2213,7 @@ var STEPS = defineSteps([
|
|
|
2213
2213
|
}
|
|
2214
2214
|
]);
|
|
2215
2215
|
|
|
2216
|
-
// node_modules/.pnpm/@wirecat+cli-base@0.
|
|
2216
|
+
// node_modules/.pnpm/@wirecat+cli-base@0.64.0_commander@15.0.0_esbuild@0.28.2_typescript@7.0.2_vitest@5.0.5/node_modules/@wirecat/cli-base/dist/standards/log.js
|
|
2217
2217
|
var LOG_SEVERITIES = ["trace", "debug", "info", "warn", "error", "fatal"];
|
|
2218
2218
|
var logRecordSchema = strictObject({
|
|
2219
2219
|
time: isoTime,
|
|
@@ -2,17 +2,17 @@ import { createRequire as __tgRequire } from "node:module";
|
|
|
2
2
|
const require = __tgRequire(import.meta.url);
|
|
3
3
|
import {
|
|
4
4
|
LEVELS
|
|
5
|
-
} from "./chunk-
|
|
5
|
+
} from "./chunk-OPBTNQ35.js";
|
|
6
6
|
import {
|
|
7
7
|
storePath,
|
|
8
8
|
wirecatDirectory
|
|
9
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-G77QOTXE.js";
|
|
10
10
|
import {
|
|
11
11
|
resolvePaths,
|
|
12
12
|
singleLine,
|
|
13
13
|
visibleControls,
|
|
14
14
|
writeSecurely
|
|
15
|
-
} from "./chunk-
|
|
15
|
+
} from "./chunk-DG62L57H.js";
|
|
16
16
|
import {
|
|
17
17
|
CliError,
|
|
18
18
|
array,
|
|
@@ -32,17 +32,17 @@ import {
|
|
|
32
32
|
string,
|
|
33
33
|
transform,
|
|
34
34
|
unknown
|
|
35
|
-
} from "./chunk-
|
|
35
|
+
} from "./chunk-OEJ5DMCX.js";
|
|
36
36
|
import {
|
|
37
37
|
__name
|
|
38
38
|
} from "./chunk-AFV74GK3.js";
|
|
39
39
|
|
|
40
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
40
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/sends/send-id.js
|
|
41
41
|
import { randomBytes } from "node:crypto";
|
|
42
42
|
var newSendId = /* @__PURE__ */ __name(() => randomBytes(8).readBigInt64BE().toString(), "newSendId");
|
|
43
43
|
var newOperationId = newSendId;
|
|
44
44
|
|
|
45
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
45
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/sends/upload.js
|
|
46
46
|
import { openAsBlob, realpathSync } from "node:fs";
|
|
47
47
|
import { open, stat } from "node:fs/promises";
|
|
48
48
|
import { basename, dirname, extname, isAbsolute, relative, resolve, sep } from "node:path";
|
|
@@ -263,7 +263,7 @@ var readStickerFile = /* @__PURE__ */ __name(async (path, maxBytes, read) => {
|
|
|
263
263
|
return { name, source };
|
|
264
264
|
}, "readStickerFile");
|
|
265
265
|
|
|
266
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
266
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/resolve.js
|
|
267
267
|
var isId = /* @__PURE__ */ __name((reference) => /^-?\d+$/.test(reference.trim()), "isId");
|
|
268
268
|
var foldName = /* @__PURE__ */ __name((name) => name.normalize("NFC").replace(/[\uFE0E\uFE0F\u200D]/g, "").toLowerCase(), "foldName");
|
|
269
269
|
var pickChat = /* @__PURE__ */ __name((reference, chats) => {
|
|
@@ -301,7 +301,7 @@ ${lines}`, { candidates });
|
|
|
301
301
|
}, "ambiguous");
|
|
302
302
|
var isPresent = /* @__PURE__ */ __name((value) => value !== null && value !== void 0, "isPresent");
|
|
303
303
|
|
|
304
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
304
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/domain/formatting.js
|
|
305
305
|
var invalid = /* @__PURE__ */ __name(() => new CliError("validation_error", "the messenger formatter returned invalid text spans"), "invalid");
|
|
306
306
|
var validateFormattedText = /* @__PURE__ */ __name((formatted) => {
|
|
307
307
|
const { text, spans } = formatted;
|
|
@@ -361,7 +361,7 @@ var visibleFormattedText = /* @__PURE__ */ __name((formatted) => {
|
|
|
361
361
|
};
|
|
362
362
|
}, "visibleFormattedText");
|
|
363
363
|
|
|
364
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
364
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/moderation/check.js
|
|
365
365
|
var INVITE = /max\.ru\/join\/|(t|telegram)\.me\/(\+|joinchat\/)|tg:\/\/join/i;
|
|
366
366
|
var LINK = /https?:\/\/\S+/i;
|
|
367
367
|
var STRENGTH = { report: 0, delete: 1, remove: 2 };
|
|
@@ -549,7 +549,7 @@ var nextPoint = /* @__PURE__ */ __name((rows, found) => {
|
|
|
549
549
|
}, "nextPoint");
|
|
550
550
|
var someUndone = /* @__PURE__ */ __name((rows) => rows.some(undone), "someUndone");
|
|
551
551
|
|
|
552
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
552
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/moderation/rules.js
|
|
553
553
|
import { existsSync, readFileSync } from "node:fs";
|
|
554
554
|
import { join } from "node:path";
|
|
555
555
|
var RULE_ACTIONS = ["report", "delete", "remove"];
|
|
@@ -9,17 +9,17 @@ import {
|
|
|
9
9
|
resolvePaths,
|
|
10
10
|
singleLine,
|
|
11
11
|
writeSecurely
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-DG62L57H.js";
|
|
13
13
|
import {
|
|
14
14
|
CliError,
|
|
15
15
|
isCliError,
|
|
16
16
|
traceIdOf
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-OEJ5DMCX.js";
|
|
18
18
|
import {
|
|
19
19
|
__name
|
|
20
20
|
} from "./chunk-AFV74GK3.js";
|
|
21
21
|
|
|
22
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
22
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/sends/guarded.js
|
|
23
23
|
import { AsyncLocalStorage } from "node:async_hooks";
|
|
24
24
|
var sentIds = /* @__PURE__ */ __name((typed, message) => ({
|
|
25
25
|
messageId: message.id,
|
|
@@ -125,7 +125,7 @@ var guardedWrite = /* @__PURE__ */ __name(async (guard, attempt, act, settled =
|
|
|
125
125
|
}, "guardedWrite");
|
|
126
126
|
var codeOf = /* @__PURE__ */ __name((error) => typeof error?.code === "string" ? error.code : "unknown", "codeOf");
|
|
127
127
|
|
|
128
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
128
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/sends/permissions.js
|
|
129
129
|
var LEVELS = ["deny", "readonly", "ask", "allow"];
|
|
130
130
|
var DANGEROUS = /* @__PURE__ */ new Set(["messages.delete", "bot.messages.delete", "topics.delete", "chats.delete", "chats.clear"]);
|
|
131
131
|
var skipFlagFor = /* @__PURE__ */ __name((key) => DANGEROUS.has(key) ? "--allow-dangerous" : "--yes", "skipFlagFor");
|
|
@@ -514,7 +514,7 @@ var assertRetentionEvidenceRead = /* @__PURE__ */ __name((permissions) => {
|
|
|
514
514
|
}
|
|
515
515
|
}, "assertRetentionEvidenceRead");
|
|
516
516
|
|
|
517
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
517
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/cli/result-fields.js
|
|
518
518
|
var named = /* @__PURE__ */ __name((work) => {
|
|
519
519
|
try {
|
|
520
520
|
return work();
|
|
@@ -541,7 +541,7 @@ var projectFields2 = /* @__PURE__ */ __name((value, fields) => named(() => {
|
|
|
541
541
|
return projectFields(value, fields);
|
|
542
542
|
}), "projectFields");
|
|
543
543
|
|
|
544
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
544
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/output-detail.js
|
|
545
545
|
var RARELY_SET = ["editedAt", "replyTo", "forwardedFrom", "reactions"];
|
|
546
546
|
var BRIEF = ["locator", "chatTitle", "timestamp", "senderName", "excerpt", "score"];
|
|
547
547
|
var isHit = /* @__PURE__ */ __name((value) => typeof value === "object" && value !== null && typeof value.locator === "string" && typeof value.text === "string", "isHit");
|
|
@@ -571,7 +571,7 @@ var atDetail = /* @__PURE__ */ __name((value, detail = "default") => {
|
|
|
571
571
|
return value;
|
|
572
572
|
}, "atDetail");
|
|
573
573
|
|
|
574
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
574
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/output.js
|
|
575
575
|
var resolveOutput = /* @__PURE__ */ __name(({ json, jsonl, quiet, streams = processStreams, tty, color, fields, hitDetail, env = process.env, capture } = {}) => {
|
|
576
576
|
const interactive = tty ?? process.stdout.isTTY === true;
|
|
577
577
|
const format = jsonl ? "jsonl" : json || !interactive ? "json" : "pretty";
|
|
@@ -619,7 +619,7 @@ var silence = /* @__PURE__ */ __name((renderer) => ({
|
|
|
619
619
|
}, "warn")
|
|
620
620
|
}), "silence");
|
|
621
621
|
|
|
622
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
622
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/runs/log-keys.js
|
|
623
623
|
var snake = /* @__PURE__ */ __name((key) => key.replace(/[A-Z]/g, (letter) => `_${letter.toLowerCase()}`), "snake");
|
|
624
624
|
var camel = /* @__PURE__ */ __name((key) => key.replace(/_([a-z0-9])/g, (_, letter) => letter.toUpperCase()), "camel");
|
|
625
625
|
var renamed = /* @__PURE__ */ __name((record, name) => Object.fromEntries(Object.entries(record).map(([key, value]) => [name(key), value])), "renamed");
|
|
@@ -632,7 +632,7 @@ var snakeLogger = /* @__PURE__ */ __name((logger) => ({
|
|
|
632
632
|
error: /* @__PURE__ */ __name((event, message) => logger.error(logAttributes(event), message), "error")
|
|
633
633
|
}), "snakeLogger");
|
|
634
634
|
|
|
635
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
635
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/runs/log-attributes.js
|
|
636
636
|
var diagnostic = {
|
|
637
637
|
event: true,
|
|
638
638
|
operation: true,
|
|
@@ -697,7 +697,7 @@ var LOG_ATTRIBUTES = [
|
|
|
697
697
|
...new Set([...Object.keys(diagnostic), ...Object.keys(send), ...background, ...crash].map((key) => Object.keys(logAttributes({ [key]: true }))[0]))
|
|
698
698
|
].sort();
|
|
699
699
|
|
|
700
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
700
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/runs/run.js
|
|
701
701
|
import { randomUUID } from "node:crypto";
|
|
702
702
|
import { appendFileSync, mkdirSync, readdirSync, readFileSync, rmSync, writeFileSync } from "node:fs";
|
|
703
703
|
import { join } from "node:path";
|
|
@@ -919,7 +919,7 @@ var metadataOf = /* @__PURE__ */ __name((parsed) => {
|
|
|
919
919
|
};
|
|
920
920
|
}, "metadataOf");
|
|
921
921
|
|
|
922
|
-
// node_modules/.pnpm/@wirecat+cli-core@0.
|
|
922
|
+
// node_modules/.pnpm/@wirecat+cli-core@0.466.0_@napi-rs+canvas@1.0.13_@wirecat+cli-base@0.64.0_commander@15._f7e4048410ccbe1e801fd184c043d197/node_modules/@wirecat/cli-core/dist/runs/scope.js
|
|
923
923
|
import { AsyncLocalStorage as AsyncLocalStorage2 } from "node:async_hooks";
|
|
924
924
|
import { randomBytes } from "node:crypto";
|
|
925
925
|
var scopes = new AsyncLocalStorage2();
|