kirograph 0.13.1 → 0.14.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 +191 -8
- package/dist/bin/commands/caveman.js +7 -2
- package/dist/bin/commands/caveman.js.map +2 -2
- package/dist/bin/commands/compression.js +109 -0
- package/dist/bin/commands/compression.js.map +7 -0
- package/dist/bin/commands/context.js +31 -24
- package/dist/bin/commands/context.js.map +2 -2
- package/dist/bin/commands/exec.js +107 -0
- package/dist/bin/commands/exec.js.map +7 -0
- package/dist/bin/commands/gain.js +119 -0
- package/dist/bin/commands/gain.js.map +7 -0
- package/dist/bin/commands/help.js +10 -1
- package/dist/bin/commands/help.js.map +2 -2
- package/dist/bin/commands/query.js +5 -1
- package/dist/bin/commands/query.js.map +2 -2
- package/dist/bin/commands/uninit.js +1 -1
- package/dist/bin/commands/uninit.js.map +2 -2
- package/dist/bin/commands/utils.js +16 -0
- package/dist/bin/commands/utils.js.map +2 -2
- package/dist/bin/installer/config-prompt.js +9 -2
- package/dist/bin/installer/config-prompt.js.map +2 -2
- package/dist/bin/installer/hooks.js +19 -1
- package/dist/bin/installer/hooks.js.map +2 -2
- package/dist/bin/installer/index.js +6 -1
- package/dist/bin/installer/index.js.map +2 -2
- package/dist/bin/installer/steering.js +116 -40
- package/dist/bin/installer/steering.js.map +2 -2
- package/dist/bin/installer/targets/index.js.map +1 -1
- package/dist/bin/installer/targets/kiro.js +4 -2
- package/dist/bin/installer/targets/kiro.js.map +2 -2
- package/dist/bin/kirograph.js +7 -1
- package/dist/bin/kirograph.js.map +3 -3
- package/dist/compression/filters/aws.js +418 -0
- package/dist/compression/filters/aws.js.map +7 -0
- package/dist/compression/filters/docker.js +153 -0
- package/dist/compression/filters/docker.js.map +7 -0
- package/dist/compression/filters/files.js +150 -0
- package/dist/compression/filters/files.js.map +7 -0
- package/dist/compression/filters/generic.js +86 -0
- package/dist/compression/filters/generic.js.map +7 -0
- package/dist/compression/filters/git.js +272 -0
- package/dist/compression/filters/git.js.map +7 -0
- package/dist/compression/filters/github.js +137 -0
- package/dist/compression/filters/github.js.map +7 -0
- package/dist/compression/filters/lint.js +280 -0
- package/dist/compression/filters/lint.js.map +7 -0
- package/dist/compression/filters/misc.js +212 -0
- package/dist/compression/filters/misc.js.map +7 -0
- package/dist/compression/filters/package.js +151 -0
- package/dist/compression/filters/package.js.map +7 -0
- package/dist/compression/filters/test.js +266 -0
- package/dist/compression/filters/test.js.map +7 -0
- package/dist/compression/index.js +144 -0
- package/dist/compression/index.js.map +7 -0
- package/dist/compression/naive-cost.js +94 -0
- package/dist/compression/naive-cost.js.map +7 -0
- package/dist/compression/tracker.js +228 -0
- package/dist/compression/tracker.js.map +7 -0
- package/dist/compression/types.js +17 -0
- package/dist/compression/types.js.map +7 -0
- package/dist/config.js +18 -1
- package/dist/config.js.map +2 -2
- package/dist/mcp/tool-names.js +3 -1
- package/dist/mcp/tool-names.js.map +2 -2
- package/dist/mcp/tools.js +170 -4
- package/dist/mcp/tools.js.map +3 -3
- package/package.json +1 -1
|
@@ -0,0 +1,272 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var git_exports = {};
|
|
20
|
+
__export(git_exports, {
|
|
21
|
+
gitFilter: () => gitFilter
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(git_exports);
|
|
24
|
+
const gitFilter = {
|
|
25
|
+
name: "git",
|
|
26
|
+
matches(command) {
|
|
27
|
+
return /^\s*(git\s|rtk\s+git\s)/.test(command);
|
|
28
|
+
},
|
|
29
|
+
filter(command, rawOutput, level) {
|
|
30
|
+
const subcommand = extractGitSubcommand(command);
|
|
31
|
+
switch (subcommand) {
|
|
32
|
+
case "status":
|
|
33
|
+
return filterGitStatus(rawOutput, level);
|
|
34
|
+
case "log":
|
|
35
|
+
return filterGitLog(rawOutput, level);
|
|
36
|
+
case "diff":
|
|
37
|
+
return filterGitDiff(rawOutput, level);
|
|
38
|
+
case "push":
|
|
39
|
+
return filterGitPush(rawOutput);
|
|
40
|
+
case "pull":
|
|
41
|
+
return filterGitPull(rawOutput);
|
|
42
|
+
case "add":
|
|
43
|
+
return filterGitAdd(rawOutput);
|
|
44
|
+
case "commit":
|
|
45
|
+
return filterGitCommit(rawOutput);
|
|
46
|
+
case "fetch":
|
|
47
|
+
return filterGitFetch(rawOutput);
|
|
48
|
+
case "branch":
|
|
49
|
+
return filterGitBranch(rawOutput, level);
|
|
50
|
+
case "stash":
|
|
51
|
+
return filterGitStash(rawOutput);
|
|
52
|
+
default:
|
|
53
|
+
return { output: rawOutput, strategy: "git:passthrough" };
|
|
54
|
+
}
|
|
55
|
+
}
|
|
56
|
+
};
|
|
57
|
+
function extractGitSubcommand(command) {
|
|
58
|
+
const match = command.match(/git\s+(\w+)/);
|
|
59
|
+
return match ? match[1] : "";
|
|
60
|
+
}
|
|
61
|
+
function filterGitStatus(raw, level) {
|
|
62
|
+
const lines = raw.split("\n").filter((l) => l.trim());
|
|
63
|
+
if (raw.includes("nothing to commit") || raw.includes("working tree clean")) {
|
|
64
|
+
return { output: "clean", strategy: "git:status:clean" };
|
|
65
|
+
}
|
|
66
|
+
const staged = [];
|
|
67
|
+
const modified = [];
|
|
68
|
+
const untracked = [];
|
|
69
|
+
const deleted = [];
|
|
70
|
+
const renamed = [];
|
|
71
|
+
let section = "";
|
|
72
|
+
for (const line of lines) {
|
|
73
|
+
if (line.includes("Changes to be committed")) {
|
|
74
|
+
section = "staged";
|
|
75
|
+
continue;
|
|
76
|
+
}
|
|
77
|
+
if (line.includes("Changes not staged")) {
|
|
78
|
+
section = "unstaged";
|
|
79
|
+
continue;
|
|
80
|
+
}
|
|
81
|
+
if (line.includes("Untracked files")) {
|
|
82
|
+
section = "untracked";
|
|
83
|
+
continue;
|
|
84
|
+
}
|
|
85
|
+
if (line.startsWith(" (use")) continue;
|
|
86
|
+
if (line.startsWith("On branch") || line.startsWith("Your branch")) continue;
|
|
87
|
+
const trimmed = line.trim();
|
|
88
|
+
if (!trimmed) continue;
|
|
89
|
+
const shortMatch = trimmed.match(/^([MADRCU?! ]{1,2})\s+(.+)$/);
|
|
90
|
+
if (shortMatch) {
|
|
91
|
+
const [, status, file] = shortMatch;
|
|
92
|
+
if (status.includes("M")) modified.push(file);
|
|
93
|
+
else if (status.includes("A")) staged.push(file);
|
|
94
|
+
else if (status.includes("D")) deleted.push(file);
|
|
95
|
+
else if (status.includes("R")) renamed.push(file);
|
|
96
|
+
else if (status.includes("?")) untracked.push(file);
|
|
97
|
+
continue;
|
|
98
|
+
}
|
|
99
|
+
if (section === "staged") {
|
|
100
|
+
const m = trimmed.match(/(?:new file|modified|deleted|renamed):\s+(.+)/);
|
|
101
|
+
if (m) staged.push(m[1]);
|
|
102
|
+
} else if (section === "unstaged") {
|
|
103
|
+
const m = trimmed.match(/(?:modified|deleted):\s+(.+)/);
|
|
104
|
+
if (m) modified.push(m[1]);
|
|
105
|
+
} else if (section === "untracked") {
|
|
106
|
+
if (!trimmed.startsWith("(")) untracked.push(trimmed);
|
|
107
|
+
}
|
|
108
|
+
}
|
|
109
|
+
if (level === "ultra") {
|
|
110
|
+
const parts2 = [];
|
|
111
|
+
if (staged.length) parts2.push(`S:${staged.length}`);
|
|
112
|
+
if (modified.length) parts2.push(`M:${modified.length}`);
|
|
113
|
+
if (deleted.length) parts2.push(`D:${deleted.length}`);
|
|
114
|
+
if (untracked.length) parts2.push(`?:${untracked.length}`);
|
|
115
|
+
if (renamed.length) parts2.push(`R:${renamed.length}`);
|
|
116
|
+
return { output: parts2.join(" ") || "clean", strategy: "git:status:ultra" };
|
|
117
|
+
}
|
|
118
|
+
const parts = [];
|
|
119
|
+
if (staged.length) parts.push(`Staged (${staged.length}): ${groupByDir(staged, level)}`);
|
|
120
|
+
if (modified.length) parts.push(`Modified (${modified.length}): ${groupByDir(modified, level)}`);
|
|
121
|
+
if (deleted.length) parts.push(`Deleted (${deleted.length}): ${groupByDir(deleted, level)}`);
|
|
122
|
+
if (untracked.length) parts.push(`Untracked (${untracked.length}): ${groupByDir(untracked, level)}`);
|
|
123
|
+
if (renamed.length) parts.push(`Renamed (${renamed.length}): ${groupByDir(renamed, level)}`);
|
|
124
|
+
return { output: parts.join("\n") || raw, strategy: "git:status" };
|
|
125
|
+
}
|
|
126
|
+
function filterGitLog(raw, level) {
|
|
127
|
+
const lines = raw.split("\n");
|
|
128
|
+
if (lines.every((l) => !l.startsWith("commit ") && !l.startsWith("Author:"))) {
|
|
129
|
+
const filtered = lines.filter((l) => l.trim()).slice(0, level === "ultra" ? 10 : 20);
|
|
130
|
+
return { output: filtered.join("\n"), strategy: "git:log:oneline" };
|
|
131
|
+
}
|
|
132
|
+
const commits = [];
|
|
133
|
+
let currentHash = "";
|
|
134
|
+
let currentMsg = "";
|
|
135
|
+
for (const line of lines) {
|
|
136
|
+
if (line.startsWith("commit ")) {
|
|
137
|
+
if (currentHash && currentMsg) {
|
|
138
|
+
commits.push(`${currentHash.slice(0, 7)} ${currentMsg.trim()}`);
|
|
139
|
+
}
|
|
140
|
+
currentHash = line.replace("commit ", "").trim();
|
|
141
|
+
currentMsg = "";
|
|
142
|
+
} else if (!line.startsWith("Author:") && !line.startsWith("Date:") && !line.startsWith("Merge:")) {
|
|
143
|
+
if (line.trim()) currentMsg = currentMsg || line.trim();
|
|
144
|
+
}
|
|
145
|
+
}
|
|
146
|
+
if (currentHash && currentMsg) {
|
|
147
|
+
commits.push(`${currentHash.slice(0, 7)} ${currentMsg.trim()}`);
|
|
148
|
+
}
|
|
149
|
+
const limit = level === "ultra" ? 10 : 20;
|
|
150
|
+
const output = commits.slice(0, limit).join("\n");
|
|
151
|
+
return { output: output || raw, strategy: "git:log" };
|
|
152
|
+
}
|
|
153
|
+
function filterGitDiff(raw, level) {
|
|
154
|
+
const lines = raw.split("\n");
|
|
155
|
+
const result = [];
|
|
156
|
+
let contextLines = level === "ultra" ? 1 : level === "aggressive" ? 2 : 3;
|
|
157
|
+
let inHunk = false;
|
|
158
|
+
let afterChange = 0;
|
|
159
|
+
let contextBuffer = [];
|
|
160
|
+
for (const line of lines) {
|
|
161
|
+
if (line.startsWith("diff --git") || line.startsWith("---") || line.startsWith("+++")) {
|
|
162
|
+
result.push(line);
|
|
163
|
+
inHunk = false;
|
|
164
|
+
contextBuffer = [];
|
|
165
|
+
continue;
|
|
166
|
+
}
|
|
167
|
+
if (line.startsWith("@@")) {
|
|
168
|
+
result.push(line);
|
|
169
|
+
inHunk = true;
|
|
170
|
+
afterChange = 0;
|
|
171
|
+
contextBuffer = [];
|
|
172
|
+
continue;
|
|
173
|
+
}
|
|
174
|
+
if (!inHunk) continue;
|
|
175
|
+
if (line.startsWith("+") || line.startsWith("-")) {
|
|
176
|
+
if (contextBuffer.length > 0) {
|
|
177
|
+
const keep = contextBuffer.slice(-contextLines);
|
|
178
|
+
result.push(...keep);
|
|
179
|
+
contextBuffer = [];
|
|
180
|
+
}
|
|
181
|
+
result.push(line);
|
|
182
|
+
afterChange = 0;
|
|
183
|
+
continue;
|
|
184
|
+
}
|
|
185
|
+
afterChange++;
|
|
186
|
+
if (afterChange <= contextLines) {
|
|
187
|
+
result.push(line);
|
|
188
|
+
} else {
|
|
189
|
+
contextBuffer.push(line);
|
|
190
|
+
}
|
|
191
|
+
}
|
|
192
|
+
return { output: result.join("\n"), strategy: "git:diff" };
|
|
193
|
+
}
|
|
194
|
+
function filterGitPush(raw) {
|
|
195
|
+
const branchMatch = raw.match(/(\S+)\s*->\s*(\S+)/);
|
|
196
|
+
if (branchMatch) {
|
|
197
|
+
return { output: `ok ${branchMatch[1]} \u2192 ${branchMatch[2]}`, strategy: "git:push" };
|
|
198
|
+
}
|
|
199
|
+
if (raw.includes("Everything up-to-date")) {
|
|
200
|
+
return { output: "ok (up-to-date)", strategy: "git:push" };
|
|
201
|
+
}
|
|
202
|
+
const meaningful = raw.split("\n").filter((l) => l.trim() && !l.includes("Enumerating") && !l.includes("Counting") && !l.includes("Compressing") && !l.includes("Writing"));
|
|
203
|
+
return { output: meaningful.pop() || "ok", strategy: "git:push" };
|
|
204
|
+
}
|
|
205
|
+
function filterGitPull(raw) {
|
|
206
|
+
if (raw.includes("Already up to date")) {
|
|
207
|
+
return { output: "ok (up-to-date)", strategy: "git:pull" };
|
|
208
|
+
}
|
|
209
|
+
const filesMatch = raw.match(/(\d+)\s+file/);
|
|
210
|
+
const insertMatch = raw.match(/(\d+)\s+insertion/);
|
|
211
|
+
const deleteMatch = raw.match(/(\d+)\s+deletion/);
|
|
212
|
+
const files = filesMatch ? filesMatch[1] : "0";
|
|
213
|
+
const ins = insertMatch ? `+${insertMatch[1]}` : "+0";
|
|
214
|
+
const del = deleteMatch ? `-${deleteMatch[1]}` : "-0";
|
|
215
|
+
return { output: `ok ${files} files ${ins} ${del}`, strategy: "git:pull" };
|
|
216
|
+
}
|
|
217
|
+
function filterGitAdd(raw) {
|
|
218
|
+
if (!raw.trim()) return { output: "ok", strategy: "git:add" };
|
|
219
|
+
return { output: raw.trim() || "ok", strategy: "git:add" };
|
|
220
|
+
}
|
|
221
|
+
function filterGitCommit(raw) {
|
|
222
|
+
const hashMatch = raw.match(/\[[\w/]+\s+([a-f0-9]+)\]/);
|
|
223
|
+
if (hashMatch) {
|
|
224
|
+
return { output: `ok ${hashMatch[1]}`, strategy: "git:commit" };
|
|
225
|
+
}
|
|
226
|
+
const firstLine = raw.split("\n").find((l) => l.trim());
|
|
227
|
+
return { output: firstLine || "ok", strategy: "git:commit" };
|
|
228
|
+
}
|
|
229
|
+
function filterGitFetch(raw) {
|
|
230
|
+
if (!raw.trim()) return { output: "ok", strategy: "git:fetch" };
|
|
231
|
+
const lines = raw.split("\n").filter((l) => l.trim() && !l.startsWith("remote:"));
|
|
232
|
+
return { output: lines.length > 0 ? lines.join("\n") : "ok", strategy: "git:fetch" };
|
|
233
|
+
}
|
|
234
|
+
function filterGitBranch(raw, level) {
|
|
235
|
+
const lines = raw.split("\n").filter((l) => l.trim());
|
|
236
|
+
const current = lines.find((l) => l.startsWith("*"));
|
|
237
|
+
const others = lines.filter((l) => !l.startsWith("*")).map((l) => l.trim());
|
|
238
|
+
if (level === "ultra") {
|
|
239
|
+
return {
|
|
240
|
+
output: `* ${current?.replace("*", "").trim() || "?"} (+${others.length} branches)`,
|
|
241
|
+
strategy: "git:branch:ultra"
|
|
242
|
+
};
|
|
243
|
+
}
|
|
244
|
+
const limit = level === "aggressive" ? 10 : 20;
|
|
245
|
+
const shown = others.slice(0, limit);
|
|
246
|
+
const parts = [current || "* (unknown)"];
|
|
247
|
+
parts.push(...shown);
|
|
248
|
+
if (others.length > limit) parts.push(` \u2026and ${others.length - limit} more`);
|
|
249
|
+
return { output: parts.join("\n"), strategy: "git:branch" };
|
|
250
|
+
}
|
|
251
|
+
function filterGitStash(raw) {
|
|
252
|
+
const lines = raw.split("\n").filter((l) => l.trim());
|
|
253
|
+
if (lines.length === 0) return { output: "ok", strategy: "git:stash" };
|
|
254
|
+
return { output: lines.slice(0, 10).join("\n"), strategy: "git:stash" };
|
|
255
|
+
}
|
|
256
|
+
function groupByDir(files, level) {
|
|
257
|
+
if (level === "aggressive" || level === "ultra") {
|
|
258
|
+
const dirs = /* @__PURE__ */ new Map();
|
|
259
|
+
for (const f of files) {
|
|
260
|
+
const dir = f.includes("/") ? f.slice(0, f.lastIndexOf("/")) : ".";
|
|
261
|
+
dirs.set(dir, (dirs.get(dir) || 0) + 1);
|
|
262
|
+
}
|
|
263
|
+
return [...dirs.entries()].map(([d, c]) => `${d}/ (${c})`).join(", ");
|
|
264
|
+
}
|
|
265
|
+
if (files.length <= 5) return files.join(", ");
|
|
266
|
+
return files.slice(0, 5).join(", ") + ` \u2026+${files.length - 5} more`;
|
|
267
|
+
}
|
|
268
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
269
|
+
0 && (module.exports = {
|
|
270
|
+
gitFilter
|
|
271
|
+
});
|
|
272
|
+
//# sourceMappingURL=git.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/compression/filters/git.ts"],
|
|
4
|
+
"sourcesContent": ["/**\n * Git command output filters\n */\n\nimport type { CommandFilter, FilterResult, CompressorOptions } from '../types';\n\nexport const gitFilter: CommandFilter = {\n name: 'git',\n\n matches(command: string): boolean {\n return /^\\s*(git\\s|rtk\\s+git\\s)/.test(command);\n },\n\n filter(command: string, rawOutput: string, level: CompressorOptions['level']): FilterResult {\n const subcommand = extractGitSubcommand(command);\n\n switch (subcommand) {\n case 'status': return filterGitStatus(rawOutput, level);\n case 'log': return filterGitLog(rawOutput, level);\n case 'diff': return filterGitDiff(rawOutput, level);\n case 'push': return filterGitPush(rawOutput);\n case 'pull': return filterGitPull(rawOutput);\n case 'add': return filterGitAdd(rawOutput);\n case 'commit': return filterGitCommit(rawOutput);\n case 'fetch': return filterGitFetch(rawOutput);\n case 'branch': return filterGitBranch(rawOutput, level);\n case 'stash': return filterGitStash(rawOutput);\n default: return { output: rawOutput, strategy: 'git:passthrough' };\n }\n },\n};\n\nfunction extractGitSubcommand(command: string): string {\n const match = command.match(/git\\s+(\\w+)/);\n return match ? match[1] : '';\n}\n\nfunction filterGitStatus(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n').filter(l => l.trim());\n\n // Detect clean state\n if (raw.includes('nothing to commit') || raw.includes('working tree clean')) {\n return { output: 'clean', strategy: 'git:status:clean' };\n }\n\n const staged: string[] = [];\n const modified: string[] = [];\n const untracked: string[] = [];\n const deleted: string[] = [];\n const renamed: string[] = [];\n\n let section = '';\n for (const line of lines) {\n if (line.includes('Changes to be committed')) { section = 'staged'; continue; }\n if (line.includes('Changes not staged')) { section = 'unstaged'; continue; }\n if (line.includes('Untracked files')) { section = 'untracked'; continue; }\n if (line.startsWith(' (use')) continue; // hint lines\n if (line.startsWith('On branch') || line.startsWith('Your branch')) continue;\n\n const trimmed = line.trim();\n if (!trimmed) continue;\n\n // Short format (git status -s) or porcelain\n const shortMatch = trimmed.match(/^([MADRCU?! ]{1,2})\\s+(.+)$/);\n if (shortMatch) {\n const [, status, file] = shortMatch;\n if (status.includes('M')) modified.push(file);\n else if (status.includes('A')) staged.push(file);\n else if (status.includes('D')) deleted.push(file);\n else if (status.includes('R')) renamed.push(file);\n else if (status.includes('?')) untracked.push(file);\n continue;\n }\n\n // Long format\n if (section === 'staged') {\n const m = trimmed.match(/(?:new file|modified|deleted|renamed):\\s+(.+)/);\n if (m) staged.push(m[1]);\n } else if (section === 'unstaged') {\n const m = trimmed.match(/(?:modified|deleted):\\s+(.+)/);\n if (m) modified.push(m[1]);\n } else if (section === 'untracked') {\n if (!trimmed.startsWith('(')) untracked.push(trimmed);\n }\n }\n\n if (level === 'ultra') {\n const parts: string[] = [];\n if (staged.length) parts.push(`S:${staged.length}`);\n if (modified.length) parts.push(`M:${modified.length}`);\n if (deleted.length) parts.push(`D:${deleted.length}`);\n if (untracked.length) parts.push(`?:${untracked.length}`);\n if (renamed.length) parts.push(`R:${renamed.length}`);\n return { output: parts.join(' ') || 'clean', strategy: 'git:status:ultra' };\n }\n\n const parts: string[] = [];\n if (staged.length) parts.push(`Staged (${staged.length}): ${groupByDir(staged, level)}`);\n if (modified.length) parts.push(`Modified (${modified.length}): ${groupByDir(modified, level)}`);\n if (deleted.length) parts.push(`Deleted (${deleted.length}): ${groupByDir(deleted, level)}`);\n if (untracked.length) parts.push(`Untracked (${untracked.length}): ${groupByDir(untracked, level)}`);\n if (renamed.length) parts.push(`Renamed (${renamed.length}): ${groupByDir(renamed, level)}`);\n\n return { output: parts.join('\\n') || raw, strategy: 'git:status' };\n}\n\nfunction filterGitLog(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n');\n\n // Already one-line format\n if (lines.every(l => !l.startsWith('commit ') && !l.startsWith('Author:'))) {\n const filtered = lines.filter(l => l.trim()).slice(0, level === 'ultra' ? 10 : 20);\n return { output: filtered.join('\\n'), strategy: 'git:log:oneline' };\n }\n\n // Parse full format into one-line\n const commits: string[] = [];\n let currentHash = '';\n let currentMsg = '';\n\n for (const line of lines) {\n if (line.startsWith('commit ')) {\n if (currentHash && currentMsg) {\n commits.push(`${currentHash.slice(0, 7)} ${currentMsg.trim()}`);\n }\n currentHash = line.replace('commit ', '').trim();\n currentMsg = '';\n } else if (!line.startsWith('Author:') && !line.startsWith('Date:') && !line.startsWith('Merge:')) {\n if (line.trim()) currentMsg = currentMsg || line.trim();\n }\n }\n if (currentHash && currentMsg) {\n commits.push(`${currentHash.slice(0, 7)} ${currentMsg.trim()}`);\n }\n\n const limit = level === 'ultra' ? 10 : 20;\n const output = commits.slice(0, limit).join('\\n');\n return { output: output || raw, strategy: 'git:log' };\n}\n\nfunction filterGitDiff(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n');\n const result: string[] = [];\n let contextLines = level === 'ultra' ? 1 : level === 'aggressive' ? 2 : 3;\n let inHunk = false;\n let afterChange = 0;\n let contextBuffer: string[] = [];\n\n for (const line of lines) {\n // Keep file headers\n if (line.startsWith('diff --git') || line.startsWith('---') || line.startsWith('+++')) {\n result.push(line);\n inHunk = false;\n contextBuffer = [];\n continue;\n }\n\n // Keep hunk headers\n if (line.startsWith('@@')) {\n result.push(line);\n inHunk = true;\n afterChange = 0;\n contextBuffer = [];\n continue;\n }\n\n if (!inHunk) continue;\n\n // Changed lines \u2014 always keep\n if (line.startsWith('+') || line.startsWith('-')) {\n // Flush context buffer (last N lines before change)\n if (contextBuffer.length > 0) {\n const keep = contextBuffer.slice(-contextLines);\n result.push(...keep);\n contextBuffer = [];\n }\n result.push(line);\n afterChange = 0;\n continue;\n }\n\n // Context lines after a change\n afterChange++;\n if (afterChange <= contextLines) {\n result.push(line);\n } else {\n contextBuffer.push(line);\n }\n }\n\n return { output: result.join('\\n'), strategy: 'git:diff' };\n}\n\nfunction filterGitPush(raw: string): FilterResult {\n // Extract branch and remote info\n const branchMatch = raw.match(/(\\S+)\\s*->\\s*(\\S+)/);\n if (branchMatch) {\n return { output: `ok ${branchMatch[1]} \u2192 ${branchMatch[2]}`, strategy: 'git:push' };\n }\n if (raw.includes('Everything up-to-date')) {\n return { output: 'ok (up-to-date)', strategy: 'git:push' };\n }\n // Fallback: just show last meaningful line\n const meaningful = raw.split('\\n').filter(l => l.trim() && !l.includes('Enumerating') && !l.includes('Counting') && !l.includes('Compressing') && !l.includes('Writing'));\n return { output: meaningful.pop() || 'ok', strategy: 'git:push' };\n}\n\nfunction filterGitPull(raw: string): FilterResult {\n if (raw.includes('Already up to date')) {\n return { output: 'ok (up-to-date)', strategy: 'git:pull' };\n }\n\n const filesMatch = raw.match(/(\\d+)\\s+file/);\n const insertMatch = raw.match(/(\\d+)\\s+insertion/);\n const deleteMatch = raw.match(/(\\d+)\\s+deletion/);\n\n const files = filesMatch ? filesMatch[1] : '0';\n const ins = insertMatch ? `+${insertMatch[1]}` : '+0';\n const del = deleteMatch ? `-${deleteMatch[1]}` : '-0';\n\n return { output: `ok ${files} files ${ins} ${del}`, strategy: 'git:pull' };\n}\n\nfunction filterGitAdd(raw: string): FilterResult {\n // git add produces no output on success\n if (!raw.trim()) return { output: 'ok', strategy: 'git:add' };\n return { output: raw.trim() || 'ok', strategy: 'git:add' };\n}\n\nfunction filterGitCommit(raw: string): FilterResult {\n const hashMatch = raw.match(/\\[[\\w/]+\\s+([a-f0-9]+)\\]/);\n if (hashMatch) {\n return { output: `ok ${hashMatch[1]}`, strategy: 'git:commit' };\n }\n // Fallback\n const firstLine = raw.split('\\n').find(l => l.trim());\n return { output: firstLine || 'ok', strategy: 'git:commit' };\n}\n\nfunction filterGitFetch(raw: string): FilterResult {\n if (!raw.trim()) return { output: 'ok', strategy: 'git:fetch' };\n const lines = raw.split('\\n').filter(l => l.trim() && !l.startsWith('remote:'));\n return { output: lines.length > 0 ? lines.join('\\n') : 'ok', strategy: 'git:fetch' };\n}\n\nfunction filterGitBranch(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n').filter(l => l.trim());\n const current = lines.find(l => l.startsWith('*'));\n const others = lines.filter(l => !l.startsWith('*')).map(l => l.trim());\n\n if (level === 'ultra') {\n return {\n output: `* ${current?.replace('*', '').trim() || '?'} (+${others.length} branches)`,\n strategy: 'git:branch:ultra',\n };\n }\n\n const limit = level === 'aggressive' ? 10 : 20;\n const shown = others.slice(0, limit);\n const parts = [current || '* (unknown)'];\n parts.push(...shown);\n if (others.length > limit) parts.push(` \u2026and ${others.length - limit} more`);\n\n return { output: parts.join('\\n'), strategy: 'git:branch' };\n}\n\nfunction filterGitStash(raw: string): FilterResult {\n const lines = raw.split('\\n').filter(l => l.trim());\n if (lines.length === 0) return { output: 'ok', strategy: 'git:stash' };\n return { output: lines.slice(0, 10).join('\\n'), strategy: 'git:stash' };\n}\n\n// \u2500\u2500 Helpers \u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\u2500\n\nfunction groupByDir(files: string[], level: CompressorOptions['level']): string {\n if (level === 'aggressive' || level === 'ultra') {\n const dirs = new Map<string, number>();\n for (const f of files) {\n const dir = f.includes('/') ? f.slice(0, f.lastIndexOf('/')) : '.';\n dirs.set(dir, (dirs.get(dir) || 0) + 1);\n }\n return [...dirs.entries()].map(([d, c]) => `${d}/ (${c})`).join(', ');\n }\n // Normal: show up to 5 files, then count\n if (files.length <= 5) return files.join(', ');\n return files.slice(0, 5).join(', ') + ` \u2026+${files.length - 5} more`;\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAMO,MAAM,YAA2B;AAAA,EACtC,MAAM;AAAA,EAEN,QAAQ,SAA0B;AAChC,WAAO,0BAA0B,KAAK,OAAO;AAAA,EAC/C;AAAA,EAEA,OAAO,SAAiB,WAAmB,OAAiD;AAC1F,UAAM,aAAa,qBAAqB,OAAO;AAE/C,YAAQ,YAAY;AAAA,MAClB,KAAK;AAAU,eAAO,gBAAgB,WAAW,KAAK;AAAA,MACtD,KAAK;AAAO,eAAO,aAAa,WAAW,KAAK;AAAA,MAChD,KAAK;AAAQ,eAAO,cAAc,WAAW,KAAK;AAAA,MAClD,KAAK;AAAQ,eAAO,cAAc,SAAS;AAAA,MAC3C,KAAK;AAAQ,eAAO,cAAc,SAAS;AAAA,MAC3C,KAAK;AAAO,eAAO,aAAa,SAAS;AAAA,MACzC,KAAK;AAAU,eAAO,gBAAgB,SAAS;AAAA,MAC/C,KAAK;AAAS,eAAO,eAAe,SAAS;AAAA,MAC7C,KAAK;AAAU,eAAO,gBAAgB,WAAW,KAAK;AAAA,MACtD,KAAK;AAAS,eAAO,eAAe,SAAS;AAAA,MA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AI,MAAM,IAAI,EAAE,OAAO,OAAK,EAAE,KAAK,CAAC;AAClD,MAAI,MAAM,WAAW,EAAG,QAAO,EAAE,QAAQ,MAAM,UAAU,YAAY;AACrE,SAAO,EAAE,QAAQ,MAAM,MAAM,GAAG,EAAE,EAAE,KAAK,IAAI,GAAG,UAAU,YAAY;AACxE;AAIA,SAAS,WAAW,OAAiB,OAA2C;AAC9E,MAAI,UAAU,gBAAgB,UAAU,SAAS;AAC/C,UAAM,OAAO,oBAAI,IAAoB;AACrC,eAAW,KAAK,OAAO;AACrB,YAAM,MAAM,EAAE,SAAS,GAAG,IAAI,EAAE,MAAM,GAAG,EAAE,YAAY,GAAG,CAAC,IAAI;AAC/D,WAAK,IAAI,MAAM,KAAK,IAAI,GAAG,KAAK,KAAK,CAAC;AAAA,IACxC;AACA,WAAO,CAAC,GAAG,KAAK,QAAQ,CAAC,EAAE,IAAI,CAAC,CAAC,GAAG,CAAC,MAAM,GAAG,CAAC,MAAM,CAAC,GAAG,EAAE,KAAK,IAAI;AAAA,EACtE;AAEA,MAAI,MAAM,UAAU,EAAG,QAAO,MAAM,KAAK,IAAI;AAC7C,SAAO,MAAM,MAAM,GAAG,CAAC,EAAE,KAAK,IAAI,IAAI,WAAM,MAAM,SAAS,CAAC;AAC9D;",
|
|
6
|
+
"names": ["parts"]
|
|
7
|
+
}
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
"use strict";
|
|
2
|
+
var __defProp = Object.defineProperty;
|
|
3
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
4
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
5
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
6
|
+
var __export = (target, all) => {
|
|
7
|
+
for (var name in all)
|
|
8
|
+
__defProp(target, name, { get: all[name], enumerable: true });
|
|
9
|
+
};
|
|
10
|
+
var __copyProps = (to, from, except, desc) => {
|
|
11
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
12
|
+
for (let key of __getOwnPropNames(from))
|
|
13
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
14
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
15
|
+
}
|
|
16
|
+
return to;
|
|
17
|
+
};
|
|
18
|
+
var __toCommonJS = (mod) => __copyProps(__defProp({}, "__esModule", { value: true }), mod);
|
|
19
|
+
var github_exports = {};
|
|
20
|
+
__export(github_exports, {
|
|
21
|
+
githubFilter: () => githubFilter
|
|
22
|
+
});
|
|
23
|
+
module.exports = __toCommonJS(github_exports);
|
|
24
|
+
const githubFilter = {
|
|
25
|
+
name: "gh",
|
|
26
|
+
matches(command) {
|
|
27
|
+
return /\bgh\s/.test(command);
|
|
28
|
+
},
|
|
29
|
+
filter(command, rawOutput, level) {
|
|
30
|
+
if (/gh\s+pr\s+list/.test(command)) return filterPrList(rawOutput, level);
|
|
31
|
+
if (/gh\s+pr\s+view/.test(command)) return filterPrView(rawOutput, level);
|
|
32
|
+
if (/gh\s+pr\s+checks/.test(command)) return filterPrChecks(rawOutput, level);
|
|
33
|
+
if (/gh\s+issue\s+list/.test(command)) return filterIssueList(rawOutput, level);
|
|
34
|
+
if (/gh\s+run\s+list/.test(command)) return filterRunList(rawOutput, level);
|
|
35
|
+
if (/gh\s+run\s+view/.test(command)) return filterRunView(rawOutput, level);
|
|
36
|
+
return { output: rawOutput, strategy: "gh:passthrough" };
|
|
37
|
+
}
|
|
38
|
+
};
|
|
39
|
+
function filterPrList(raw, level) {
|
|
40
|
+
const lines = raw.split("\n").filter((l) => l.trim());
|
|
41
|
+
if (lines.length === 0) return { output: "no open PRs", strategy: "gh:pr-list:empty" };
|
|
42
|
+
if (level === "ultra") {
|
|
43
|
+
return { output: `${lines.length} PRs`, strategy: "gh:pr-list:ultra" };
|
|
44
|
+
}
|
|
45
|
+
const compact = lines.map((l) => {
|
|
46
|
+
const parts = l.split(" ");
|
|
47
|
+
if (parts.length >= 3) {
|
|
48
|
+
const [num, title, branch] = parts;
|
|
49
|
+
return `#${num} ${title} (${branch})`;
|
|
50
|
+
}
|
|
51
|
+
return l;
|
|
52
|
+
});
|
|
53
|
+
const maxLines = level === "aggressive" ? 10 : 20;
|
|
54
|
+
const shown = compact.slice(0, maxLines).join("\n");
|
|
55
|
+
const extra = compact.length > maxLines ? `
|
|
56
|
+
\u2026+${compact.length - maxLines} more` : "";
|
|
57
|
+
return { output: `${compact.length} PRs:
|
|
58
|
+
${shown}${extra}`, strategy: "gh:pr-list" };
|
|
59
|
+
}
|
|
60
|
+
function filterPrView(raw, level) {
|
|
61
|
+
const lines = raw.split("\n");
|
|
62
|
+
if (level === "ultra") {
|
|
63
|
+
const titleLine = lines.find((l) => l.startsWith("title:") || /^#\d+/.test(l.trim()));
|
|
64
|
+
const stateLine = lines.find((l) => l.includes("OPEN") || l.includes("MERGED") || l.includes("CLOSED"));
|
|
65
|
+
return { output: (titleLine || lines[0] || "").trim() + (stateLine ? ` [${stateLine.trim()}]` : ""), strategy: "gh:pr-view:ultra" };
|
|
66
|
+
}
|
|
67
|
+
const important = lines.filter((l) => {
|
|
68
|
+
const trimmed = l.trim();
|
|
69
|
+
if (!trimmed) return false;
|
|
70
|
+
if (trimmed.startsWith("--")) return false;
|
|
71
|
+
return true;
|
|
72
|
+
});
|
|
73
|
+
const maxLines = level === "aggressive" ? 20 : 40;
|
|
74
|
+
if (important.length <= maxLines) return { output: important.join("\n"), strategy: "gh:pr-view" };
|
|
75
|
+
return { output: important.slice(0, maxLines).join("\n") + `
|
|
76
|
+
\u2026+${important.length - maxLines} more lines`, strategy: "gh:pr-view" };
|
|
77
|
+
}
|
|
78
|
+
function filterPrChecks(raw, level) {
|
|
79
|
+
const lines = raw.split("\n").filter((l) => l.trim());
|
|
80
|
+
if (lines.length === 0) return { output: "no checks", strategy: "gh:pr-checks:empty" };
|
|
81
|
+
const passed = lines.filter((l) => l.includes("pass") || l.includes("\u2713")).length;
|
|
82
|
+
const failed = lines.filter((l) => l.includes("fail") || l.includes("\u2717") || l.includes("X")).length;
|
|
83
|
+
if (level === "ultra") {
|
|
84
|
+
return { output: failed > 0 ? `\u2717 ${failed} failed, ${passed} passed` : `\u2713 ${passed} passed`, strategy: "gh:pr-checks:ultra" };
|
|
85
|
+
}
|
|
86
|
+
return { output: raw, strategy: "gh:pr-checks" };
|
|
87
|
+
}
|
|
88
|
+
function filterIssueList(raw, level) {
|
|
89
|
+
const lines = raw.split("\n").filter((l) => l.trim());
|
|
90
|
+
if (lines.length === 0) return { output: "no open issues", strategy: "gh:issue-list:empty" };
|
|
91
|
+
if (level === "ultra") {
|
|
92
|
+
return { output: `${lines.length} issues`, strategy: "gh:issue-list:ultra" };
|
|
93
|
+
}
|
|
94
|
+
const compact = lines.map((l) => {
|
|
95
|
+
const parts = l.split(" ");
|
|
96
|
+
if (parts.length >= 3) {
|
|
97
|
+
const [num, title] = parts;
|
|
98
|
+
return `#${num} ${title}`;
|
|
99
|
+
}
|
|
100
|
+
return l;
|
|
101
|
+
});
|
|
102
|
+
const maxLines = level === "aggressive" ? 10 : 20;
|
|
103
|
+
const shown = compact.slice(0, maxLines).join("\n");
|
|
104
|
+
const extra = compact.length > maxLines ? `
|
|
105
|
+
\u2026+${compact.length - maxLines} more` : "";
|
|
106
|
+
return { output: `${compact.length} issues:
|
|
107
|
+
${shown}${extra}`, strategy: "gh:issue-list" };
|
|
108
|
+
}
|
|
109
|
+
function filterRunList(raw, level) {
|
|
110
|
+
const lines = raw.split("\n").filter((l) => l.trim());
|
|
111
|
+
if (lines.length === 0) return { output: "no runs", strategy: "gh:run-list:empty" };
|
|
112
|
+
if (level === "ultra") {
|
|
113
|
+
const failed = lines.filter((l) => l.includes("failure") || l.includes("X")).length;
|
|
114
|
+
return { output: failed > 0 ? `${lines.length} runs (${failed} failed)` : `${lines.length} runs`, strategy: "gh:run-list:ultra" };
|
|
115
|
+
}
|
|
116
|
+
const maxLines = level === "aggressive" ? 10 : 20;
|
|
117
|
+
const shown = lines.slice(0, maxLines).join("\n");
|
|
118
|
+
const extra = lines.length > maxLines ? `
|
|
119
|
+
\u2026+${lines.length - maxLines} more` : "";
|
|
120
|
+
return { output: `${shown}${extra}`, strategy: "gh:run-list" };
|
|
121
|
+
}
|
|
122
|
+
function filterRunView(raw, level) {
|
|
123
|
+
const lines = raw.split("\n").filter((l) => l.trim());
|
|
124
|
+
if (level === "ultra") {
|
|
125
|
+
const statusLine = lines.find((l) => l.includes("completed") || l.includes("in_progress") || l.includes("failure"));
|
|
126
|
+
return { output: statusLine || lines[0] || "", strategy: "gh:run-view:ultra" };
|
|
127
|
+
}
|
|
128
|
+
const maxLines = level === "aggressive" ? 20 : 40;
|
|
129
|
+
if (lines.length <= maxLines) return { output: raw, strategy: "gh:run-view" };
|
|
130
|
+
return { output: lines.slice(0, maxLines).join("\n") + `
|
|
131
|
+
\u2026+${lines.length - maxLines} more`, strategy: "gh:run-view" };
|
|
132
|
+
}
|
|
133
|
+
// Annotate the CommonJS export names for ESM import in node:
|
|
134
|
+
0 && (module.exports = {
|
|
135
|
+
githubFilter
|
|
136
|
+
});
|
|
137
|
+
//# sourceMappingURL=github.js.map
|
|
@@ -0,0 +1,7 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../../../src/compression/filters/github.ts"],
|
|
4
|
+
"sourcesContent": ["/**\n * GitHub CLI (gh) output filters\n */\n\nimport type { CommandFilter, FilterResult, CompressorOptions } from '../types';\n\nexport const githubFilter: CommandFilter = {\n name: 'gh',\n\n matches(command: string): boolean {\n return /\\bgh\\s/.test(command);\n },\n\n filter(command: string, rawOutput: string, level: CompressorOptions['level']): FilterResult {\n if (/gh\\s+pr\\s+list/.test(command)) return filterPrList(rawOutput, level);\n if (/gh\\s+pr\\s+view/.test(command)) return filterPrView(rawOutput, level);\n if (/gh\\s+pr\\s+checks/.test(command)) return filterPrChecks(rawOutput, level);\n if (/gh\\s+issue\\s+list/.test(command)) return filterIssueList(rawOutput, level);\n if (/gh\\s+run\\s+list/.test(command)) return filterRunList(rawOutput, level);\n if (/gh\\s+run\\s+view/.test(command)) return filterRunView(rawOutput, level);\n return { output: rawOutput, strategy: 'gh:passthrough' };\n },\n};\n\nfunction filterPrList(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n').filter(l => l.trim());\n if (lines.length === 0) return { output: 'no open PRs', strategy: 'gh:pr-list:empty' };\n\n if (level === 'ultra') {\n return { output: `${lines.length} PRs`, strategy: 'gh:pr-list:ultra' };\n }\n\n // gh pr list outputs tab-separated: number, title, branch, status\n const compact = lines.map(l => {\n const parts = l.split('\\t');\n if (parts.length >= 3) {\n const [num, title, branch] = parts;\n return `#${num} ${title} (${branch})`;\n }\n return l;\n });\n\n const maxLines = level === 'aggressive' ? 10 : 20;\n const shown = compact.slice(0, maxLines).join('\\n');\n const extra = compact.length > maxLines ? `\\n\u2026+${compact.length - maxLines} more` : '';\n\n return { output: `${compact.length} PRs:\\n${shown}${extra}`, strategy: 'gh:pr-list' };\n}\n\nfunction filterPrView(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n');\n\n if (level === 'ultra') {\n // Extract title and state\n const titleLine = lines.find(l => l.startsWith('title:') || /^#\\d+/.test(l.trim()));\n const stateLine = lines.find(l => l.includes('OPEN') || l.includes('MERGED') || l.includes('CLOSED'));\n return { output: (titleLine || lines[0] || '').trim() + (stateLine ? ` [${stateLine.trim()}]` : ''), strategy: 'gh:pr-view:ultra' };\n }\n\n // Strip verbose metadata, keep: title, state, author, body summary, checks\n const important = lines.filter(l => {\n const trimmed = l.trim();\n if (!trimmed) return false;\n if (trimmed.startsWith('--')) return false;\n return true;\n });\n\n const maxLines = level === 'aggressive' ? 20 : 40;\n if (important.length <= maxLines) return { output: important.join('\\n'), strategy: 'gh:pr-view' };\n\n return { output: important.slice(0, maxLines).join('\\n') + `\\n\u2026+${important.length - maxLines} more lines`, strategy: 'gh:pr-view' };\n}\n\nfunction filterPrChecks(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n').filter(l => l.trim());\n if (lines.length === 0) return { output: 'no checks', strategy: 'gh:pr-checks:empty' };\n\n const passed = lines.filter(l => l.includes('pass') || l.includes('\u2713')).length;\n const failed = lines.filter(l => l.includes('fail') || l.includes('\u2717') || l.includes('X')).length;\n\n if (level === 'ultra') {\n return { output: failed > 0 ? `\u2717 ${failed} failed, ${passed} passed` : `\u2713 ${passed} passed`, strategy: 'gh:pr-checks:ultra' };\n }\n\n return { output: raw, strategy: 'gh:pr-checks' };\n}\n\nfunction filterIssueList(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n').filter(l => l.trim());\n if (lines.length === 0) return { output: 'no open issues', strategy: 'gh:issue-list:empty' };\n\n if (level === 'ultra') {\n return { output: `${lines.length} issues`, strategy: 'gh:issue-list:ultra' };\n }\n\n const compact = lines.map(l => {\n const parts = l.split('\\t');\n if (parts.length >= 3) {\n const [num, title] = parts;\n return `#${num} ${title}`;\n }\n return l;\n });\n\n const maxLines = level === 'aggressive' ? 10 : 20;\n const shown = compact.slice(0, maxLines).join('\\n');\n const extra = compact.length > maxLines ? `\\n\u2026+${compact.length - maxLines} more` : '';\n\n return { output: `${compact.length} issues:\\n${shown}${extra}`, strategy: 'gh:issue-list' };\n}\n\nfunction filterRunList(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n').filter(l => l.trim());\n if (lines.length === 0) return { output: 'no runs', strategy: 'gh:run-list:empty' };\n\n if (level === 'ultra') {\n const failed = lines.filter(l => l.includes('failure') || l.includes('X')).length;\n return { output: failed > 0 ? `${lines.length} runs (${failed} failed)` : `${lines.length} runs`, strategy: 'gh:run-list:ultra' };\n }\n\n const maxLines = level === 'aggressive' ? 10 : 20;\n const shown = lines.slice(0, maxLines).join('\\n');\n const extra = lines.length > maxLines ? `\\n\u2026+${lines.length - maxLines} more` : '';\n\n return { output: `${shown}${extra}`, strategy: 'gh:run-list' };\n}\n\nfunction filterRunView(raw: string, level: CompressorOptions['level']): FilterResult {\n const lines = raw.split('\\n').filter(l => l.trim());\n\n if (level === 'ultra') {\n const statusLine = lines.find(l => l.includes('completed') || l.includes('in_progress') || l.includes('failure'));\n return { output: statusLine || lines[0] || '', strategy: 'gh:run-view:ultra' };\n }\n\n const maxLines = level === 'aggressive' ? 20 : 40;\n if (lines.length <= maxLines) return { output: raw, strategy: 'gh:run-view' };\n return { output: lines.slice(0, maxLines).join('\\n') + `\\n\u2026+${lines.length - maxLines} more`, strategy: 'gh:run-view' };\n}\n"],
|
|
5
|
+
"mappings": ";;;;;;;;;;;;;;;;;;AAAA;AAAA;AAAA;AAAA;AAAA;AAMO,MAAM,eAA8B;AAAA,EACzC,MAAM;AAAA,EAEN,QAAQ,SAA0B;AAChC,WAAO,SAAS,KAAK,OAAO;AAAA,EAC9B;AAAA,EAEA,OAAO,SAAiB,WAAmB,OAAiD;AAC1F,QAAI,iBAAiB,KAAK,OAAO,EAAG,QAAO,aAAa,WAAW,KAAK;AACxE,QAAI,iBAAiB,KAAK,OAAO,EAAG,QAAO,aAAa,WAAW,KAAK;AACxE,QAAI,mBAAmB,KAAK,OAAO,EAAG,QAAO,eAAe,WAAW,KAAK;AAC5E,QAAI,oBAAoB,KAAK,OAAO,EAAG,QAAO,gBAAgB,WAAW,KAAK;AAC9E,QAAI,kBAAkB,KAAK,OAAO,EAAG,QAAO,cAAc,WAAW,KAAK;AAC1E,QAAI,kBAAkB,KAAK,OAAO,EAAG,QAAO,cAAc,WAAW,KAAK;AAC1E,WAAO,EAAE,QAAQ,WAAW,UAAU,iBAAiB;AAAA,EACzD;AACF;AAEA,SAAS,aAAa,KAAa,OAAiD;AAClF,QAAM,QAAQ,IAAI,MAAM,IAAI,EAAE,OAAO,OAAK,EAAE,KAAK,CAAC;AAClD,MAAI,MAAM,WAAW,EAAG,QAAO,EAAE,QAAQ,eAAe,UAAU,mBAAmB;AAErF,MAAI,UAAU,SAAS;AACrB,WAA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