@tjalve/cube-cli 0.1.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.
Files changed (71) hide show
  1. package/LICENSE +21 -0
  2. package/README.md +39 -0
  3. package/dist/errors/index.d.ts +28 -0
  4. package/dist/errors/index.d.ts.map +1 -0
  5. package/dist/errors/index.js +58 -0
  6. package/dist/errors/index.js.map +1 -0
  7. package/dist/fixtures/cli.d.ts +4 -0
  8. package/dist/fixtures/cli.d.ts.map +1 -0
  9. package/dist/fixtures/cli.js +195 -0
  10. package/dist/fixtures/cli.js.map +1 -0
  11. package/dist/fixtures/metadata.d.ts +347 -0
  12. package/dist/fixtures/metadata.d.ts.map +1 -0
  13. package/dist/fixtures/metadata.js +372 -0
  14. package/dist/fixtures/metadata.js.map +1 -0
  15. package/dist/help/index.d.ts +24 -0
  16. package/dist/help/index.d.ts.map +1 -0
  17. package/dist/help/index.js +254 -0
  18. package/dist/help/index.js.map +1 -0
  19. package/dist/index.d.ts +20 -0
  20. package/dist/index.d.ts.map +1 -0
  21. package/dist/index.js +21 -0
  22. package/dist/index.js.map +1 -0
  23. package/dist/metadata/define.d.ts +11 -0
  24. package/dist/metadata/define.d.ts.map +1 -0
  25. package/dist/metadata/define.js +125 -0
  26. package/dist/metadata/define.js.map +1 -0
  27. package/dist/metadata/index.d.ts +3 -0
  28. package/dist/metadata/index.d.ts.map +1 -0
  29. package/dist/metadata/index.js +2 -0
  30. package/dist/metadata/index.js.map +1 -0
  31. package/dist/metadata/types.d.ts +109 -0
  32. package/dist/metadata/types.d.ts.map +1 -0
  33. package/dist/metadata/types.js +2 -0
  34. package/dist/metadata/types.js.map +1 -0
  35. package/dist/mutation/index.d.ts +55 -0
  36. package/dist/mutation/index.d.ts.map +1 -0
  37. package/dist/mutation/index.js +162 -0
  38. package/dist/mutation/index.js.map +1 -0
  39. package/dist/output/index.d.ts +32 -0
  40. package/dist/output/index.d.ts.map +1 -0
  41. package/dist/output/index.js +94 -0
  42. package/dist/output/index.js.map +1 -0
  43. package/dist/prompts/index.d.ts +37 -0
  44. package/dist/prompts/index.d.ts.map +1 -0
  45. package/dist/prompts/index.js +78 -0
  46. package/dist/prompts/index.js.map +1 -0
  47. package/dist/redaction/index.d.ts +10 -0
  48. package/dist/redaction/index.d.ts.map +1 -0
  49. package/dist/redaction/index.js +83 -0
  50. package/dist/redaction/index.js.map +1 -0
  51. package/dist/registry/index.d.ts +25 -0
  52. package/dist/registry/index.d.ts.map +1 -0
  53. package/dist/registry/index.js +286 -0
  54. package/dist/registry/index.js.map +1 -0
  55. package/dist/runtime/index.d.ts +69 -0
  56. package/dist/runtime/index.d.ts.map +1 -0
  57. package/dist/runtime/index.js +581 -0
  58. package/dist/runtime/index.js.map +1 -0
  59. package/dist/schema/index.d.ts +122 -0
  60. package/dist/schema/index.d.ts.map +1 -0
  61. package/dist/schema/index.js +208 -0
  62. package/dist/schema/index.js.map +1 -0
  63. package/dist/terminal/index.d.ts +31 -0
  64. package/dist/terminal/index.d.ts.map +1 -0
  65. package/dist/terminal/index.js +118 -0
  66. package/dist/terminal/index.js.map +1 -0
  67. package/dist/testing/index.d.ts +85 -0
  68. package/dist/testing/index.d.ts.map +1 -0
  69. package/dist/testing/index.js +293 -0
  70. package/dist/testing/index.js.map +1 -0
  71. package/package.json +107 -0
@@ -0,0 +1,347 @@
1
+ export declare const cacheTopic: Readonly<{
2
+ readonly kind: "topic";
3
+ readonly name: "cache";
4
+ readonly description: "Commands for inspecting and maintaining a local cache.";
5
+ readonly extensions: Readonly<{
6
+ readonly fixture: true;
7
+ readonly owner: "toolkit-tests";
8
+ readonly nested: {
9
+ readonly beta: 2;
10
+ readonly alpha: 1;
11
+ };
12
+ }>;
13
+ }>;
14
+ export declare const cacheInspectCommand: Readonly<{
15
+ readonly kind: "command";
16
+ readonly name: "cache inspect";
17
+ readonly description: "Inspect cache entries without changing local state.";
18
+ readonly arguments: readonly [Readonly<{
19
+ readonly name: "key";
20
+ readonly description: "Cache key to inspect.";
21
+ readonly required: false;
22
+ readonly extensions: Readonly<{
23
+ readonly fixtureRole: "lookup-key";
24
+ }>;
25
+ }>];
26
+ readonly flags: readonly [Readonly<{
27
+ readonly name: "json";
28
+ readonly description: "Render machine-readable JSON output.";
29
+ readonly type: "boolean";
30
+ }>, Readonly<{
31
+ readonly name: "output";
32
+ readonly description: "Select the output format.";
33
+ readonly type: "option";
34
+ readonly options: readonly ["human", "json"];
35
+ readonly defaultValue: "human";
36
+ readonly extensions: Readonly<{
37
+ readonly fixtureRole: "format-selector";
38
+ }>;
39
+ }>];
40
+ readonly examples: readonly [Readonly<{
41
+ readonly description: "Inspect all cache entries.";
42
+ readonly command: "fixture cache inspect";
43
+ }>];
44
+ readonly output: {
45
+ readonly formats: readonly ["human", "json"];
46
+ readonly defaultFormat: "human";
47
+ };
48
+ readonly interactions: {
49
+ readonly json: true;
50
+ readonly noColor: true;
51
+ readonly nonInteractive: true;
52
+ readonly ttyPrompt: false;
53
+ };
54
+ readonly externalServices: readonly [];
55
+ readonly errors: readonly [{
56
+ readonly kind: "cache-read-failed";
57
+ readonly description: "The cache could not be read.";
58
+ readonly exitCode: 2;
59
+ }];
60
+ readonly exitCodes: readonly [{
61
+ readonly code: 0;
62
+ readonly category: "success";
63
+ readonly description: "The command completed successfully.";
64
+ }, {
65
+ readonly code: 2;
66
+ readonly category: "validation";
67
+ readonly description: "The cache key or cache state was invalid.";
68
+ }];
69
+ readonly extensions: Readonly<{
70
+ readonly fixture: true;
71
+ readonly owner: "toolkit-tests";
72
+ readonly nested: {
73
+ readonly beta: 2;
74
+ readonly alpha: 1;
75
+ };
76
+ }>;
77
+ }>;
78
+ export declare const cacheClearCommand: Readonly<{
79
+ readonly kind: "command";
80
+ readonly name: "cache clear";
81
+ readonly description: "Clear cache entries after showing the planned local file changes.";
82
+ readonly aliases: readonly ["cc"];
83
+ readonly flags: readonly [Readonly<{
84
+ readonly name: "dry-run";
85
+ readonly description: "Show cache entries that would be removed without deleting them.";
86
+ readonly type: "boolean";
87
+ }>, Readonly<{
88
+ readonly name: "yes";
89
+ readonly description: "Run without interactive confirmation.";
90
+ readonly type: "boolean";
91
+ }>];
92
+ readonly examples: readonly [Readonly<{
93
+ readonly description: "Preview cache cleanup.";
94
+ readonly command: "fixture cache clear --dry-run";
95
+ }>];
96
+ readonly output: {
97
+ readonly formats: readonly ["human", "json"];
98
+ readonly defaultFormat: "human";
99
+ };
100
+ readonly interactions: {
101
+ readonly json: true;
102
+ readonly dryRun: import("../metadata/types.js").DryRunSupport;
103
+ readonly noColor: true;
104
+ readonly nonInteractive: true;
105
+ readonly ttyPrompt: true;
106
+ };
107
+ readonly mutation: Readonly<{
108
+ readonly categories: readonly ["local-files"];
109
+ readonly extensions: Readonly<{
110
+ readonly fixtureMutation: "cache-cleanup";
111
+ }>;
112
+ }>;
113
+ readonly exitCodes: readonly [{
114
+ readonly code: 0;
115
+ readonly category: "success";
116
+ readonly description: "The command completed successfully.";
117
+ }, {
118
+ readonly code: 5;
119
+ readonly category: "safety";
120
+ readonly description: "The command was blocked by a safety policy.";
121
+ }];
122
+ readonly extensions: Readonly<{
123
+ readonly fixture: true;
124
+ readonly owner: "toolkit-tests";
125
+ readonly nested: {
126
+ readonly beta: 2;
127
+ readonly alpha: 1;
128
+ };
129
+ }>;
130
+ }>;
131
+ export declare const cacheInstallCommand: Readonly<{
132
+ readonly kind: "command";
133
+ readonly name: "cache install";
134
+ readonly description: "Prepare dependency cache entries after showing supply-chain-sensitive checks.";
135
+ readonly flags: readonly [Readonly<{
136
+ readonly name: "dry-run";
137
+ readonly description: "Show dependency cache changes without writing fixture state.";
138
+ readonly type: "boolean";
139
+ }>, Readonly<{
140
+ readonly name: "json";
141
+ readonly description: "Render machine-readable JSON output.";
142
+ readonly type: "boolean";
143
+ }>];
144
+ readonly examples: readonly [Readonly<{
145
+ readonly description: "Preview dependency cache preparation.";
146
+ readonly command: "fixture cache install --dry-run";
147
+ }>];
148
+ readonly output: {
149
+ readonly formats: readonly ["human", "json"];
150
+ readonly defaultFormat: "human";
151
+ };
152
+ readonly interactions: {
153
+ readonly json: true;
154
+ readonly dryRun: import("../metadata/types.js").DryRunSupport;
155
+ readonly noColor: true;
156
+ readonly nonInteractive: true;
157
+ readonly ttyPrompt: false;
158
+ };
159
+ readonly mutation: Readonly<{
160
+ readonly categories: readonly ["dependency", "local-files"];
161
+ readonly extensions: Readonly<{
162
+ readonly fixtureMutation: "dependency-cache";
163
+ }>;
164
+ }>;
165
+ readonly supplyChain: {
166
+ readonly sensitive: true;
167
+ readonly kinds: readonly ["dependency", "package-manager"];
168
+ readonly reason: "Dependency cache preparation depends on package-manager metadata supplied by the consuming package.";
169
+ readonly extensions: Readonly<{
170
+ readonly fixtureSupplyChain: "dependency-cache";
171
+ }>;
172
+ };
173
+ readonly errors: readonly [{
174
+ readonly kind: "supply-chain-blocked";
175
+ readonly description: "The dependency cache operation was blocked for supply-chain review.";
176
+ readonly exitCode: 5;
177
+ }];
178
+ readonly exitCodes: readonly [{
179
+ readonly code: 0;
180
+ readonly category: "success";
181
+ readonly description: "The command completed successfully.";
182
+ }, {
183
+ readonly code: 5;
184
+ readonly category: "safety";
185
+ readonly description: "The command was blocked by supply-chain safety guidance.";
186
+ }];
187
+ readonly extensions: Readonly<{
188
+ readonly fixture: true;
189
+ readonly owner: "toolkit-tests";
190
+ readonly nested: {
191
+ readonly beta: 2;
192
+ readonly alpha: 1;
193
+ };
194
+ }>;
195
+ }>;
196
+ export declare const cacheValidateCommand: Readonly<{
197
+ readonly kind: "command";
198
+ readonly name: "cache validate";
199
+ readonly description: "Validate cache configuration and report actionable failures.";
200
+ readonly flags: readonly [Readonly<{
201
+ readonly name: "json";
202
+ readonly description: "Render machine-readable JSON output.";
203
+ readonly type: "boolean";
204
+ }>];
205
+ readonly examples: readonly [Readonly<{
206
+ readonly description: "Validate cache configuration.";
207
+ readonly command: "fixture cache validate --json";
208
+ }>];
209
+ readonly output: {
210
+ readonly formats: readonly ["human", "json"];
211
+ readonly defaultFormat: "human";
212
+ };
213
+ readonly interactions: {
214
+ readonly json: true;
215
+ readonly noColor: true;
216
+ readonly nonInteractive: true;
217
+ readonly ttyPrompt: false;
218
+ };
219
+ readonly errors: readonly [{
220
+ readonly kind: "cache-config-invalid";
221
+ readonly description: "The cache configuration failed validation.";
222
+ readonly exitCode: 3;
223
+ }];
224
+ readonly exitCodes: readonly [{
225
+ readonly code: 0;
226
+ readonly category: "success";
227
+ readonly description: "The command completed successfully.";
228
+ }, {
229
+ readonly code: 3;
230
+ readonly category: "validation";
231
+ readonly description: "The cache configuration was invalid.";
232
+ }];
233
+ readonly extensions: Readonly<{
234
+ readonly fixture: true;
235
+ readonly owner: "toolkit-tests";
236
+ readonly nested: {
237
+ readonly beta: 2;
238
+ readonly alpha: 1;
239
+ };
240
+ }>;
241
+ }>;
242
+ export declare const cachePromptCommand: Readonly<{
243
+ readonly kind: "command";
244
+ readonly name: "cache prompt";
245
+ readonly description: "Resolve a cache prompt through flags, defaults, or an interactive TTY.";
246
+ readonly flags: readonly [Readonly<{
247
+ readonly name: "value";
248
+ readonly description: "Prompt value supplied by flags or config.";
249
+ readonly type: "string";
250
+ }>, Readonly<{
251
+ readonly name: "defaults";
252
+ readonly description: "Use deterministic defaults without prompting.";
253
+ readonly type: "boolean";
254
+ }>, Readonly<{
255
+ readonly name: "yes";
256
+ readonly description: "Accept the deterministic prompt default.";
257
+ readonly type: "boolean";
258
+ }>, Readonly<{
259
+ readonly name: "json";
260
+ readonly description: "Render machine-readable JSON output.";
261
+ readonly type: "boolean";
262
+ }>];
263
+ readonly examples: readonly [Readonly<{
264
+ readonly description: "Resolve a prompt from flags.";
265
+ readonly command: "fixture cache prompt --value alpha";
266
+ }>];
267
+ readonly output: {
268
+ readonly formats: readonly ["human", "json"];
269
+ readonly defaultFormat: "human";
270
+ };
271
+ readonly interactions: {
272
+ readonly json: true;
273
+ readonly noColor: true;
274
+ readonly nonInteractive: false;
275
+ readonly ttyPrompt: true;
276
+ };
277
+ readonly errors: readonly [{
278
+ readonly kind: "prompt-blocked";
279
+ readonly description: "The prompt was blocked by non-interactive execution.";
280
+ readonly exitCode: 2;
281
+ }, {
282
+ readonly kind: "prompt-cancelled";
283
+ readonly description: "The prompt was cancelled before a value was supplied.";
284
+ readonly exitCode: 2;
285
+ }];
286
+ readonly exitCodes: readonly [{
287
+ readonly code: 0;
288
+ readonly category: "success";
289
+ readonly description: "The command completed successfully.";
290
+ }, {
291
+ readonly code: 2;
292
+ readonly category: "usage";
293
+ readonly description: "The prompt could not run in the current execution mode.";
294
+ }];
295
+ readonly extensions: Readonly<{
296
+ readonly fixture: true;
297
+ readonly owner: "toolkit-tests";
298
+ readonly nested: {
299
+ readonly beta: 2;
300
+ readonly alpha: 1;
301
+ };
302
+ }>;
303
+ }>;
304
+ export declare const cacheExplodeCommand: Readonly<{
305
+ readonly kind: "command";
306
+ readonly name: "cache explode";
307
+ readonly description: "Raise an unexpected fixture failure for runtime error tests.";
308
+ readonly flags: readonly [Readonly<{
309
+ readonly name: "json";
310
+ readonly description: "Render machine-readable JSON output.";
311
+ readonly type: "boolean";
312
+ }>];
313
+ readonly examples: readonly [Readonly<{
314
+ readonly description: "Raise an unexpected fixture failure.";
315
+ readonly command: "fixture cache explode --json";
316
+ }>];
317
+ readonly output: {
318
+ readonly formats: readonly ["human", "json"];
319
+ readonly defaultFormat: "human";
320
+ };
321
+ readonly interactions: {
322
+ readonly json: true;
323
+ readonly noColor: true;
324
+ readonly nonInteractive: true;
325
+ readonly ttyPrompt: false;
326
+ };
327
+ readonly errors: readonly [{
328
+ readonly kind: "unexpected-error";
329
+ readonly description: "The command failed unexpectedly.";
330
+ readonly exitCode: 70;
331
+ }];
332
+ readonly exitCodes: readonly [{
333
+ readonly code: 70;
334
+ readonly category: "unexpected";
335
+ readonly description: "The command failed unexpectedly.";
336
+ }];
337
+ readonly extensions: Readonly<{
338
+ readonly fixture: true;
339
+ readonly owner: "toolkit-tests";
340
+ readonly nested: {
341
+ readonly beta: 2;
342
+ readonly alpha: 1;
343
+ };
344
+ }>;
345
+ }>;
346
+ export declare const fixtureMetadata: Readonly<import("../registry/index.js").CommandRegistry>;
347
+ //# sourceMappingURL=metadata.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"metadata.d.ts","sourceRoot":"","sources":["../../src/fixtures/metadata.ts"],"names":[],"mappings":"AAaA,eAAO,MAAM,UAAU;;;;;;;;;;;;EAKrB,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAoE9B,CAAC;AAEH,eAAO,MAAM,iBAAiB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAqD5B,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmE9B,CAAC;AAEH,eAAO,MAAM,oBAAoB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA+C/B,CAAC;AAEH,eAAO,MAAM,kBAAkB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EAmE7B,CAAC;AAEH,eAAO,MAAM,mBAAmB;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;EA0C9B,CAAC;AAEH,eAAO,MAAM,eAAe,0DAG1B,CAAC"}