@kb-labs/quality-entry 2.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 +120 -0
- package/dist/cli/commands/build-order.d.ts +16 -0
- package/dist/cli/commands/build-order.js +113 -0
- package/dist/cli/commands/build-order.js.map +1 -0
- package/dist/cli/commands/check-builds.d.ts +10 -0
- package/dist/cli/commands/check-builds.js +93 -0
- package/dist/cli/commands/check-builds.js.map +1 -0
- package/dist/cli/commands/check-tests.d.ts +10 -0
- package/dist/cli/commands/check-tests.js +114 -0
- package/dist/cli/commands/check-tests.js.map +1 -0
- package/dist/cli/commands/check-types.d.ts +10 -0
- package/dist/cli/commands/check-types.js +108 -0
- package/dist/cli/commands/check-types.js.map +1 -0
- package/dist/cli/commands/cycles.d.ts +17 -0
- package/dist/cli/commands/cycles.js +85 -0
- package/dist/cli/commands/cycles.js.map +1 -0
- package/dist/cli/commands/dead-code.d.ts +10 -0
- package/dist/cli/commands/dead-code.js +217 -0
- package/dist/cli/commands/dead-code.js.map +1 -0
- package/dist/cli/commands/fix-deps.d.ts +28 -0
- package/dist/cli/commands/fix-deps.js +389 -0
- package/dist/cli/commands/fix-deps.js.map +1 -0
- package/dist/cli/commands/flags.d.ts +344 -0
- package/dist/cli/commands/flags.js +298 -0
- package/dist/cli/commands/flags.js.map +1 -0
- package/dist/cli/commands/health.d.ts +10 -0
- package/dist/cli/commands/health.js +210 -0
- package/dist/cli/commands/health.js.map +1 -0
- package/dist/cli/commands/index.d.ts +14 -0
- package/dist/cli/commands/index.js +1747 -0
- package/dist/cli/commands/index.js.map +1 -0
- package/dist/cli/commands/stats.d.ts +10 -0
- package/dist/cli/commands/stats.js +282 -0
- package/dist/cli/commands/stats.js.map +1 -0
- package/dist/cli/commands/visualize.d.ts +26 -0
- package/dist/cli/commands/visualize.js +210 -0
- package/dist/cli/commands/visualize.js.map +1 -0
- package/dist/index.d.ts +2 -0
- package/dist/index.js +666 -0
- package/dist/index.js.map +1 -0
- package/dist/manifest.d.ts +168 -0
- package/dist/manifest.js +666 -0
- package/dist/manifest.js.map +1 -0
- package/dist/rest/handlers/build-order-handler.d.ts +17 -0
- package/dist/rest/handlers/build-order-handler.js +28 -0
- package/dist/rest/handlers/build-order-handler.js.map +1 -0
- package/dist/rest/handlers/builds-handler.d.ts +12 -0
- package/dist/rest/handlers/builds-handler.js +17 -0
- package/dist/rest/handlers/builds-handler.js.map +1 -0
- package/dist/rest/handlers/cycles-handler.d.ts +13 -0
- package/dist/rest/handlers/cycles-handler.js +23 -0
- package/dist/rest/handlers/cycles-handler.js.map +1 -0
- package/dist/rest/handlers/dependencies-handler.d.ts +14 -0
- package/dist/rest/handlers/dependencies-handler.js +19 -0
- package/dist/rest/handlers/dependencies-handler.js.map +1 -0
- package/dist/rest/handlers/graph-handler.d.ts +30 -0
- package/dist/rest/handlers/graph-handler.js +155 -0
- package/dist/rest/handlers/graph-handler.js.map +1 -0
- package/dist/rest/handlers/health-handler.d.ts +15 -0
- package/dist/rest/handlers/health-handler.js +19 -0
- package/dist/rest/handlers/health-handler.js.map +1 -0
- package/dist/rest/handlers/stale-handler.d.ts +30 -0
- package/dist/rest/handlers/stale-handler.js +20 -0
- package/dist/rest/handlers/stale-handler.js.map +1 -0
- package/dist/rest/handlers/stats-handler.d.ts +16 -0
- package/dist/rest/handlers/stats-handler.js +29 -0
- package/dist/rest/handlers/stats-handler.js.map +1 -0
- package/dist/rest/handlers/tests-handler.d.ts +14 -0
- package/dist/rest/handlers/tests-handler.js +19 -0
- package/dist/rest/handlers/tests-handler.js.map +1 -0
- package/dist/rest/handlers/types-handler.d.ts +12 -0
- package/dist/rest/handlers/types-handler.js +17 -0
- package/dist/rest/handlers/types-handler.js.map +1 -0
- package/package.json +98 -0
|
@@ -0,0 +1,344 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* Shared command flags definitions
|
|
3
|
+
*
|
|
4
|
+
* DRY pattern: Define flags once, use in both manifest and command handlers.
|
|
5
|
+
*/
|
|
6
|
+
/**
|
|
7
|
+
* Flags for quality:stats command
|
|
8
|
+
*/
|
|
9
|
+
declare const statsFlags: {
|
|
10
|
+
readonly json: {
|
|
11
|
+
readonly type: "boolean";
|
|
12
|
+
readonly description: "Output JSON format";
|
|
13
|
+
readonly default: false;
|
|
14
|
+
};
|
|
15
|
+
readonly md: {
|
|
16
|
+
readonly type: "boolean";
|
|
17
|
+
readonly description: "Output Markdown table";
|
|
18
|
+
readonly default: false;
|
|
19
|
+
};
|
|
20
|
+
readonly health: {
|
|
21
|
+
readonly type: "boolean";
|
|
22
|
+
readonly description: "Show health score";
|
|
23
|
+
readonly default: false;
|
|
24
|
+
};
|
|
25
|
+
readonly refresh: {
|
|
26
|
+
readonly type: "boolean";
|
|
27
|
+
readonly description: "Bypass cache and recalculate";
|
|
28
|
+
readonly default: false;
|
|
29
|
+
};
|
|
30
|
+
};
|
|
31
|
+
type StatsFlags = typeof statsFlags;
|
|
32
|
+
/**
|
|
33
|
+
* Flags for quality:health command
|
|
34
|
+
*/
|
|
35
|
+
declare const healthFlags: {
|
|
36
|
+
readonly json: {
|
|
37
|
+
readonly type: "boolean";
|
|
38
|
+
readonly description: "Output JSON format";
|
|
39
|
+
readonly default: false;
|
|
40
|
+
};
|
|
41
|
+
readonly package: {
|
|
42
|
+
readonly type: "string";
|
|
43
|
+
readonly description: "Check health for specific package";
|
|
44
|
+
readonly alias: "p";
|
|
45
|
+
};
|
|
46
|
+
readonly detailed: {
|
|
47
|
+
readonly type: "boolean";
|
|
48
|
+
readonly description: "Show detailed breakdown";
|
|
49
|
+
readonly default: false;
|
|
50
|
+
readonly alias: "d";
|
|
51
|
+
};
|
|
52
|
+
};
|
|
53
|
+
type HealthFlags = typeof healthFlags;
|
|
54
|
+
/**
|
|
55
|
+
* Flags for quality:fix-deps command
|
|
56
|
+
*/
|
|
57
|
+
declare const fixDepsFlags: {
|
|
58
|
+
readonly 'dry-run': {
|
|
59
|
+
readonly type: "boolean";
|
|
60
|
+
readonly description: "Preview changes without applying them";
|
|
61
|
+
readonly default: false;
|
|
62
|
+
};
|
|
63
|
+
readonly 'remove-unused': {
|
|
64
|
+
readonly type: "boolean";
|
|
65
|
+
readonly description: "Remove unused dependencies";
|
|
66
|
+
readonly default: false;
|
|
67
|
+
};
|
|
68
|
+
readonly 'add-missing': {
|
|
69
|
+
readonly type: "boolean";
|
|
70
|
+
readonly description: "Add missing workspace dependencies";
|
|
71
|
+
readonly default: false;
|
|
72
|
+
};
|
|
73
|
+
readonly 'align-versions': {
|
|
74
|
+
readonly type: "boolean";
|
|
75
|
+
readonly description: "Align duplicate dependency versions";
|
|
76
|
+
readonly default: false;
|
|
77
|
+
};
|
|
78
|
+
readonly all: {
|
|
79
|
+
readonly type: "boolean";
|
|
80
|
+
readonly description: "Apply all fixes (remove-unused + add-missing + align-versions)";
|
|
81
|
+
readonly default: false;
|
|
82
|
+
};
|
|
83
|
+
readonly stats: {
|
|
84
|
+
readonly type: "boolean";
|
|
85
|
+
readonly description: "Show dependency statistics";
|
|
86
|
+
readonly default: false;
|
|
87
|
+
};
|
|
88
|
+
readonly json: {
|
|
89
|
+
readonly type: "boolean";
|
|
90
|
+
readonly description: "Output JSON format";
|
|
91
|
+
readonly default: false;
|
|
92
|
+
};
|
|
93
|
+
};
|
|
94
|
+
type FixDepsFlags = typeof fixDepsFlags;
|
|
95
|
+
/**
|
|
96
|
+
* Flags for quality:run command
|
|
97
|
+
*/
|
|
98
|
+
declare const runFlags: {
|
|
99
|
+
readonly script: {
|
|
100
|
+
readonly type: "string";
|
|
101
|
+
readonly description: "Script to run (build, test, type-check, lint)";
|
|
102
|
+
readonly required: true;
|
|
103
|
+
};
|
|
104
|
+
readonly 'continue-on-error': {
|
|
105
|
+
readonly type: "boolean";
|
|
106
|
+
readonly description: "Continue even if packages fail";
|
|
107
|
+
readonly default: true;
|
|
108
|
+
};
|
|
109
|
+
readonly parallel: {
|
|
110
|
+
readonly type: "boolean";
|
|
111
|
+
readonly description: "Run in parallel (respects dependencies)";
|
|
112
|
+
readonly default: false;
|
|
113
|
+
};
|
|
114
|
+
readonly filter: {
|
|
115
|
+
readonly type: "string";
|
|
116
|
+
readonly description: "Filter packages by pattern (@kb-labs/*)";
|
|
117
|
+
};
|
|
118
|
+
readonly json: {
|
|
119
|
+
readonly type: "boolean";
|
|
120
|
+
readonly description: "Output JSON format";
|
|
121
|
+
readonly default: false;
|
|
122
|
+
};
|
|
123
|
+
readonly verbose: {
|
|
124
|
+
readonly type: "boolean";
|
|
125
|
+
readonly description: "Show full output for each package";
|
|
126
|
+
readonly default: false;
|
|
127
|
+
readonly alias: "v";
|
|
128
|
+
};
|
|
129
|
+
};
|
|
130
|
+
type RunFlags = typeof runFlags;
|
|
131
|
+
/**
|
|
132
|
+
* Flags for quality:build-order command
|
|
133
|
+
*/
|
|
134
|
+
declare const buildOrderFlags: {
|
|
135
|
+
readonly package: {
|
|
136
|
+
readonly type: "string";
|
|
137
|
+
readonly description: "Calculate build order for specific package";
|
|
138
|
+
readonly alias: "p";
|
|
139
|
+
};
|
|
140
|
+
readonly layers: {
|
|
141
|
+
readonly type: "boolean";
|
|
142
|
+
readonly description: "Show build layers (parallel groups)";
|
|
143
|
+
readonly default: false;
|
|
144
|
+
};
|
|
145
|
+
readonly script: {
|
|
146
|
+
readonly type: "boolean";
|
|
147
|
+
readonly description: "Output as shell script";
|
|
148
|
+
readonly default: false;
|
|
149
|
+
};
|
|
150
|
+
readonly json: {
|
|
151
|
+
readonly type: "boolean";
|
|
152
|
+
readonly description: "Output JSON format";
|
|
153
|
+
readonly default: false;
|
|
154
|
+
};
|
|
155
|
+
};
|
|
156
|
+
type BuildOrderFlags = typeof buildOrderFlags;
|
|
157
|
+
/**
|
|
158
|
+
* Flags for quality:cycles command
|
|
159
|
+
*/
|
|
160
|
+
declare const cyclesFlags: {
|
|
161
|
+
readonly json: {
|
|
162
|
+
readonly type: "boolean";
|
|
163
|
+
readonly description: "Output JSON format";
|
|
164
|
+
readonly default: false;
|
|
165
|
+
};
|
|
166
|
+
};
|
|
167
|
+
type CyclesFlags = typeof cyclesFlags;
|
|
168
|
+
/**
|
|
169
|
+
* Flags for quality:visualize command
|
|
170
|
+
*/
|
|
171
|
+
declare const visualizeFlags: {
|
|
172
|
+
readonly package: {
|
|
173
|
+
readonly type: "string";
|
|
174
|
+
readonly description: "Focus on specific package";
|
|
175
|
+
readonly alias: "p";
|
|
176
|
+
};
|
|
177
|
+
readonly tree: {
|
|
178
|
+
readonly type: "boolean";
|
|
179
|
+
readonly description: "Show dependency tree";
|
|
180
|
+
readonly default: false;
|
|
181
|
+
};
|
|
182
|
+
readonly dot: {
|
|
183
|
+
readonly type: "boolean";
|
|
184
|
+
readonly description: "Output DOT format for graphviz";
|
|
185
|
+
readonly default: false;
|
|
186
|
+
};
|
|
187
|
+
readonly stats: {
|
|
188
|
+
readonly type: "boolean";
|
|
189
|
+
readonly description: "Show graph statistics";
|
|
190
|
+
readonly default: false;
|
|
191
|
+
};
|
|
192
|
+
readonly reverse: {
|
|
193
|
+
readonly type: "boolean";
|
|
194
|
+
readonly description: "Show reverse dependencies (who depends on this)";
|
|
195
|
+
readonly default: false;
|
|
196
|
+
};
|
|
197
|
+
readonly impact: {
|
|
198
|
+
readonly type: "boolean";
|
|
199
|
+
readonly description: "Show impact analysis (what will be affected)";
|
|
200
|
+
readonly default: false;
|
|
201
|
+
};
|
|
202
|
+
readonly json: {
|
|
203
|
+
readonly type: "boolean";
|
|
204
|
+
readonly description: "Output JSON format";
|
|
205
|
+
readonly default: false;
|
|
206
|
+
};
|
|
207
|
+
};
|
|
208
|
+
type VisualizeFlags = typeof visualizeFlags;
|
|
209
|
+
/**
|
|
210
|
+
* Flags for quality:check-builds command
|
|
211
|
+
*/
|
|
212
|
+
declare const checkBuildsFlags: {
|
|
213
|
+
readonly package: {
|
|
214
|
+
readonly type: "string";
|
|
215
|
+
readonly description: "Check builds for specific package";
|
|
216
|
+
readonly alias: "p";
|
|
217
|
+
};
|
|
218
|
+
readonly timeout: {
|
|
219
|
+
readonly type: "number";
|
|
220
|
+
readonly description: "Timeout per package in milliseconds";
|
|
221
|
+
readonly default: 30000;
|
|
222
|
+
};
|
|
223
|
+
readonly json: {
|
|
224
|
+
readonly type: "boolean";
|
|
225
|
+
readonly description: "Output JSON format";
|
|
226
|
+
readonly default: false;
|
|
227
|
+
};
|
|
228
|
+
readonly refresh: {
|
|
229
|
+
readonly type: "boolean";
|
|
230
|
+
readonly description: "Bypass cache and check fresh";
|
|
231
|
+
readonly default: false;
|
|
232
|
+
};
|
|
233
|
+
};
|
|
234
|
+
type CheckBuildsFlags = typeof checkBuildsFlags;
|
|
235
|
+
/**
|
|
236
|
+
* Flags for quality:check-types command
|
|
237
|
+
*/
|
|
238
|
+
declare const checkTypesFlags: {
|
|
239
|
+
readonly package: {
|
|
240
|
+
readonly type: "string";
|
|
241
|
+
readonly description: "Analyze types for specific package";
|
|
242
|
+
readonly alias: "p";
|
|
243
|
+
};
|
|
244
|
+
readonly 'errors-only': {
|
|
245
|
+
readonly type: "boolean";
|
|
246
|
+
readonly description: "Show only packages with errors";
|
|
247
|
+
readonly default: false;
|
|
248
|
+
};
|
|
249
|
+
readonly json: {
|
|
250
|
+
readonly type: "boolean";
|
|
251
|
+
readonly description: "Output JSON format";
|
|
252
|
+
readonly default: false;
|
|
253
|
+
};
|
|
254
|
+
readonly refresh: {
|
|
255
|
+
readonly type: "boolean";
|
|
256
|
+
readonly description: "Bypass cache and analyze fresh";
|
|
257
|
+
readonly default: false;
|
|
258
|
+
};
|
|
259
|
+
};
|
|
260
|
+
type CheckTypesFlags = typeof checkTypesFlags;
|
|
261
|
+
/**
|
|
262
|
+
* Flags for quality:check-tests command
|
|
263
|
+
*/
|
|
264
|
+
declare const checkTestsFlags: {
|
|
265
|
+
readonly package: {
|
|
266
|
+
readonly type: "string";
|
|
267
|
+
readonly description: "Run tests for specific package";
|
|
268
|
+
readonly alias: "p";
|
|
269
|
+
};
|
|
270
|
+
readonly timeout: {
|
|
271
|
+
readonly type: "number";
|
|
272
|
+
readonly description: "Timeout per package in milliseconds";
|
|
273
|
+
readonly default: 60000;
|
|
274
|
+
};
|
|
275
|
+
readonly 'with-coverage': {
|
|
276
|
+
readonly type: "boolean";
|
|
277
|
+
readonly description: "Collect coverage statistics";
|
|
278
|
+
readonly default: false;
|
|
279
|
+
};
|
|
280
|
+
readonly 'coverage-only': {
|
|
281
|
+
readonly type: "boolean";
|
|
282
|
+
readonly description: "Only show existing coverage (skip test execution)";
|
|
283
|
+
readonly default: false;
|
|
284
|
+
};
|
|
285
|
+
readonly json: {
|
|
286
|
+
readonly type: "boolean";
|
|
287
|
+
readonly description: "Output JSON format";
|
|
288
|
+
readonly default: false;
|
|
289
|
+
};
|
|
290
|
+
readonly refresh: {
|
|
291
|
+
readonly type: "boolean";
|
|
292
|
+
readonly description: "Bypass cache and run fresh";
|
|
293
|
+
readonly default: false;
|
|
294
|
+
};
|
|
295
|
+
};
|
|
296
|
+
type CheckTestsFlags = typeof checkTestsFlags;
|
|
297
|
+
/**
|
|
298
|
+
* Flags for quality:dead-code command
|
|
299
|
+
*/
|
|
300
|
+
declare const deadCodeFlags: {
|
|
301
|
+
readonly package: {
|
|
302
|
+
readonly type: "string";
|
|
303
|
+
readonly description: "Scan specific package only";
|
|
304
|
+
readonly alias: "p";
|
|
305
|
+
};
|
|
306
|
+
readonly json: {
|
|
307
|
+
readonly type: "boolean";
|
|
308
|
+
readonly description: "Output JSON format";
|
|
309
|
+
readonly default: false;
|
|
310
|
+
};
|
|
311
|
+
readonly verbose: {
|
|
312
|
+
readonly type: "boolean";
|
|
313
|
+
readonly description: "Show entry points and alive reasons";
|
|
314
|
+
readonly default: false;
|
|
315
|
+
readonly alias: "v";
|
|
316
|
+
};
|
|
317
|
+
readonly 'auto-remove': {
|
|
318
|
+
readonly type: "boolean";
|
|
319
|
+
readonly description: "Remove dead files (creates backup first)";
|
|
320
|
+
readonly default: false;
|
|
321
|
+
};
|
|
322
|
+
readonly 'dry-run': {
|
|
323
|
+
readonly type: "boolean";
|
|
324
|
+
readonly description: "Show what would be removed without actually deleting";
|
|
325
|
+
readonly default: false;
|
|
326
|
+
};
|
|
327
|
+
readonly restore: {
|
|
328
|
+
readonly type: "string";
|
|
329
|
+
readonly description: "Restore files from backup ID";
|
|
330
|
+
};
|
|
331
|
+
readonly 'list-backups': {
|
|
332
|
+
readonly type: "boolean";
|
|
333
|
+
readonly description: "List available backups";
|
|
334
|
+
readonly default: false;
|
|
335
|
+
};
|
|
336
|
+
readonly refresh: {
|
|
337
|
+
readonly type: "boolean";
|
|
338
|
+
readonly description: "Bypass cache and rescan";
|
|
339
|
+
readonly default: false;
|
|
340
|
+
};
|
|
341
|
+
};
|
|
342
|
+
type DeadCodeFlags = typeof deadCodeFlags;
|
|
343
|
+
|
|
344
|
+
export { type BuildOrderFlags, type CheckBuildsFlags, type CheckTestsFlags, type CheckTypesFlags, type CyclesFlags, type DeadCodeFlags, type FixDepsFlags, type HealthFlags, type RunFlags, type StatsFlags, type VisualizeFlags, buildOrderFlags, checkBuildsFlags, checkTestsFlags, checkTypesFlags, cyclesFlags, deadCodeFlags, fixDepsFlags, healthFlags, runFlags, statsFlags, visualizeFlags };
|
|
@@ -0,0 +1,298 @@
|
|
|
1
|
+
// src/cli/commands/flags.ts
|
|
2
|
+
var statsFlags = {
|
|
3
|
+
json: {
|
|
4
|
+
type: "boolean",
|
|
5
|
+
description: "Output JSON format",
|
|
6
|
+
default: false
|
|
7
|
+
},
|
|
8
|
+
md: {
|
|
9
|
+
type: "boolean",
|
|
10
|
+
description: "Output Markdown table",
|
|
11
|
+
default: false
|
|
12
|
+
},
|
|
13
|
+
health: {
|
|
14
|
+
type: "boolean",
|
|
15
|
+
description: "Show health score",
|
|
16
|
+
default: false
|
|
17
|
+
},
|
|
18
|
+
refresh: {
|
|
19
|
+
type: "boolean",
|
|
20
|
+
description: "Bypass cache and recalculate",
|
|
21
|
+
default: false
|
|
22
|
+
}
|
|
23
|
+
};
|
|
24
|
+
var healthFlags = {
|
|
25
|
+
json: {
|
|
26
|
+
type: "boolean",
|
|
27
|
+
description: "Output JSON format",
|
|
28
|
+
default: false
|
|
29
|
+
},
|
|
30
|
+
package: {
|
|
31
|
+
type: "string",
|
|
32
|
+
description: "Check health for specific package",
|
|
33
|
+
alias: "p"
|
|
34
|
+
},
|
|
35
|
+
detailed: {
|
|
36
|
+
type: "boolean",
|
|
37
|
+
description: "Show detailed breakdown",
|
|
38
|
+
default: false,
|
|
39
|
+
alias: "d"
|
|
40
|
+
}
|
|
41
|
+
};
|
|
42
|
+
var fixDepsFlags = {
|
|
43
|
+
"dry-run": {
|
|
44
|
+
type: "boolean",
|
|
45
|
+
description: "Preview changes without applying them",
|
|
46
|
+
default: false
|
|
47
|
+
},
|
|
48
|
+
"remove-unused": {
|
|
49
|
+
type: "boolean",
|
|
50
|
+
description: "Remove unused dependencies",
|
|
51
|
+
default: false
|
|
52
|
+
},
|
|
53
|
+
"add-missing": {
|
|
54
|
+
type: "boolean",
|
|
55
|
+
description: "Add missing workspace dependencies",
|
|
56
|
+
default: false
|
|
57
|
+
},
|
|
58
|
+
"align-versions": {
|
|
59
|
+
type: "boolean",
|
|
60
|
+
description: "Align duplicate dependency versions",
|
|
61
|
+
default: false
|
|
62
|
+
},
|
|
63
|
+
all: {
|
|
64
|
+
type: "boolean",
|
|
65
|
+
description: "Apply all fixes (remove-unused + add-missing + align-versions)",
|
|
66
|
+
default: false
|
|
67
|
+
},
|
|
68
|
+
stats: {
|
|
69
|
+
type: "boolean",
|
|
70
|
+
description: "Show dependency statistics",
|
|
71
|
+
default: false
|
|
72
|
+
},
|
|
73
|
+
json: {
|
|
74
|
+
type: "boolean",
|
|
75
|
+
description: "Output JSON format",
|
|
76
|
+
default: false
|
|
77
|
+
}
|
|
78
|
+
};
|
|
79
|
+
var runFlags = {
|
|
80
|
+
script: {
|
|
81
|
+
type: "string",
|
|
82
|
+
description: "Script to run (build, test, type-check, lint)",
|
|
83
|
+
required: true
|
|
84
|
+
},
|
|
85
|
+
"continue-on-error": {
|
|
86
|
+
type: "boolean",
|
|
87
|
+
description: "Continue even if packages fail",
|
|
88
|
+
default: true
|
|
89
|
+
},
|
|
90
|
+
parallel: {
|
|
91
|
+
type: "boolean",
|
|
92
|
+
description: "Run in parallel (respects dependencies)",
|
|
93
|
+
default: false
|
|
94
|
+
},
|
|
95
|
+
filter: {
|
|
96
|
+
type: "string",
|
|
97
|
+
description: "Filter packages by pattern (@kb-labs/*)"
|
|
98
|
+
},
|
|
99
|
+
json: {
|
|
100
|
+
type: "boolean",
|
|
101
|
+
description: "Output JSON format",
|
|
102
|
+
default: false
|
|
103
|
+
},
|
|
104
|
+
verbose: {
|
|
105
|
+
type: "boolean",
|
|
106
|
+
description: "Show full output for each package",
|
|
107
|
+
default: false,
|
|
108
|
+
alias: "v"
|
|
109
|
+
}
|
|
110
|
+
};
|
|
111
|
+
var buildOrderFlags = {
|
|
112
|
+
package: {
|
|
113
|
+
type: "string",
|
|
114
|
+
description: "Calculate build order for specific package",
|
|
115
|
+
alias: "p"
|
|
116
|
+
},
|
|
117
|
+
layers: {
|
|
118
|
+
type: "boolean",
|
|
119
|
+
description: "Show build layers (parallel groups)",
|
|
120
|
+
default: false
|
|
121
|
+
},
|
|
122
|
+
script: {
|
|
123
|
+
type: "boolean",
|
|
124
|
+
description: "Output as shell script",
|
|
125
|
+
default: false
|
|
126
|
+
},
|
|
127
|
+
json: {
|
|
128
|
+
type: "boolean",
|
|
129
|
+
description: "Output JSON format",
|
|
130
|
+
default: false
|
|
131
|
+
}
|
|
132
|
+
};
|
|
133
|
+
var cyclesFlags = {
|
|
134
|
+
json: {
|
|
135
|
+
type: "boolean",
|
|
136
|
+
description: "Output JSON format",
|
|
137
|
+
default: false
|
|
138
|
+
}
|
|
139
|
+
};
|
|
140
|
+
var visualizeFlags = {
|
|
141
|
+
package: {
|
|
142
|
+
type: "string",
|
|
143
|
+
description: "Focus on specific package",
|
|
144
|
+
alias: "p"
|
|
145
|
+
},
|
|
146
|
+
tree: {
|
|
147
|
+
type: "boolean",
|
|
148
|
+
description: "Show dependency tree",
|
|
149
|
+
default: false
|
|
150
|
+
},
|
|
151
|
+
dot: {
|
|
152
|
+
type: "boolean",
|
|
153
|
+
description: "Output DOT format for graphviz",
|
|
154
|
+
default: false
|
|
155
|
+
},
|
|
156
|
+
stats: {
|
|
157
|
+
type: "boolean",
|
|
158
|
+
description: "Show graph statistics",
|
|
159
|
+
default: false
|
|
160
|
+
},
|
|
161
|
+
reverse: {
|
|
162
|
+
type: "boolean",
|
|
163
|
+
description: "Show reverse dependencies (who depends on this)",
|
|
164
|
+
default: false
|
|
165
|
+
},
|
|
166
|
+
impact: {
|
|
167
|
+
type: "boolean",
|
|
168
|
+
description: "Show impact analysis (what will be affected)",
|
|
169
|
+
default: false
|
|
170
|
+
},
|
|
171
|
+
json: {
|
|
172
|
+
type: "boolean",
|
|
173
|
+
description: "Output JSON format",
|
|
174
|
+
default: false
|
|
175
|
+
}
|
|
176
|
+
};
|
|
177
|
+
var checkBuildsFlags = {
|
|
178
|
+
package: {
|
|
179
|
+
type: "string",
|
|
180
|
+
description: "Check builds for specific package",
|
|
181
|
+
alias: "p"
|
|
182
|
+
},
|
|
183
|
+
timeout: {
|
|
184
|
+
type: "number",
|
|
185
|
+
description: "Timeout per package in milliseconds",
|
|
186
|
+
default: 3e4
|
|
187
|
+
},
|
|
188
|
+
json: {
|
|
189
|
+
type: "boolean",
|
|
190
|
+
description: "Output JSON format",
|
|
191
|
+
default: false
|
|
192
|
+
},
|
|
193
|
+
refresh: {
|
|
194
|
+
type: "boolean",
|
|
195
|
+
description: "Bypass cache and check fresh",
|
|
196
|
+
default: false
|
|
197
|
+
}
|
|
198
|
+
};
|
|
199
|
+
var checkTypesFlags = {
|
|
200
|
+
package: {
|
|
201
|
+
type: "string",
|
|
202
|
+
description: "Analyze types for specific package",
|
|
203
|
+
alias: "p"
|
|
204
|
+
},
|
|
205
|
+
"errors-only": {
|
|
206
|
+
type: "boolean",
|
|
207
|
+
description: "Show only packages with errors",
|
|
208
|
+
default: false
|
|
209
|
+
},
|
|
210
|
+
json: {
|
|
211
|
+
type: "boolean",
|
|
212
|
+
description: "Output JSON format",
|
|
213
|
+
default: false
|
|
214
|
+
},
|
|
215
|
+
refresh: {
|
|
216
|
+
type: "boolean",
|
|
217
|
+
description: "Bypass cache and analyze fresh",
|
|
218
|
+
default: false
|
|
219
|
+
}
|
|
220
|
+
};
|
|
221
|
+
var checkTestsFlags = {
|
|
222
|
+
package: {
|
|
223
|
+
type: "string",
|
|
224
|
+
description: "Run tests for specific package",
|
|
225
|
+
alias: "p"
|
|
226
|
+
},
|
|
227
|
+
timeout: {
|
|
228
|
+
type: "number",
|
|
229
|
+
description: "Timeout per package in milliseconds",
|
|
230
|
+
default: 6e4
|
|
231
|
+
},
|
|
232
|
+
"with-coverage": {
|
|
233
|
+
type: "boolean",
|
|
234
|
+
description: "Collect coverage statistics",
|
|
235
|
+
default: false
|
|
236
|
+
},
|
|
237
|
+
"coverage-only": {
|
|
238
|
+
type: "boolean",
|
|
239
|
+
description: "Only show existing coverage (skip test execution)",
|
|
240
|
+
default: false
|
|
241
|
+
},
|
|
242
|
+
json: {
|
|
243
|
+
type: "boolean",
|
|
244
|
+
description: "Output JSON format",
|
|
245
|
+
default: false
|
|
246
|
+
},
|
|
247
|
+
refresh: {
|
|
248
|
+
type: "boolean",
|
|
249
|
+
description: "Bypass cache and run fresh",
|
|
250
|
+
default: false
|
|
251
|
+
}
|
|
252
|
+
};
|
|
253
|
+
var deadCodeFlags = {
|
|
254
|
+
package: {
|
|
255
|
+
type: "string",
|
|
256
|
+
description: "Scan specific package only",
|
|
257
|
+
alias: "p"
|
|
258
|
+
},
|
|
259
|
+
json: {
|
|
260
|
+
type: "boolean",
|
|
261
|
+
description: "Output JSON format",
|
|
262
|
+
default: false
|
|
263
|
+
},
|
|
264
|
+
verbose: {
|
|
265
|
+
type: "boolean",
|
|
266
|
+
description: "Show entry points and alive reasons",
|
|
267
|
+
default: false,
|
|
268
|
+
alias: "v"
|
|
269
|
+
},
|
|
270
|
+
"auto-remove": {
|
|
271
|
+
type: "boolean",
|
|
272
|
+
description: "Remove dead files (creates backup first)",
|
|
273
|
+
default: false
|
|
274
|
+
},
|
|
275
|
+
"dry-run": {
|
|
276
|
+
type: "boolean",
|
|
277
|
+
description: "Show what would be removed without actually deleting",
|
|
278
|
+
default: false
|
|
279
|
+
},
|
|
280
|
+
restore: {
|
|
281
|
+
type: "string",
|
|
282
|
+
description: "Restore files from backup ID"
|
|
283
|
+
},
|
|
284
|
+
"list-backups": {
|
|
285
|
+
type: "boolean",
|
|
286
|
+
description: "List available backups",
|
|
287
|
+
default: false
|
|
288
|
+
},
|
|
289
|
+
refresh: {
|
|
290
|
+
type: "boolean",
|
|
291
|
+
description: "Bypass cache and rescan",
|
|
292
|
+
default: false
|
|
293
|
+
}
|
|
294
|
+
};
|
|
295
|
+
|
|
296
|
+
export { buildOrderFlags, checkBuildsFlags, checkTestsFlags, checkTypesFlags, cyclesFlags, deadCodeFlags, fixDepsFlags, healthFlags, runFlags, statsFlags, visualizeFlags };
|
|
297
|
+
//# sourceMappingURL=flags.js.map
|
|
298
|
+
//# sourceMappingURL=flags.js.map
|
|
@@ -0,0 +1 @@
|
|
|
1
|
+
{"version":3,"sources":["../../../src/cli/commands/flags.ts"],"names":[],"mappings":";AASO,IAAM,UAAA,GAAa;AAAA,EACxB,IAAA,EAAM;AAAA,IACJ,IAAA,EAAM,SAAA;AAAA,IACN,WAAA,EAAa,oBAAA;AAAA,IACb,OAAA,EAAS;AAAA,GACX;AAAA,EACA,EAAA,EAAI;AAAA,IACF,IAAA,EAAM,SAAA;AAAA,IACN,WAAA,EAAa,uBAAA;AAAA,IACb,OAAA,EAAS;AAAA,GACX;AAAA,EACA,MAAA,EAAQ;AAAA,IACN,IAAA,EAAM,SAAA;AAAA,IACN,WAAA,EAAa,mBAAA;AAAA,IACb,OAAA,EAAS;AAA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A,EAAM,SAAA;AAAA,IACN,WAAA,EAAa,yBAAA;AAAA,IACb,OAAA,EAAS;AAAA;AAEb","file":"flags.js","sourcesContent":["/**\n * Shared command flags definitions\n *\n * DRY pattern: Define flags once, use in both manifest and command handlers.\n */\n\n/**\n * Flags for quality:stats command\n */\nexport const statsFlags = {\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n md: {\n type: 'boolean',\n description: 'Output Markdown table',\n default: false,\n },\n health: {\n type: 'boolean',\n description: 'Show health score',\n default: false,\n },\n refresh: {\n type: 'boolean',\n description: 'Bypass cache and recalculate',\n default: false,\n },\n} as const;\n\nexport type StatsFlags = typeof statsFlags;\n\n/**\n * Flags for quality:health command\n */\nexport const healthFlags = {\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n package: {\n type: 'string',\n description: 'Check health for specific package',\n alias: 'p',\n },\n detailed: {\n type: 'boolean',\n description: 'Show detailed breakdown',\n default: false,\n alias: 'd',\n },\n} as const;\n\nexport type HealthFlags = typeof healthFlags;\n\n/**\n * Flags for quality:fix-deps command\n */\nexport const fixDepsFlags = {\n 'dry-run': {\n type: 'boolean',\n description: 'Preview changes without applying them',\n default: false,\n },\n 'remove-unused': {\n type: 'boolean',\n description: 'Remove unused dependencies',\n default: false,\n },\n 'add-missing': {\n type: 'boolean',\n description: 'Add missing workspace dependencies',\n default: false,\n },\n 'align-versions': {\n type: 'boolean',\n description: 'Align duplicate dependency versions',\n default: false,\n },\n all: {\n type: 'boolean',\n description: 'Apply all fixes (remove-unused + add-missing + align-versions)',\n default: false,\n },\n stats: {\n type: 'boolean',\n description: 'Show dependency statistics',\n default: false,\n },\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n} as const;\n\nexport type FixDepsFlags = typeof fixDepsFlags;\n\n/**\n * Flags for quality:run command\n */\nexport const runFlags = {\n script: {\n type: 'string',\n description: 'Script to run (build, test, type-check, lint)',\n required: true,\n },\n 'continue-on-error': {\n type: 'boolean',\n description: 'Continue even if packages fail',\n default: true,\n },\n parallel: {\n type: 'boolean',\n description: 'Run in parallel (respects dependencies)',\n default: false,\n },\n filter: {\n type: 'string',\n description: 'Filter packages by pattern (@kb-labs/*)',\n },\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n verbose: {\n type: 'boolean',\n description: 'Show full output for each package',\n default: false,\n alias: 'v',\n },\n} as const;\n\nexport type RunFlags = typeof runFlags;\n\n/**\n * Flags for quality:build-order command\n */\nexport const buildOrderFlags = {\n package: {\n type: 'string',\n description: 'Calculate build order for specific package',\n alias: 'p',\n },\n layers: {\n type: 'boolean',\n description: 'Show build layers (parallel groups)',\n default: false,\n },\n script: {\n type: 'boolean',\n description: 'Output as shell script',\n default: false,\n },\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n} as const;\n\nexport type BuildOrderFlags = typeof buildOrderFlags;\n\n/**\n * Flags for quality:cycles command\n */\nexport const cyclesFlags = {\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n} as const;\n\nexport type CyclesFlags = typeof cyclesFlags;\n\n/**\n * Flags for quality:visualize command\n */\nexport const visualizeFlags = {\n package: {\n type: 'string',\n description: 'Focus on specific package',\n alias: 'p',\n },\n tree: {\n type: 'boolean',\n description: 'Show dependency tree',\n default: false,\n },\n dot: {\n type: 'boolean',\n description: 'Output DOT format for graphviz',\n default: false,\n },\n stats: {\n type: 'boolean',\n description: 'Show graph statistics',\n default: false,\n },\n reverse: {\n type: 'boolean',\n description: 'Show reverse dependencies (who depends on this)',\n default: false,\n },\n impact: {\n type: 'boolean',\n description: 'Show impact analysis (what will be affected)',\n default: false,\n },\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n} as const;\n\nexport type VisualizeFlags = typeof visualizeFlags;\n\n/**\n * Flags for quality:check-builds command\n */\nexport const checkBuildsFlags = {\n package: {\n type: 'string',\n description: 'Check builds for specific package',\n alias: 'p',\n },\n timeout: {\n type: 'number',\n description: 'Timeout per package in milliseconds',\n default: 30000,\n },\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n refresh: {\n type: 'boolean',\n description: 'Bypass cache and check fresh',\n default: false,\n },\n} as const;\n\nexport type CheckBuildsFlags = typeof checkBuildsFlags;\n\n/**\n * Flags for quality:check-types command\n */\nexport const checkTypesFlags = {\n package: {\n type: 'string',\n description: 'Analyze types for specific package',\n alias: 'p',\n },\n 'errors-only': {\n type: 'boolean',\n description: 'Show only packages with errors',\n default: false,\n },\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n refresh: {\n type: 'boolean',\n description: 'Bypass cache and analyze fresh',\n default: false,\n },\n} as const;\n\nexport type CheckTypesFlags = typeof checkTypesFlags;\n\n/**\n * Flags for quality:check-tests command\n */\nexport const checkTestsFlags = {\n package: {\n type: 'string',\n description: 'Run tests for specific package',\n alias: 'p',\n },\n timeout: {\n type: 'number',\n description: 'Timeout per package in milliseconds',\n default: 60000,\n },\n 'with-coverage': {\n type: 'boolean',\n description: 'Collect coverage statistics',\n default: false,\n },\n 'coverage-only': {\n type: 'boolean',\n description: 'Only show existing coverage (skip test execution)',\n default: false,\n },\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n refresh: {\n type: 'boolean',\n description: 'Bypass cache and run fresh',\n default: false,\n },\n} as const;\n\nexport type CheckTestsFlags = typeof checkTestsFlags;\n\n/**\n * Flags for quality:dead-code command\n */\nexport const deadCodeFlags = {\n package: {\n type: 'string',\n description: 'Scan specific package only',\n alias: 'p',\n },\n json: {\n type: 'boolean',\n description: 'Output JSON format',\n default: false,\n },\n verbose: {\n type: 'boolean',\n description: 'Show entry points and alive reasons',\n default: false,\n alias: 'v',\n },\n 'auto-remove': {\n type: 'boolean',\n description: 'Remove dead files (creates backup first)',\n default: false,\n },\n 'dry-run': {\n type: 'boolean',\n description: 'Show what would be removed without actually deleting',\n default: false,\n },\n restore: {\n type: 'string',\n description: 'Restore files from backup ID',\n },\n 'list-backups': {\n type: 'boolean',\n description: 'List available backups',\n default: false,\n },\n refresh: {\n type: 'boolean',\n description: 'Bypass cache and rescan',\n default: false,\n },\n} as const;\n\nexport type DeadCodeFlags = typeof deadCodeFlags;\n"]}
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
import * as _kb_labs_shared_command_kit from '@kb-labs/shared-command-kit';
|
|
2
|
+
import { HealthScore } from '@kb-labs/quality-contracts';
|
|
3
|
+
import { HealthFlags } from './flags.js';
|
|
4
|
+
|
|
5
|
+
type HealthInput = HealthFlags & {
|
|
6
|
+
argv?: string[];
|
|
7
|
+
};
|
|
8
|
+
declare const _default: _kb_labs_shared_command_kit.CommandHandlerV3<unknown, HealthInput, HealthScore>;
|
|
9
|
+
|
|
10
|
+
export { _default as default };
|