token-goat 2.6.32 → 2.6.34
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 +24 -1
- package/dist/{token-goat-chunk-5EXIMDHA.mjs → token-goat-chunk-7FWBSPCT.mjs} +1573 -386
- package/dist/token-goat-chunk-AEX54RUZ.mjs +11 -0
- package/dist/{token-goat-chunk-3KW5C2KQ.mjs → token-goat-chunk-AO2QD2AG.mjs} +0 -4
- package/dist/{token-goat-chunk-TBCLQTPG.mjs → token-goat-chunk-CKRATWCJ.mjs} +7 -7
- package/dist/{token-goat-chunk-X5OPORR4.mjs → token-goat-chunk-CN7GUPX6.mjs} +1258 -1769
- package/dist/{token-goat-hook-chunk-TKXOXN4J.mjs → token-goat-chunk-DG53MVNJ.mjs} +2 -98
- package/dist/{token-goat-chunk-DFBD2FFU.mjs → token-goat-chunk-FRMEOIRU.mjs} +365 -139
- package/dist/{token-goat-chunk-YWYITDOS.mjs → token-goat-chunk-G6XLWJWI.mjs} +2 -5
- package/dist/{token-goat-chunk-RD6O3PJU.mjs → token-goat-chunk-GXBPEQR2.mjs} +3699 -3341
- package/dist/{token-goat-chunk-DNEPSN3P.mjs → token-goat-chunk-I6EQH27G.mjs} +4 -7
- package/dist/{token-goat-hook-chunk-Q5URQRIF.mjs → token-goat-chunk-IYYQOPY4.mjs} +811 -79
- package/dist/{token-goat-chunk-W3MX4LQV.mjs → token-goat-chunk-L7QLEVO7.mjs} +6 -9
- package/dist/{token-goat-chunk-O7TGKV5I.mjs → token-goat-chunk-OA3GFKP2.mjs} +23 -24
- package/dist/{token-goat-chunk-GWZJ5SI2.mjs → token-goat-chunk-WA2ER6TZ.mjs} +7 -32
- package/dist/{token-goat-hook-chunk-VHZECEQD.mjs → token-goat-hook-chunk-2ISZ4AZR.mjs} +7 -32
- package/dist/{token-goat-chunk-4M7PSAO3.mjs → token-goat-hook-chunk-3QYSN4QV.mjs} +2 -98
- package/dist/{token-goat-hook-chunk-LFYT4DLB.mjs → token-goat-hook-chunk-6C5RN3CM.mjs} +23 -24
- package/dist/{token-goat-hook-chunk-WBTHUYJP.mjs → token-goat-hook-chunk-6QTWMSRO.mjs} +1221 -1730
- package/dist/token-goat-hook-chunk-ATEGFQAU.mjs +23 -0
- package/dist/{token-goat-hook-chunk-DJZGX27J.mjs → token-goat-hook-chunk-BU5OFDGQ.mjs} +363 -138
- package/dist/{token-goat-hook-chunk-J2ZK2FYW.mjs → token-goat-hook-chunk-BUOCULAM.mjs} +0 -4
- package/dist/{token-goat-hook-chunk-DHW6SRHR.mjs → token-goat-hook-chunk-CNLMPHXT.mjs} +1569 -382
- package/dist/{token-goat-hook-chunk-6NF4WM2U.mjs → token-goat-hook-chunk-I5VM5PO5.mjs} +3700 -3342
- package/dist/{token-goat-chunk-N53GXI2Z.mjs → token-goat-hook-chunk-KGLMNOGD.mjs} +811 -79
- package/dist/{token-goat-hook-chunk-TBJ5PUPQ.mjs → token-goat-hook-chunk-OQML5EMA.mjs} +6 -9
- package/dist/{token-goat-hook-chunk-UXD3B4OY.mjs → token-goat-hook-chunk-QTZ6YUMQ.mjs} +4 -7
- package/dist/token-goat-hook-chunk-RFRLWOQH.mjs +11 -0
- package/dist/{token-goat-hook-chunk-PCP4W65Z.mjs → token-goat-hook-chunk-XUMIVYEN.mjs} +2 -5
- package/dist/token-goat-hook.mjs +7 -12
- package/dist/token-goat.core.mjs +7 -10
- package/package.json +20 -40
- package/dist/token-goat-chunk-3UOG7PSZ.mjs +0 -63
- package/dist/token-goat-hook-chunk-ANFXTEQO.mjs +0 -23
- package/dist/token-goat-hook-chunk-K33JMLL7.mjs +0 -63
|
@@ -25,7 +25,7 @@ import {
|
|
|
25
25
|
runSkeleton,
|
|
26
26
|
runSymbol,
|
|
27
27
|
withPinnedReads
|
|
28
|
-
} from "./token-goat-chunk-
|
|
28
|
+
} from "./token-goat-chunk-IYYQOPY4.mjs";
|
|
29
29
|
import {
|
|
30
30
|
buildProjectMap,
|
|
31
31
|
embeddingsDepsAvailable,
|
|
@@ -34,7 +34,7 @@ import {
|
|
|
34
34
|
getProjectIndexCounts,
|
|
35
35
|
isWorkerRunning,
|
|
36
36
|
mapLookupBytesSaved
|
|
37
|
-
} from "./token-goat-chunk-
|
|
37
|
+
} from "./token-goat-chunk-CN7GUPX6.mjs";
|
|
38
38
|
import {
|
|
39
39
|
VERSION,
|
|
40
40
|
dataDir,
|
|
@@ -45,14 +45,11 @@ import {
|
|
|
45
45
|
normalizePath,
|
|
46
46
|
recordStat,
|
|
47
47
|
resolveProjectRoot
|
|
48
|
-
} from "./token-goat-chunk-
|
|
49
|
-
import "./token-goat-chunk-
|
|
50
|
-
import
|
|
51
|
-
init_define_import_meta_env
|
|
52
|
-
} from "./token-goat-chunk-3UOG7PSZ.mjs";
|
|
48
|
+
} from "./token-goat-chunk-7FWBSPCT.mjs";
|
|
49
|
+
import "./token-goat-chunk-AO2QD2AG.mjs";
|
|
50
|
+
import "./token-goat-chunk-AEX54RUZ.mjs";
|
|
53
51
|
|
|
54
52
|
// src/mcp_server.ts
|
|
55
|
-
init_define_import_meta_env();
|
|
56
53
|
import * as fs from "fs";
|
|
57
54
|
import * as path from "path";
|
|
58
55
|
var TOKEN_GOAT_RETRY_RE = /token-goat (\w[\w-]*) "([^"]+)"/g;
|
|
@@ -202,7 +199,7 @@ function withConfinedRead(pins, fn) {
|
|
|
202
199
|
}
|
|
203
200
|
}
|
|
204
201
|
async function createMcpServer() {
|
|
205
|
-
const [{ McpServer }, { z }] = await Promise.all([import("@modelcontextprotocol/sdk/server/mcp.js"), import("./token-goat-chunk-
|
|
202
|
+
const [{ McpServer }, { z }] = await Promise.all([import("@modelcontextprotocol/sdk/server/mcp.js"), import("./token-goat-chunk-DG53MVNJ.mjs")]);
|
|
206
203
|
const server = new McpServer({ name: "token-goat", version: VERSION });
|
|
207
204
|
const makeProjectRootField = (verb) => z.string().optional().describe(
|
|
208
205
|
`absolute path to the workspace root to scope this ${verb} to; defaults to the MCP server process's cwd, which is not always the actual workspace root for MCP clients -- pass this explicitly when it might differ`
|
|
@@ -6,7 +6,7 @@ import {
|
|
|
6
6
|
loadBlob,
|
|
7
7
|
sanitizeFtsQuery,
|
|
8
8
|
storeBlob
|
|
9
|
-
} from "./token-goat-chunk-
|
|
9
|
+
} from "./token-goat-chunk-CN7GUPX6.mjs";
|
|
10
10
|
import {
|
|
11
11
|
SYMBOL_BODY_CHAR_CAP,
|
|
12
12
|
extractErrorMessage,
|
|
@@ -16,16 +16,12 @@ import {
|
|
|
16
16
|
redactSecrets,
|
|
17
17
|
runGit,
|
|
18
18
|
shortFingerprint
|
|
19
|
-
} from "./token-goat-chunk-
|
|
19
|
+
} from "./token-goat-chunk-7FWBSPCT.mjs";
|
|
20
20
|
import {
|
|
21
21
|
registerReset
|
|
22
|
-
} from "./token-goat-chunk-
|
|
23
|
-
import {
|
|
24
|
-
init_define_import_meta_env
|
|
25
|
-
} from "./token-goat-chunk-3UOG7PSZ.mjs";
|
|
22
|
+
} from "./token-goat-chunk-AO2QD2AG.mjs";
|
|
26
23
|
|
|
27
24
|
// src/hooks_cli.ts
|
|
28
|
-
init_define_import_meta_env();
|
|
29
25
|
var _LOG = {
|
|
30
26
|
warn: (msg, ...args) => console.warn(`[hooks_cli] ${msg}`, ...args),
|
|
31
27
|
debug: (msg, ...args) => console.error(`[hooks_cli] ${msg}`, ...args),
|
|
@@ -76,6 +72,15 @@ var GROK_TOOL_NAME_MAP = {
|
|
|
76
72
|
var GROK_INPUT_KEY_MAP = {
|
|
77
73
|
Read: { target_file: "file_path" }
|
|
78
74
|
};
|
|
75
|
+
var KIMI_TOOL_NAME_MAP = {
|
|
76
|
+
FetchURL: "WebFetch",
|
|
77
|
+
ReadMediaFile: "Read"
|
|
78
|
+
};
|
|
79
|
+
var KIMI_INPUT_KEY_MAP = {
|
|
80
|
+
Read: { path: "file_path" },
|
|
81
|
+
Write: { path: "file_path" },
|
|
82
|
+
Edit: { path: "file_path" }
|
|
83
|
+
};
|
|
79
84
|
function remapInputKeys(input, keyMap) {
|
|
80
85
|
const newInput = {};
|
|
81
86
|
for (const [k, v] of Object.entries(input)) {
|
|
@@ -84,17 +89,13 @@ function remapInputKeys(input, keyMap) {
|
|
|
84
89
|
return newInput;
|
|
85
90
|
}
|
|
86
91
|
function remapToolName(obj, toolName, nameMap, inputKeyMap) {
|
|
87
|
-
const mapped = nameMap[toolName];
|
|
92
|
+
const mapped = nameMap[toolName] ?? toolName;
|
|
88
93
|
const result = { ...obj };
|
|
89
|
-
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
if (keyMap) {
|
|
95
|
-
result["tool_input"] = remapInputKeys(rawInput, keyMap);
|
|
96
|
-
}
|
|
97
|
-
}
|
|
94
|
+
result["tool_name"] = mapped;
|
|
95
|
+
const rawInput = obj["tool_input"];
|
|
96
|
+
const keyMap = inputKeyMap[mapped];
|
|
97
|
+
if (keyMap && typeof rawInput === "object" && rawInput !== null && !Array.isArray(rawInput)) {
|
|
98
|
+
result["tool_input"] = remapInputKeys(rawInput, keyMap);
|
|
98
99
|
}
|
|
99
100
|
return result;
|
|
100
101
|
}
|
|
@@ -149,6 +150,11 @@ function normalizePayload(payload, harness = "claude") {
|
|
|
149
150
|
result2["_tg_harness"] = harness;
|
|
150
151
|
return result2;
|
|
151
152
|
}
|
|
153
|
+
if (harness === "kimi") {
|
|
154
|
+
const result2 = remapToolName(obj, toolName, KIMI_TOOL_NAME_MAP, KIMI_INPUT_KEY_MAP);
|
|
155
|
+
result2["_tg_harness"] = harness;
|
|
156
|
+
return result2;
|
|
157
|
+
}
|
|
152
158
|
if (harness === "gemini") {
|
|
153
159
|
const result2 = remapToolName(obj, toolName, GEMINI_TOOL_NAME_MAP, GEMINI_INPUT_KEY_MAP);
|
|
154
160
|
if ("functionCallId" in result2 && !("toolUseId" in result2)) {
|
|
@@ -164,7 +170,6 @@ function normalizePayload(payload, harness = "claude") {
|
|
|
164
170
|
}
|
|
165
171
|
|
|
166
172
|
// src/recall_index.ts
|
|
167
|
-
init_define_import_meta_env();
|
|
168
173
|
var VALID_TYPES = ["bash", "web", "mcp"];
|
|
169
174
|
function isRecallCacheType(value) {
|
|
170
175
|
return VALID_TYPES.includes(value);
|
|
@@ -299,7 +304,6 @@ function searchRecall(query, opts = {}) {
|
|
|
299
304
|
}
|
|
300
305
|
|
|
301
306
|
// src/bash_output_cache.ts
|
|
302
|
-
init_define_import_meta_env();
|
|
303
307
|
import { readdirSync, readFileSync, statSync } from "fs";
|
|
304
308
|
import { resolve } from "path";
|
|
305
309
|
var BASH_OUTPUT_SUBDIR = "bash_outputs";
|
|
@@ -649,7 +653,6 @@ registerReset(() => {
|
|
|
649
653
|
});
|
|
650
654
|
|
|
651
655
|
// src/web_cache.ts
|
|
652
|
-
init_define_import_meta_env();
|
|
653
656
|
var WEB_OUTPUT_SUBDIR = "web_outputs";
|
|
654
657
|
var _byId2 = /* @__PURE__ */ new Map();
|
|
655
658
|
var _rawById = /* @__PURE__ */ new Map();
|
|
@@ -706,7 +709,6 @@ registerReset(() => {
|
|
|
706
709
|
});
|
|
707
710
|
|
|
708
711
|
// src/types.ts
|
|
709
|
-
init_define_import_meta_env();
|
|
710
712
|
var HOOK_EVENTS = [
|
|
711
713
|
"pre_tool_use",
|
|
712
714
|
"post_tool_use",
|
|
@@ -719,7 +721,6 @@ var HOOK_EVENTS = [
|
|
|
719
721
|
];
|
|
720
722
|
|
|
721
723
|
// src/cli_commands.ts
|
|
722
|
-
init_define_import_meta_env();
|
|
723
724
|
function toEntry(cmd) {
|
|
724
725
|
return {
|
|
725
726
|
name: cmd.name(),
|
|
@@ -788,7 +789,6 @@ function formatCommandManifest(manifest) {
|
|
|
788
789
|
}
|
|
789
790
|
|
|
790
791
|
// src/stdin_json.ts
|
|
791
|
-
init_define_import_meta_env();
|
|
792
792
|
var DEFAULT_STDIN_TIMEOUT_MS = 5e3;
|
|
793
793
|
var MAX_STDIN_BYTES = 64 * 1024 * 1024;
|
|
794
794
|
function readStdinJson(timeoutMs = DEFAULT_STDIN_TIMEOUT_MS, maxBytes = MAX_STDIN_BYTES) {
|
|
@@ -843,7 +843,6 @@ function readStdinJson(timeoutMs = DEFAULT_STDIN_TIMEOUT_MS, maxBytes = MAX_STDI
|
|
|
843
843
|
}
|
|
844
844
|
|
|
845
845
|
// src/symbol_body_probe.ts
|
|
846
|
-
init_define_import_meta_env();
|
|
847
846
|
import * as fs from "fs";
|
|
848
847
|
var OVERSIZED_BODY_PROBE_SQL = `SELECT 1 FROM symbols WHERE LENGTH(body) > ${SYMBOL_BODY_CHAR_CAP} LIMIT 1`;
|
|
849
848
|
function checkSymbolBodySize(dbPath) {
|
|
@@ -4,13 +4,9 @@ import {
|
|
|
4
4
|
loadConfig,
|
|
5
5
|
redactSecrets,
|
|
6
6
|
stripAnsiCodes
|
|
7
|
-
} from "./token-goat-chunk-
|
|
8
|
-
import {
|
|
9
|
-
init_define_import_meta_env
|
|
10
|
-
} from "./token-goat-chunk-3UOG7PSZ.mjs";
|
|
7
|
+
} from "./token-goat-chunk-7FWBSPCT.mjs";
|
|
11
8
|
|
|
12
9
|
// src/tool_filters/helpers.ts
|
|
13
|
-
init_define_import_meta_env();
|
|
14
10
|
import * as fs from "node:fs";
|
|
15
11
|
import * as path from "node:path";
|
|
16
12
|
var DEFAULT_MAX_LINES = 1e3;
|
|
@@ -593,7 +589,6 @@ function byteLength(s) {
|
|
|
593
589
|
}
|
|
594
590
|
|
|
595
591
|
// src/tool_filters/base.ts
|
|
596
|
-
init_define_import_meta_env();
|
|
597
592
|
var DEFAULT_MIN_NET_SAVINGS_BYTES = 100;
|
|
598
593
|
function resolveMinNetSavingsBytes() {
|
|
599
594
|
try {
|
|
@@ -828,11 +823,7 @@ ${body}`;
|
|
|
828
823
|
}
|
|
829
824
|
};
|
|
830
825
|
|
|
831
|
-
// src/tool_filters/dispatch.ts
|
|
832
|
-
init_define_import_meta_env();
|
|
833
|
-
|
|
834
826
|
// src/tool_filters/generic.ts
|
|
835
|
-
init_define_import_meta_env();
|
|
836
827
|
var GenericFilter = class extends ToolFilter {
|
|
837
828
|
name = "generic";
|
|
838
829
|
compress(stdout, stderr, _exitCode, _argv) {
|
|
@@ -853,7 +844,6 @@ ${errPart}` : errPart;
|
|
|
853
844
|
};
|
|
854
845
|
|
|
855
846
|
// src/tool_filters/go_test.ts
|
|
856
|
-
init_define_import_meta_env();
|
|
857
847
|
var TEST_RUN_RE = /^=== (RUN|PAUSE|CONT|NAME)\s/;
|
|
858
848
|
var RACE_FENCE_RE = /^={10,}\s*$/;
|
|
859
849
|
var RACE_WARNING_RE = /^WARNING: DATA RACE/;
|
|
@@ -1054,11 +1044,7 @@ var GoTestFilter = class extends ToolFilter {
|
|
|
1054
1044
|
};
|
|
1055
1045
|
var goTestFilter = new GoTestFilter();
|
|
1056
1046
|
|
|
1057
|
-
// src/tool_filters/ai_clis.ts
|
|
1058
|
-
init_define_import_meta_env();
|
|
1059
|
-
|
|
1060
1047
|
// src/tool_filters/families.ts
|
|
1061
|
-
init_define_import_meta_env();
|
|
1062
1048
|
function plural(n, suffix = "s") {
|
|
1063
1049
|
return n === 1 ? "" : suffix;
|
|
1064
1050
|
}
|
|
@@ -1740,7 +1726,6 @@ var AI_CLI_FILTERS = [
|
|
|
1740
1726
|
];
|
|
1741
1727
|
|
|
1742
1728
|
// src/tool_filters/build.ts
|
|
1743
|
-
init_define_import_meta_env();
|
|
1744
1729
|
var MAKE_RECURSE_RE = /^make\[\d+\]: (?:Entering|Leaving) directory/;
|
|
1745
1730
|
var MAKE_PERCENT_RE = /^\[\s*\d+%\] (?:Building|Linking|Scanning|Generating|Installing|Compiling)\b/;
|
|
1746
1731
|
var MAKE_ECHO_RE = /^\s*(?:echo|cc|gcc|clang|g\+\+)\b.*(?<![Ee]rror|[Ww]arning)/;
|
|
@@ -3226,7 +3211,6 @@ var BUILD_FILTERS = [
|
|
|
3226
3211
|
];
|
|
3227
3212
|
|
|
3228
3213
|
// src/tool_filters/ci.ts
|
|
3229
|
-
init_define_import_meta_env();
|
|
3230
3214
|
var _GH_RUN_PASS_STEP_RE = /^\s*[✓√]\s/;
|
|
3231
3215
|
var _GH_RUN_FAIL_STEP_RE = /^\s*[X✗❌]\s|^\s*FAIL(:|ED|URE)\b|^\s*Error:\s/;
|
|
3232
3216
|
var _GH_API_URL_SUFFIX = "_url";
|
|
@@ -3432,7 +3416,12 @@ var GhRunLogFilter = class extends ToolFilter {
|
|
|
3432
3416
|
const name = pathName(first).toLowerCase();
|
|
3433
3417
|
if (stem !== "gh" && name !== "gh") return false;
|
|
3434
3418
|
const positionals = positionalArgs(argv.slice(1));
|
|
3435
|
-
return positionals.length >= 2 && positionals[0] === "run" && positionals[1] === "view" &&
|
|
3419
|
+
return positionals.length >= 2 && positionals[0] === "run" && positionals[1] === "view" && // `--log-failed` is the CI-triage spelling and emits the identical
|
|
3420
|
+
// job/step/timestamp column format, so it needs this filter too. A plain
|
|
3421
|
+
// `argv.includes('--log')` is a whole-token test and never matches it,
|
|
3422
|
+
// which sent it to GhFilter -- whose pass-step regex anchors at line
|
|
3423
|
+
// start and so matches nothing while the column prefix is still present.
|
|
3424
|
+
(argv.includes("--log") || argv.includes("--log-failed"));
|
|
3436
3425
|
}
|
|
3437
3426
|
compress(stdout, stderr, _exitCode, _argv) {
|
|
3438
3427
|
const merged = this.combineOutput(stdout, stderr);
|
|
@@ -4027,7 +4016,6 @@ var CI_FILTERS = [
|
|
|
4027
4016
|
];
|
|
4028
4017
|
|
|
4029
4018
|
// src/tool_filters/cloud.ts
|
|
4030
|
-
init_define_import_meta_env();
|
|
4031
4019
|
var _TF_REFRESH_RE = /^[a-z0-9_.[\]"-]+: (Refreshing state|Reading|Read complete|Still |Modifications complete)/;
|
|
4032
4020
|
var _TF_PLAN_SUMMARY_RE = /^Plan: \d+ to (add|change|destroy|import)/;
|
|
4033
4021
|
var _TF_NO_CHANGES_RE = /^No changes\.|^(?:This plan does nothing|Nothing to do\.)/i;
|
|
@@ -5447,7 +5435,6 @@ var CLOUD_FILTERS = [
|
|
|
5447
5435
|
];
|
|
5448
5436
|
|
|
5449
5437
|
// src/tool_filters/shell_file.ts
|
|
5450
|
-
init_define_import_meta_env();
|
|
5451
5438
|
var _GREP_COMPRESS_THRESHOLD = 30;
|
|
5452
5439
|
var _GREP_MAX_FILE_LINES = 20;
|
|
5453
5440
|
var GrepFilter = class extends ToolFilter {
|
|
@@ -6550,7 +6537,6 @@ var SHELL_FILE_FILTERS = [
|
|
|
6550
6537
|
];
|
|
6551
6538
|
|
|
6552
6539
|
// src/tool_filters/languages.ts
|
|
6553
|
-
init_define_import_meta_env();
|
|
6554
6540
|
var NODE_INTERNAL_FRAME_RE = /^\s{4}at\s+(?:node:|.+\s+\(node:)/;
|
|
6555
6541
|
var NODE_MODULES_FRAME_RE = /^\s{4}at\s+.*[/\\]node_modules[/\\]/;
|
|
6556
6542
|
var NodeFilter = class extends ToolFilter {
|
|
@@ -7775,7 +7761,6 @@ var LANGUAGE_FILTERS = [
|
|
|
7775
7761
|
];
|
|
7776
7762
|
|
|
7777
7763
|
// src/tool_filters/misc.ts
|
|
7778
|
-
init_define_import_meta_env();
|
|
7779
7764
|
var PW_PASS_RE = /^\s+[✓✔]\s/;
|
|
7780
7765
|
var PW_DOWNLOAD_RE = /^\s*(Downloading|Downloaded|Installing)\s+\w|^\s*[\d.]+\s+[KMG]b\s+\[/i;
|
|
7781
7766
|
var PlaywrightFilter = class _PlaywrightFilter extends ToolFilter {
|
|
@@ -9173,7 +9158,6 @@ var MISC_FILTERS = [
|
|
|
9173
9158
|
];
|
|
9174
9159
|
|
|
9175
9160
|
// src/tool_filters/containers.ts
|
|
9176
|
-
init_define_import_meta_env();
|
|
9177
9161
|
var _DOCKER_DIGEST_RE = /^\s*#\d+\s+(sha256:[a-f0-9]{8,}|resolve\s)/;
|
|
9178
9162
|
var _DOCKER_PROGRESS_RE = /^\s*#\d+\s+\d+(?:\.\d+)?(?:MB|kB|GB)\s+\//;
|
|
9179
9163
|
var _DOCKER_STEP_RE = /^\s*=>\s|^\s*#\d+\s+\[(internal|build|stage)/;
|
|
@@ -9835,7 +9819,6 @@ var CONTAINER_FILTERS = [
|
|
|
9835
9819
|
];
|
|
9836
9820
|
|
|
9837
9821
|
// src/tool_filters/git.ts
|
|
9838
|
-
init_define_import_meta_env();
|
|
9839
9822
|
var _GIT_VALUE_FLAGS = /* @__PURE__ */ new Set([
|
|
9840
9823
|
"-m",
|
|
9841
9824
|
"--message",
|
|
@@ -10877,7 +10860,6 @@ var GIT_FILTERS = [
|
|
|
10877
10860
|
];
|
|
10878
10861
|
|
|
10879
10862
|
// src/tool_filters/linters.ts
|
|
10880
|
-
init_define_import_meta_env();
|
|
10881
10863
|
var _ESLINT_LOC_RE = /^\s+\d+:\d+\s+(error|warning|info)\s/;
|
|
10882
10864
|
var _ESLINT_FILE_RE = /^(?:\/|[A-Za-z]:|[a-zA-Z0-9_./-]+\.(?:js|jsx|ts|tsx|mjs|cjs|vue))/;
|
|
10883
10865
|
var _ESLINT_SUMMARY_RE = /^[✖✗✘x×]\s+\d+\s+problem/;
|
|
@@ -12218,7 +12200,6 @@ var LINTER_FILTERS = [
|
|
|
12218
12200
|
];
|
|
12219
12201
|
|
|
12220
12202
|
// src/tool_filters/package_managers.ts
|
|
12221
|
-
init_define_import_meta_env();
|
|
12222
12203
|
function dedupLines(lines, maxPerKey = 1, keyFn = (l) => l.trim()) {
|
|
12223
12204
|
const seen = /* @__PURE__ */ new Map();
|
|
12224
12205
|
const out = [];
|
|
@@ -13290,7 +13271,6 @@ var PACKAGE_MANAGER_FILTERS = [
|
|
|
13290
13271
|
];
|
|
13291
13272
|
|
|
13292
13273
|
// src/tool_filters/pytest.ts
|
|
13293
|
-
init_define_import_meta_env();
|
|
13294
13274
|
var XDIST_PREFIX_RE = /^\[gw\d+\]\s*(?:\[\s*\d+%\]\s*)?/;
|
|
13295
13275
|
var DOTS_RE = /^[.FxXEsS]+\s*(\[\s*\d+%\])?\s*$/;
|
|
13296
13276
|
var BANNER_RE = /^(?:platform\s|cachedir:\s|rootdir:\s|plugins:\s|configfile:\s|bringing up\s|cacheprovider-)/;
|
|
@@ -13477,7 +13457,6 @@ var PytestFilter = class extends ToolFilter {
|
|
|
13477
13457
|
var pytestFilter = new PytestFilter();
|
|
13478
13458
|
|
|
13479
13459
|
// src/tool_filters/test_runners.ts
|
|
13480
|
-
init_define_import_meta_env();
|
|
13481
13460
|
var jestFilter = makeNodeTestRunnerFilter({
|
|
13482
13461
|
name: "jest",
|
|
13483
13462
|
binaries: ["jest", "mocha", "ava", "tap"],
|
|
@@ -13605,11 +13584,7 @@ function filterByName(name) {
|
|
|
13605
13584
|
return null;
|
|
13606
13585
|
}
|
|
13607
13586
|
|
|
13608
|
-
// src/tool_filters/index.ts
|
|
13609
|
-
init_define_import_meta_env();
|
|
13610
|
-
|
|
13611
13587
|
// src/shell.ts
|
|
13612
|
-
init_define_import_meta_env();
|
|
13613
13588
|
import * as fs2 from "node:fs";
|
|
13614
13589
|
import * as path2 from "node:path";
|
|
13615
13590
|
var WSL_LAUNCHER_SEGMENTS = /* @__PURE__ */ new Set(["system32", "syswow64", "windowsapps"]);
|
|
@@ -4,13 +4,9 @@ import {
|
|
|
4
4
|
loadConfig,
|
|
5
5
|
redactSecrets,
|
|
6
6
|
stripAnsiCodes
|
|
7
|
-
} from "./token-goat-hook-chunk-
|
|
8
|
-
import {
|
|
9
|
-
init_define_import_meta_env
|
|
10
|
-
} from "./token-goat-hook-chunk-K33JMLL7.mjs";
|
|
7
|
+
} from "./token-goat-hook-chunk-CNLMPHXT.mjs";
|
|
11
8
|
|
|
12
9
|
// src/tool_filters/helpers.ts
|
|
13
|
-
init_define_import_meta_env();
|
|
14
10
|
import * as fs from "node:fs";
|
|
15
11
|
import * as path from "node:path";
|
|
16
12
|
var DEFAULT_MAX_LINES = 1e3;
|
|
@@ -593,7 +589,6 @@ function byteLength(s) {
|
|
|
593
589
|
}
|
|
594
590
|
|
|
595
591
|
// src/tool_filters/base.ts
|
|
596
|
-
init_define_import_meta_env();
|
|
597
592
|
var DEFAULT_MIN_NET_SAVINGS_BYTES = 100;
|
|
598
593
|
function resolveMinNetSavingsBytes() {
|
|
599
594
|
try {
|
|
@@ -828,11 +823,7 @@ ${body}`;
|
|
|
828
823
|
}
|
|
829
824
|
};
|
|
830
825
|
|
|
831
|
-
// src/tool_filters/dispatch.ts
|
|
832
|
-
init_define_import_meta_env();
|
|
833
|
-
|
|
834
826
|
// src/tool_filters/generic.ts
|
|
835
|
-
init_define_import_meta_env();
|
|
836
827
|
var GenericFilter = class extends ToolFilter {
|
|
837
828
|
name = "generic";
|
|
838
829
|
compress(stdout, stderr, _exitCode, _argv) {
|
|
@@ -853,7 +844,6 @@ ${errPart}` : errPart;
|
|
|
853
844
|
};
|
|
854
845
|
|
|
855
846
|
// src/tool_filters/go_test.ts
|
|
856
|
-
init_define_import_meta_env();
|
|
857
847
|
var TEST_RUN_RE = /^=== (RUN|PAUSE|CONT|NAME)\s/;
|
|
858
848
|
var RACE_FENCE_RE = /^={10,}\s*$/;
|
|
859
849
|
var RACE_WARNING_RE = /^WARNING: DATA RACE/;
|
|
@@ -1054,11 +1044,7 @@ var GoTestFilter = class extends ToolFilter {
|
|
|
1054
1044
|
};
|
|
1055
1045
|
var goTestFilter = new GoTestFilter();
|
|
1056
1046
|
|
|
1057
|
-
// src/tool_filters/ai_clis.ts
|
|
1058
|
-
init_define_import_meta_env();
|
|
1059
|
-
|
|
1060
1047
|
// src/tool_filters/families.ts
|
|
1061
|
-
init_define_import_meta_env();
|
|
1062
1048
|
function plural(n, suffix = "s") {
|
|
1063
1049
|
return n === 1 ? "" : suffix;
|
|
1064
1050
|
}
|
|
@@ -1740,7 +1726,6 @@ var AI_CLI_FILTERS = [
|
|
|
1740
1726
|
];
|
|
1741
1727
|
|
|
1742
1728
|
// src/tool_filters/build.ts
|
|
1743
|
-
init_define_import_meta_env();
|
|
1744
1729
|
var MAKE_RECURSE_RE = /^make\[\d+\]: (?:Entering|Leaving) directory/;
|
|
1745
1730
|
var MAKE_PERCENT_RE = /^\[\s*\d+%\] (?:Building|Linking|Scanning|Generating|Installing|Compiling)\b/;
|
|
1746
1731
|
var MAKE_ECHO_RE = /^\s*(?:echo|cc|gcc|clang|g\+\+)\b.*(?<![Ee]rror|[Ww]arning)/;
|
|
@@ -3226,7 +3211,6 @@ var BUILD_FILTERS = [
|
|
|
3226
3211
|
];
|
|
3227
3212
|
|
|
3228
3213
|
// src/tool_filters/ci.ts
|
|
3229
|
-
init_define_import_meta_env();
|
|
3230
3214
|
var _GH_RUN_PASS_STEP_RE = /^\s*[✓√]\s/;
|
|
3231
3215
|
var _GH_RUN_FAIL_STEP_RE = /^\s*[X✗❌]\s|^\s*FAIL(:|ED|URE)\b|^\s*Error:\s/;
|
|
3232
3216
|
var _GH_API_URL_SUFFIX = "_url";
|
|
@@ -3432,7 +3416,12 @@ var GhRunLogFilter = class extends ToolFilter {
|
|
|
3432
3416
|
const name = pathName(first).toLowerCase();
|
|
3433
3417
|
if (stem !== "gh" && name !== "gh") return false;
|
|
3434
3418
|
const positionals = positionalArgs(argv.slice(1));
|
|
3435
|
-
return positionals.length >= 2 && positionals[0] === "run" && positionals[1] === "view" &&
|
|
3419
|
+
return positionals.length >= 2 && positionals[0] === "run" && positionals[1] === "view" && // `--log-failed` is the CI-triage spelling and emits the identical
|
|
3420
|
+
// job/step/timestamp column format, so it needs this filter too. A plain
|
|
3421
|
+
// `argv.includes('--log')` is a whole-token test and never matches it,
|
|
3422
|
+
// which sent it to GhFilter -- whose pass-step regex anchors at line
|
|
3423
|
+
// start and so matches nothing while the column prefix is still present.
|
|
3424
|
+
(argv.includes("--log") || argv.includes("--log-failed"));
|
|
3436
3425
|
}
|
|
3437
3426
|
compress(stdout, stderr, _exitCode, _argv) {
|
|
3438
3427
|
const merged = this.combineOutput(stdout, stderr);
|
|
@@ -4027,7 +4016,6 @@ var CI_FILTERS = [
|
|
|
4027
4016
|
];
|
|
4028
4017
|
|
|
4029
4018
|
// src/tool_filters/cloud.ts
|
|
4030
|
-
init_define_import_meta_env();
|
|
4031
4019
|
var _TF_REFRESH_RE = /^[a-z0-9_.[\]"-]+: (Refreshing state|Reading|Read complete|Still |Modifications complete)/;
|
|
4032
4020
|
var _TF_PLAN_SUMMARY_RE = /^Plan: \d+ to (add|change|destroy|import)/;
|
|
4033
4021
|
var _TF_NO_CHANGES_RE = /^No changes\.|^(?:This plan does nothing|Nothing to do\.)/i;
|
|
@@ -5447,7 +5435,6 @@ var CLOUD_FILTERS = [
|
|
|
5447
5435
|
];
|
|
5448
5436
|
|
|
5449
5437
|
// src/tool_filters/shell_file.ts
|
|
5450
|
-
init_define_import_meta_env();
|
|
5451
5438
|
var _GREP_COMPRESS_THRESHOLD = 30;
|
|
5452
5439
|
var _GREP_MAX_FILE_LINES = 20;
|
|
5453
5440
|
var GrepFilter = class extends ToolFilter {
|
|
@@ -6550,7 +6537,6 @@ var SHELL_FILE_FILTERS = [
|
|
|
6550
6537
|
];
|
|
6551
6538
|
|
|
6552
6539
|
// src/tool_filters/languages.ts
|
|
6553
|
-
init_define_import_meta_env();
|
|
6554
6540
|
var NODE_INTERNAL_FRAME_RE = /^\s{4}at\s+(?:node:|.+\s+\(node:)/;
|
|
6555
6541
|
var NODE_MODULES_FRAME_RE = /^\s{4}at\s+.*[/\\]node_modules[/\\]/;
|
|
6556
6542
|
var NodeFilter = class extends ToolFilter {
|
|
@@ -7775,7 +7761,6 @@ var LANGUAGE_FILTERS = [
|
|
|
7775
7761
|
];
|
|
7776
7762
|
|
|
7777
7763
|
// src/tool_filters/misc.ts
|
|
7778
|
-
init_define_import_meta_env();
|
|
7779
7764
|
var PW_PASS_RE = /^\s+[✓✔]\s/;
|
|
7780
7765
|
var PW_DOWNLOAD_RE = /^\s*(Downloading|Downloaded|Installing)\s+\w|^\s*[\d.]+\s+[KMG]b\s+\[/i;
|
|
7781
7766
|
var PlaywrightFilter = class _PlaywrightFilter extends ToolFilter {
|
|
@@ -9173,7 +9158,6 @@ var MISC_FILTERS = [
|
|
|
9173
9158
|
];
|
|
9174
9159
|
|
|
9175
9160
|
// src/tool_filters/containers.ts
|
|
9176
|
-
init_define_import_meta_env();
|
|
9177
9161
|
var _DOCKER_DIGEST_RE = /^\s*#\d+\s+(sha256:[a-f0-9]{8,}|resolve\s)/;
|
|
9178
9162
|
var _DOCKER_PROGRESS_RE = /^\s*#\d+\s+\d+(?:\.\d+)?(?:MB|kB|GB)\s+\//;
|
|
9179
9163
|
var _DOCKER_STEP_RE = /^\s*=>\s|^\s*#\d+\s+\[(internal|build|stage)/;
|
|
@@ -9835,7 +9819,6 @@ var CONTAINER_FILTERS = [
|
|
|
9835
9819
|
];
|
|
9836
9820
|
|
|
9837
9821
|
// src/tool_filters/git.ts
|
|
9838
|
-
init_define_import_meta_env();
|
|
9839
9822
|
var _GIT_VALUE_FLAGS = /* @__PURE__ */ new Set([
|
|
9840
9823
|
"-m",
|
|
9841
9824
|
"--message",
|
|
@@ -10877,7 +10860,6 @@ var GIT_FILTERS = [
|
|
|
10877
10860
|
];
|
|
10878
10861
|
|
|
10879
10862
|
// src/tool_filters/linters.ts
|
|
10880
|
-
init_define_import_meta_env();
|
|
10881
10863
|
var _ESLINT_LOC_RE = /^\s+\d+:\d+\s+(error|warning|info)\s/;
|
|
10882
10864
|
var _ESLINT_FILE_RE = /^(?:\/|[A-Za-z]:|[a-zA-Z0-9_./-]+\.(?:js|jsx|ts|tsx|mjs|cjs|vue))/;
|
|
10883
10865
|
var _ESLINT_SUMMARY_RE = /^[✖✗✘x×]\s+\d+\s+problem/;
|
|
@@ -12218,7 +12200,6 @@ var LINTER_FILTERS = [
|
|
|
12218
12200
|
];
|
|
12219
12201
|
|
|
12220
12202
|
// src/tool_filters/package_managers.ts
|
|
12221
|
-
init_define_import_meta_env();
|
|
12222
12203
|
function dedupLines(lines, maxPerKey = 1, keyFn = (l) => l.trim()) {
|
|
12223
12204
|
const seen = /* @__PURE__ */ new Map();
|
|
12224
12205
|
const out = [];
|
|
@@ -13290,7 +13271,6 @@ var PACKAGE_MANAGER_FILTERS = [
|
|
|
13290
13271
|
];
|
|
13291
13272
|
|
|
13292
13273
|
// src/tool_filters/pytest.ts
|
|
13293
|
-
init_define_import_meta_env();
|
|
13294
13274
|
var XDIST_PREFIX_RE = /^\[gw\d+\]\s*(?:\[\s*\d+%\]\s*)?/;
|
|
13295
13275
|
var DOTS_RE = /^[.FxXEsS]+\s*(\[\s*\d+%\])?\s*$/;
|
|
13296
13276
|
var BANNER_RE = /^(?:platform\s|cachedir:\s|rootdir:\s|plugins:\s|configfile:\s|bringing up\s|cacheprovider-)/;
|
|
@@ -13477,7 +13457,6 @@ var PytestFilter = class extends ToolFilter {
|
|
|
13477
13457
|
var pytestFilter = new PytestFilter();
|
|
13478
13458
|
|
|
13479
13459
|
// src/tool_filters/test_runners.ts
|
|
13480
|
-
init_define_import_meta_env();
|
|
13481
13460
|
var jestFilter = makeNodeTestRunnerFilter({
|
|
13482
13461
|
name: "jest",
|
|
13483
13462
|
binaries: ["jest", "mocha", "ava", "tap"],
|
|
@@ -13605,11 +13584,7 @@ function filterByName(name) {
|
|
|
13605
13584
|
return null;
|
|
13606
13585
|
}
|
|
13607
13586
|
|
|
13608
|
-
// src/tool_filters/index.ts
|
|
13609
|
-
init_define_import_meta_env();
|
|
13610
|
-
|
|
13611
13587
|
// src/shell.ts
|
|
13612
|
-
init_define_import_meta_env();
|
|
13613
13588
|
import * as fs2 from "node:fs";
|
|
13614
13589
|
import * as path2 from "node:path";
|
|
13615
13590
|
var WSL_LAUNCHER_SEGMENTS = /* @__PURE__ */ new Set(["system32", "syswow64", "windowsapps"]);
|