@ue-shed/project-custodian 0.2.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.
@@ -0,0 +1,648 @@
1
+ import { Schema } from "effect";
2
+ export declare const CustodianTargetId: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
3
+ export type CustodianTargetId = typeof CustodianTargetId.Type;
4
+ export declare const CustodianProposalId: Schema.brand<Schema.NonEmptyString, "CustodianProposalId">;
5
+ export type CustodianProposalId = typeof CustodianProposalId.Type;
6
+ export declare const CustodianExecutionMode: Schema.Literals<readonly ["trash", "permanent"]>;
7
+ export type CustodianExecutionMode = typeof CustodianExecutionMode.Type;
8
+ export declare const ProjectTargetKey: Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>;
9
+ export type ProjectTargetKey = typeof ProjectTargetKey.Type;
10
+ export declare const EngineTargetKey: Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>;
11
+ export type EngineTargetKey = typeof EngineTargetKey.Type;
12
+ export declare const CustodianPolicy: Schema.Struct<{
13
+ readonly enabled: Schema.Boolean;
14
+ readonly minAgeDays: Schema.Number;
15
+ readonly minFreeGb: Schema.Number;
16
+ readonly keepBinariesForCpp: Schema.Boolean;
17
+ readonly targets: Schema.$Array<Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>>;
18
+ readonly source: Schema.Literals<readonly ["default", "project"]>;
19
+ }>;
20
+ export interface CustodianPolicy extends Schema.Schema.Type<typeof CustodianPolicy> {
21
+ }
22
+ export declare const CustodianFreshness: Schema.Struct<{
23
+ readonly authoredAt: Schema.optionalKey<Schema.String>;
24
+ readonly lastSessionAt: Schema.optionalKey<Schema.String>;
25
+ readonly effectiveAt: Schema.optionalKey<Schema.String>;
26
+ readonly ageDays: Schema.optionalKey<Schema.Number>;
27
+ readonly mtimesLookRewritten: Schema.Boolean;
28
+ }>;
29
+ export interface CustodianFreshness extends Schema.Schema.Type<typeof CustodianFreshness> {
30
+ }
31
+ export declare const CustodianTarget: Schema.Struct<{
32
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
33
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
34
+ readonly path: Schema.NonEmptyString;
35
+ readonly relativePath: Schema.NonEmptyString;
36
+ readonly bytes: Schema.Int;
37
+ readonly description: Schema.NonEmptyString;
38
+ readonly rebuildCost: Schema.NonEmptyString;
39
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
40
+ }>;
41
+ export interface CustodianTarget extends Schema.Schema.Type<typeof CustodianTarget> {
42
+ }
43
+ export declare const CustodianRefusal: Schema.Struct<{
44
+ readonly path: Schema.NonEmptyString;
45
+ readonly relativePath: Schema.NonEmptyString;
46
+ readonly code: Schema.Literals<readonly ["protected_path", "outside_root", "different_volume", "installed_engine", "unreadable"]>;
47
+ readonly reason: Schema.NonEmptyString;
48
+ }>;
49
+ export interface CustodianRefusal extends Schema.Schema.Type<typeof CustodianRefusal> {
50
+ }
51
+ export declare const CustodianDiagnostic: Schema.Struct<{
52
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
53
+ readonly message: Schema.NonEmptyString;
54
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
55
+ }>;
56
+ export interface CustodianDiagnostic extends Schema.Schema.Type<typeof CustodianDiagnostic> {
57
+ }
58
+ export declare const ProjectEligibility: Schema.Union<readonly [Schema.Struct<{
59
+ readonly kind: Schema.Literal<"candidate">;
60
+ }>, Schema.Struct<{
61
+ readonly kind: Schema.Literal<"opted_out">;
62
+ }>, Schema.Struct<{
63
+ readonly kind: Schema.Literal<"recent">;
64
+ readonly eligibleAfterDays: Schema.Number;
65
+ }>, Schema.Struct<{
66
+ readonly kind: Schema.Literal<"unknown_age">;
67
+ }>, Schema.Struct<{
68
+ readonly kind: Schema.Literal<"empty">;
69
+ }>, Schema.Struct<{
70
+ readonly kind: Schema.Literal<"invalid_policy">;
71
+ }>]>;
72
+ export type ProjectEligibility = typeof ProjectEligibility.Type;
73
+ export declare const CustodianProjectReport: Schema.Struct<{
74
+ readonly kind: Schema.Literal<"project">;
75
+ readonly name: Schema.NonEmptyString;
76
+ readonly root: Schema.NonEmptyString;
77
+ readonly descriptor: Schema.NonEmptyString;
78
+ readonly engineAssociation: Schema.NonEmptyString;
79
+ readonly isCpp: Schema.Boolean;
80
+ readonly policy: Schema.Struct<{
81
+ readonly enabled: Schema.Boolean;
82
+ readonly minAgeDays: Schema.Number;
83
+ readonly minFreeGb: Schema.Number;
84
+ readonly keepBinariesForCpp: Schema.Boolean;
85
+ readonly targets: Schema.$Array<Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>>;
86
+ readonly source: Schema.Literals<readonly ["default", "project"]>;
87
+ }>;
88
+ readonly freshness: Schema.Struct<{
89
+ readonly authoredAt: Schema.optionalKey<Schema.String>;
90
+ readonly lastSessionAt: Schema.optionalKey<Schema.String>;
91
+ readonly effectiveAt: Schema.optionalKey<Schema.String>;
92
+ readonly ageDays: Schema.optionalKey<Schema.Number>;
93
+ readonly mtimesLookRewritten: Schema.Boolean;
94
+ }>;
95
+ readonly eligibility: Schema.Union<readonly [Schema.Struct<{
96
+ readonly kind: Schema.Literal<"candidate">;
97
+ }>, Schema.Struct<{
98
+ readonly kind: Schema.Literal<"opted_out">;
99
+ }>, Schema.Struct<{
100
+ readonly kind: Schema.Literal<"recent">;
101
+ readonly eligibleAfterDays: Schema.Number;
102
+ }>, Schema.Struct<{
103
+ readonly kind: Schema.Literal<"unknown_age">;
104
+ }>, Schema.Struct<{
105
+ readonly kind: Schema.Literal<"empty">;
106
+ }>, Schema.Struct<{
107
+ readonly kind: Schema.Literal<"invalid_policy">;
108
+ }>]>;
109
+ readonly targets: Schema.$Array<Schema.Struct<{
110
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
111
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
112
+ readonly path: Schema.NonEmptyString;
113
+ readonly relativePath: Schema.NonEmptyString;
114
+ readonly bytes: Schema.Int;
115
+ readonly description: Schema.NonEmptyString;
116
+ readonly rebuildCost: Schema.NonEmptyString;
117
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
118
+ }>>;
119
+ readonly refusals: Schema.$Array<Schema.Struct<{
120
+ readonly path: Schema.NonEmptyString;
121
+ readonly relativePath: Schema.NonEmptyString;
122
+ readonly code: Schema.Literals<readonly ["protected_path", "outside_root", "different_volume", "installed_engine", "unreadable"]>;
123
+ readonly reason: Schema.NonEmptyString;
124
+ }>>;
125
+ readonly diagnostics: Schema.$Array<Schema.Struct<{
126
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
127
+ readonly message: Schema.NonEmptyString;
128
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
129
+ }>>;
130
+ readonly reclaimableBytes: Schema.Int;
131
+ }>;
132
+ export interface CustodianProjectReport extends Schema.Schema.Type<typeof CustodianProjectReport> {
133
+ }
134
+ export declare const CustodianEngineReport: Schema.Struct<{
135
+ readonly kind: Schema.Literal<"engine">;
136
+ readonly name: Schema.NonEmptyString;
137
+ readonly root: Schema.NonEmptyString;
138
+ readonly version: Schema.NonEmptyString;
139
+ readonly buildKind: Schema.Literals<readonly ["installed", "source"]>;
140
+ readonly targets: Schema.$Array<Schema.Struct<{
141
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
142
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
143
+ readonly path: Schema.NonEmptyString;
144
+ readonly relativePath: Schema.NonEmptyString;
145
+ readonly bytes: Schema.Int;
146
+ readonly description: Schema.NonEmptyString;
147
+ readonly rebuildCost: Schema.NonEmptyString;
148
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
149
+ }>>;
150
+ readonly refusals: Schema.$Array<Schema.Struct<{
151
+ readonly path: Schema.NonEmptyString;
152
+ readonly relativePath: Schema.NonEmptyString;
153
+ readonly code: Schema.Literals<readonly ["protected_path", "outside_root", "different_volume", "installed_engine", "unreadable"]>;
154
+ readonly reason: Schema.NonEmptyString;
155
+ }>>;
156
+ readonly diagnostics: Schema.$Array<Schema.Struct<{
157
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
158
+ readonly message: Schema.NonEmptyString;
159
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
160
+ }>>;
161
+ readonly reclaimableBytes: Schema.Int;
162
+ }>;
163
+ export interface CustodianEngineReport extends Schema.Schema.Type<typeof CustodianEngineReport> {
164
+ }
165
+ export declare const CustodianPlanItem: Schema.Struct<{
166
+ readonly kind: Schema.Literals<readonly ["project", "engine"]>;
167
+ readonly name: Schema.NonEmptyString;
168
+ readonly root: Schema.NonEmptyString;
169
+ readonly bytes: Schema.Int;
170
+ readonly targets: Schema.$Array<Schema.Struct<{
171
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
172
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
173
+ readonly path: Schema.NonEmptyString;
174
+ readonly relativePath: Schema.NonEmptyString;
175
+ readonly bytes: Schema.Int;
176
+ readonly description: Schema.NonEmptyString;
177
+ readonly rebuildCost: Schema.NonEmptyString;
178
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
179
+ }>>;
180
+ }>;
181
+ export interface CustodianPlanItem extends Schema.Schema.Type<typeof CustodianPlanItem> {
182
+ }
183
+ export declare const CustodianPlan: Schema.Struct<{
184
+ readonly status: Schema.Literals<readonly ["ready", "pressure_satisfied", "nothing_eligible"]>;
185
+ readonly freeBytes: Schema.Int;
186
+ readonly thresholdBytes: Schema.Int;
187
+ readonly projectedFreeBytes: Schema.Int;
188
+ readonly reclaimableBytes: Schema.Int;
189
+ readonly items: Schema.$Array<Schema.Struct<{
190
+ readonly kind: Schema.Literals<readonly ["project", "engine"]>;
191
+ readonly name: Schema.NonEmptyString;
192
+ readonly root: Schema.NonEmptyString;
193
+ readonly bytes: Schema.Int;
194
+ readonly targets: Schema.$Array<Schema.Struct<{
195
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
196
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
197
+ readonly path: Schema.NonEmptyString;
198
+ readonly relativePath: Schema.NonEmptyString;
199
+ readonly bytes: Schema.Int;
200
+ readonly description: Schema.NonEmptyString;
201
+ readonly rebuildCost: Schema.NonEmptyString;
202
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
203
+ }>>;
204
+ }>>;
205
+ }>;
206
+ export interface CustodianPlan extends Schema.Schema.Type<typeof CustodianPlan> {
207
+ }
208
+ export declare const CustodianScanRequest: Schema.Struct<{
209
+ readonly root: Schema.NonEmptyString;
210
+ readonly ignorePressure: Schema.optionalKey<Schema.Boolean>;
211
+ }>;
212
+ export interface CustodianScanRequest extends Schema.Schema.Type<typeof CustodianScanRequest> {
213
+ }
214
+ export declare const CustodianReport: Schema.Struct<{
215
+ readonly schemaVersion: Schema.Literal<2>;
216
+ readonly root: Schema.NonEmptyString;
217
+ readonly measuredAt: Schema.String;
218
+ readonly freeBytes: Schema.Int;
219
+ readonly totalReclaimableBytes: Schema.Int;
220
+ readonly projects: Schema.$Array<Schema.Struct<{
221
+ readonly kind: Schema.Literal<"project">;
222
+ readonly name: Schema.NonEmptyString;
223
+ readonly root: Schema.NonEmptyString;
224
+ readonly descriptor: Schema.NonEmptyString;
225
+ readonly engineAssociation: Schema.NonEmptyString;
226
+ readonly isCpp: Schema.Boolean;
227
+ readonly policy: Schema.Struct<{
228
+ readonly enabled: Schema.Boolean;
229
+ readonly minAgeDays: Schema.Number;
230
+ readonly minFreeGb: Schema.Number;
231
+ readonly keepBinariesForCpp: Schema.Boolean;
232
+ readonly targets: Schema.$Array<Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>>;
233
+ readonly source: Schema.Literals<readonly ["default", "project"]>;
234
+ }>;
235
+ readonly freshness: Schema.Struct<{
236
+ readonly authoredAt: Schema.optionalKey<Schema.String>;
237
+ readonly lastSessionAt: Schema.optionalKey<Schema.String>;
238
+ readonly effectiveAt: Schema.optionalKey<Schema.String>;
239
+ readonly ageDays: Schema.optionalKey<Schema.Number>;
240
+ readonly mtimesLookRewritten: Schema.Boolean;
241
+ }>;
242
+ readonly eligibility: Schema.Union<readonly [Schema.Struct<{
243
+ readonly kind: Schema.Literal<"candidate">;
244
+ }>, Schema.Struct<{
245
+ readonly kind: Schema.Literal<"opted_out">;
246
+ }>, Schema.Struct<{
247
+ readonly kind: Schema.Literal<"recent">;
248
+ readonly eligibleAfterDays: Schema.Number;
249
+ }>, Schema.Struct<{
250
+ readonly kind: Schema.Literal<"unknown_age">;
251
+ }>, Schema.Struct<{
252
+ readonly kind: Schema.Literal<"empty">;
253
+ }>, Schema.Struct<{
254
+ readonly kind: Schema.Literal<"invalid_policy">;
255
+ }>]>;
256
+ readonly targets: Schema.$Array<Schema.Struct<{
257
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
258
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
259
+ readonly path: Schema.NonEmptyString;
260
+ readonly relativePath: Schema.NonEmptyString;
261
+ readonly bytes: Schema.Int;
262
+ readonly description: Schema.NonEmptyString;
263
+ readonly rebuildCost: Schema.NonEmptyString;
264
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
265
+ }>>;
266
+ readonly refusals: Schema.$Array<Schema.Struct<{
267
+ readonly path: Schema.NonEmptyString;
268
+ readonly relativePath: Schema.NonEmptyString;
269
+ readonly code: Schema.Literals<readonly ["protected_path", "outside_root", "different_volume", "installed_engine", "unreadable"]>;
270
+ readonly reason: Schema.NonEmptyString;
271
+ }>>;
272
+ readonly diagnostics: Schema.$Array<Schema.Struct<{
273
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
274
+ readonly message: Schema.NonEmptyString;
275
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
276
+ }>>;
277
+ readonly reclaimableBytes: Schema.Int;
278
+ }>>;
279
+ readonly engines: Schema.$Array<Schema.Struct<{
280
+ readonly kind: Schema.Literal<"engine">;
281
+ readonly name: Schema.NonEmptyString;
282
+ readonly root: Schema.NonEmptyString;
283
+ readonly version: Schema.NonEmptyString;
284
+ readonly buildKind: Schema.Literals<readonly ["installed", "source"]>;
285
+ readonly targets: Schema.$Array<Schema.Struct<{
286
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
287
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
288
+ readonly path: Schema.NonEmptyString;
289
+ readonly relativePath: Schema.NonEmptyString;
290
+ readonly bytes: Schema.Int;
291
+ readonly description: Schema.NonEmptyString;
292
+ readonly rebuildCost: Schema.NonEmptyString;
293
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
294
+ }>>;
295
+ readonly refusals: Schema.$Array<Schema.Struct<{
296
+ readonly path: Schema.NonEmptyString;
297
+ readonly relativePath: Schema.NonEmptyString;
298
+ readonly code: Schema.Literals<readonly ["protected_path", "outside_root", "different_volume", "installed_engine", "unreadable"]>;
299
+ readonly reason: Schema.NonEmptyString;
300
+ }>>;
301
+ readonly diagnostics: Schema.$Array<Schema.Struct<{
302
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
303
+ readonly message: Schema.NonEmptyString;
304
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
305
+ }>>;
306
+ readonly reclaimableBytes: Schema.Int;
307
+ }>>;
308
+ readonly diagnostics: Schema.$Array<Schema.Struct<{
309
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
310
+ readonly message: Schema.NonEmptyString;
311
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
312
+ }>>;
313
+ readonly plan: Schema.Struct<{
314
+ readonly status: Schema.Literals<readonly ["ready", "pressure_satisfied", "nothing_eligible"]>;
315
+ readonly freeBytes: Schema.Int;
316
+ readonly thresholdBytes: Schema.Int;
317
+ readonly projectedFreeBytes: Schema.Int;
318
+ readonly reclaimableBytes: Schema.Int;
319
+ readonly items: Schema.$Array<Schema.Struct<{
320
+ readonly kind: Schema.Literals<readonly ["project", "engine"]>;
321
+ readonly name: Schema.NonEmptyString;
322
+ readonly root: Schema.NonEmptyString;
323
+ readonly bytes: Schema.Int;
324
+ readonly targets: Schema.$Array<Schema.Struct<{
325
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
326
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
327
+ readonly path: Schema.NonEmptyString;
328
+ readonly relativePath: Schema.NonEmptyString;
329
+ readonly bytes: Schema.Int;
330
+ readonly description: Schema.NonEmptyString;
331
+ readonly rebuildCost: Schema.NonEmptyString;
332
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
333
+ }>>;
334
+ }>>;
335
+ }>;
336
+ readonly destructiveOperationsAvailable: Schema.Literal<true>;
337
+ }>;
338
+ export interface CustodianReport extends Schema.Schema.Type<typeof CustodianReport> {
339
+ }
340
+ export declare const CustodianProposalTarget: Schema.Struct<{
341
+ readonly kind: Schema.Literals<readonly ["project", "engine"]>;
342
+ readonly name: Schema.NonEmptyString;
343
+ readonly root: Schema.NonEmptyString;
344
+ readonly target: Schema.Struct<{
345
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
346
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
347
+ readonly path: Schema.NonEmptyString;
348
+ readonly relativePath: Schema.NonEmptyString;
349
+ readonly bytes: Schema.Int;
350
+ readonly description: Schema.NonEmptyString;
351
+ readonly rebuildCost: Schema.NonEmptyString;
352
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
353
+ }>;
354
+ }>;
355
+ export interface CustodianProposalTarget extends Schema.Schema.Type<typeof CustodianProposalTarget> {
356
+ }
357
+ export declare const CustodianPrepareRequest: Schema.Struct<{
358
+ readonly root: Schema.NonEmptyString;
359
+ readonly ignorePressure: Schema.optionalKey<Schema.Boolean>;
360
+ readonly mode: Schema.Literals<readonly ["trash", "permanent"]>;
361
+ readonly proposalDirectory: Schema.NonEmptyString;
362
+ readonly targetIds: Schema.$Array<Schema.brand<Schema.NonEmptyString, "CustodianTargetId">>;
363
+ }>;
364
+ export interface CustodianPrepareRequest extends Schema.Schema.Type<typeof CustodianPrepareRequest> {
365
+ }
366
+ export declare const CustodianProposal: Schema.Struct<{
367
+ readonly schemaVersion: Schema.Literal<1>;
368
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianProposalId">;
369
+ readonly createdAt: Schema.String;
370
+ readonly root: Schema.NonEmptyString;
371
+ readonly ignorePressure: Schema.Boolean;
372
+ readonly mode: Schema.Literals<readonly ["trash", "permanent"]>;
373
+ readonly proposalPath: Schema.NonEmptyString;
374
+ readonly receiptPath: Schema.NonEmptyString;
375
+ readonly logPath: Schema.NonEmptyString;
376
+ readonly approvalPhrase: Schema.NonEmptyString;
377
+ readonly bytes: Schema.Int;
378
+ readonly targets: Schema.$Array<Schema.Struct<{
379
+ readonly kind: Schema.Literals<readonly ["project", "engine"]>;
380
+ readonly name: Schema.NonEmptyString;
381
+ readonly root: Schema.NonEmptyString;
382
+ readonly target: Schema.Struct<{
383
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
384
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
385
+ readonly path: Schema.NonEmptyString;
386
+ readonly relativePath: Schema.NonEmptyString;
387
+ readonly bytes: Schema.Int;
388
+ readonly description: Schema.NonEmptyString;
389
+ readonly rebuildCost: Schema.NonEmptyString;
390
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
391
+ }>;
392
+ }>>;
393
+ }>;
394
+ export interface CustodianProposal extends Schema.Schema.Type<typeof CustodianProposal> {
395
+ }
396
+ export declare const CustodianExecuteRequest: Schema.Struct<{
397
+ readonly proposalPath: Schema.NonEmptyString;
398
+ readonly approvalPhrase: Schema.NonEmptyString;
399
+ }>;
400
+ export interface CustodianExecuteRequest extends Schema.Schema.Type<typeof CustodianExecuteRequest> {
401
+ }
402
+ export declare const CustodianCancelResult: Schema.Struct<{
403
+ readonly proposalId: Schema.brand<Schema.NonEmptyString, "CustodianProposalId">;
404
+ readonly status: Schema.Literals<readonly ["cancelled", "not_running"]>;
405
+ }>;
406
+ export interface CustodianCancelResult extends Schema.Schema.Type<typeof CustodianCancelResult> {
407
+ }
408
+ export declare const CustodianExecutionRefusal: Schema.Struct<{
409
+ readonly code: Schema.Literals<readonly ["approval_mismatch", "editor_running", "proposal_stale", "target_invalid"]>;
410
+ readonly message: Schema.NonEmptyString;
411
+ readonly recovery: Schema.NonEmptyString;
412
+ }>;
413
+ export interface CustodianExecutionRefusal extends Schema.Schema.Type<typeof CustodianExecutionRefusal> {
414
+ }
415
+ export declare const CustodianExecutionEntry: Schema.Struct<{
416
+ readonly targetId: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
417
+ readonly path: Schema.NonEmptyString;
418
+ readonly relativePath: Schema.NonEmptyString;
419
+ readonly bytes: Schema.Int;
420
+ readonly status: Schema.Literals<readonly ["trashed", "deleted", "failed", "cancelled"]>;
421
+ readonly message: Schema.optionalKey<Schema.NonEmptyString>;
422
+ }>;
423
+ export interface CustodianExecutionEntry extends Schema.Schema.Type<typeof CustodianExecutionEntry> {
424
+ }
425
+ export declare const CustodianReceipt: Schema.Struct<{
426
+ readonly schemaVersion: Schema.Literal<1>;
427
+ readonly proposalId: Schema.brand<Schema.NonEmptyString, "CustodianProposalId">;
428
+ readonly proposalPath: Schema.NonEmptyString;
429
+ readonly receiptPath: Schema.NonEmptyString;
430
+ readonly logPath: Schema.NonEmptyString;
431
+ readonly root: Schema.NonEmptyString;
432
+ readonly mode: Schema.Literals<readonly ["trash", "permanent"]>;
433
+ readonly startedAt: Schema.String;
434
+ readonly finishedAt: Schema.String;
435
+ readonly status: Schema.Literals<readonly ["completed", "partial", "cancelled", "refused"]>;
436
+ readonly plannedBytes: Schema.Int;
437
+ readonly processedBytes: Schema.Int;
438
+ readonly entries: Schema.$Array<Schema.Struct<{
439
+ readonly targetId: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
440
+ readonly path: Schema.NonEmptyString;
441
+ readonly relativePath: Schema.NonEmptyString;
442
+ readonly bytes: Schema.Int;
443
+ readonly status: Schema.Literals<readonly ["trashed", "deleted", "failed", "cancelled"]>;
444
+ readonly message: Schema.optionalKey<Schema.NonEmptyString>;
445
+ }>>;
446
+ readonly refusal: Schema.optionalKey<Schema.Struct<{
447
+ readonly code: Schema.Literals<readonly ["approval_mismatch", "editor_running", "proposal_stale", "target_invalid"]>;
448
+ readonly message: Schema.NonEmptyString;
449
+ readonly recovery: Schema.NonEmptyString;
450
+ }>>;
451
+ }>;
452
+ export interface CustodianReceipt extends Schema.Schema.Type<typeof CustodianReceipt> {
453
+ }
454
+ export declare const decodeCustodianScanRequest: (input: unknown, options?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
455
+ readonly root: string;
456
+ readonly ignorePressure?: boolean;
457
+ }, Schema.SchemaError, never>;
458
+ export declare const decodeCustodianReport: (input: unknown, options?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<Schema.Struct.ReadonlySide<{
459
+ readonly schemaVersion: Schema.Literal<2>;
460
+ readonly root: Schema.NonEmptyString;
461
+ readonly measuredAt: Schema.String;
462
+ readonly freeBytes: Schema.Int;
463
+ readonly totalReclaimableBytes: Schema.Int;
464
+ readonly projects: Schema.$Array<Schema.Struct<{
465
+ readonly kind: Schema.Literal<"project">;
466
+ readonly name: Schema.NonEmptyString;
467
+ readonly root: Schema.NonEmptyString;
468
+ readonly descriptor: Schema.NonEmptyString;
469
+ readonly engineAssociation: Schema.NonEmptyString;
470
+ readonly isCpp: Schema.Boolean;
471
+ readonly policy: Schema.Struct<{
472
+ readonly enabled: Schema.Boolean;
473
+ readonly minAgeDays: Schema.Number;
474
+ readonly minFreeGb: Schema.Number;
475
+ readonly keepBinariesForCpp: Schema.Boolean;
476
+ readonly targets: Schema.$Array<Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>>;
477
+ readonly source: Schema.Literals<readonly ["default", "project"]>;
478
+ }>;
479
+ readonly freshness: Schema.Struct<{
480
+ readonly authoredAt: Schema.optionalKey<Schema.String>;
481
+ readonly lastSessionAt: Schema.optionalKey<Schema.String>;
482
+ readonly effectiveAt: Schema.optionalKey<Schema.String>;
483
+ readonly ageDays: Schema.optionalKey<Schema.Number>;
484
+ readonly mtimesLookRewritten: Schema.Boolean;
485
+ }>;
486
+ readonly eligibility: Schema.Union<readonly [Schema.Struct<{
487
+ readonly kind: Schema.Literal<"candidate">;
488
+ }>, Schema.Struct<{
489
+ readonly kind: Schema.Literal<"opted_out">;
490
+ }>, Schema.Struct<{
491
+ readonly kind: Schema.Literal<"recent">;
492
+ readonly eligibleAfterDays: Schema.Number;
493
+ }>, Schema.Struct<{
494
+ readonly kind: Schema.Literal<"unknown_age">;
495
+ }>, Schema.Struct<{
496
+ readonly kind: Schema.Literal<"empty">;
497
+ }>, Schema.Struct<{
498
+ readonly kind: Schema.Literal<"invalid_policy">;
499
+ }>]>;
500
+ readonly targets: Schema.$Array<Schema.Struct<{
501
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
502
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
503
+ readonly path: Schema.NonEmptyString;
504
+ readonly relativePath: Schema.NonEmptyString;
505
+ readonly bytes: Schema.Int;
506
+ readonly description: Schema.NonEmptyString;
507
+ readonly rebuildCost: Schema.NonEmptyString;
508
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
509
+ }>>;
510
+ readonly refusals: Schema.$Array<Schema.Struct<{
511
+ readonly path: Schema.NonEmptyString;
512
+ readonly relativePath: Schema.NonEmptyString;
513
+ readonly code: Schema.Literals<readonly ["protected_path", "outside_root", "different_volume", "installed_engine", "unreadable"]>;
514
+ readonly reason: Schema.NonEmptyString;
515
+ }>>;
516
+ readonly diagnostics: Schema.$Array<Schema.Struct<{
517
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
518
+ readonly message: Schema.NonEmptyString;
519
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
520
+ }>>;
521
+ readonly reclaimableBytes: Schema.Int;
522
+ }>>;
523
+ readonly engines: Schema.$Array<Schema.Struct<{
524
+ readonly kind: Schema.Literal<"engine">;
525
+ readonly name: Schema.NonEmptyString;
526
+ readonly root: Schema.NonEmptyString;
527
+ readonly version: Schema.NonEmptyString;
528
+ readonly buildKind: Schema.Literals<readonly ["installed", "source"]>;
529
+ readonly targets: Schema.$Array<Schema.Struct<{
530
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
531
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
532
+ readonly path: Schema.NonEmptyString;
533
+ readonly relativePath: Schema.NonEmptyString;
534
+ readonly bytes: Schema.Int;
535
+ readonly description: Schema.NonEmptyString;
536
+ readonly rebuildCost: Schema.NonEmptyString;
537
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
538
+ }>>;
539
+ readonly refusals: Schema.$Array<Schema.Struct<{
540
+ readonly path: Schema.NonEmptyString;
541
+ readonly relativePath: Schema.NonEmptyString;
542
+ readonly code: Schema.Literals<readonly ["protected_path", "outside_root", "different_volume", "installed_engine", "unreadable"]>;
543
+ readonly reason: Schema.NonEmptyString;
544
+ }>>;
545
+ readonly diagnostics: Schema.$Array<Schema.Struct<{
546
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
547
+ readonly message: Schema.NonEmptyString;
548
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
549
+ }>>;
550
+ readonly reclaimableBytes: Schema.Int;
551
+ }>>;
552
+ readonly diagnostics: Schema.$Array<Schema.Struct<{
553
+ readonly code: Schema.Literals<readonly ["invalid_policy", "descriptor_unreadable", "target_unreadable", "discovery_incomplete", "cross_volume_skipped", "hardlink_excluded"]>;
554
+ readonly message: Schema.NonEmptyString;
555
+ readonly path: Schema.optionalKey<Schema.NonEmptyString>;
556
+ }>>;
557
+ readonly plan: Schema.Struct<{
558
+ readonly status: Schema.Literals<readonly ["ready", "pressure_satisfied", "nothing_eligible"]>;
559
+ readonly freeBytes: Schema.Int;
560
+ readonly thresholdBytes: Schema.Int;
561
+ readonly projectedFreeBytes: Schema.Int;
562
+ readonly reclaimableBytes: Schema.Int;
563
+ readonly items: Schema.$Array<Schema.Struct<{
564
+ readonly kind: Schema.Literals<readonly ["project", "engine"]>;
565
+ readonly name: Schema.NonEmptyString;
566
+ readonly root: Schema.NonEmptyString;
567
+ readonly bytes: Schema.Int;
568
+ readonly targets: Schema.$Array<Schema.Struct<{
569
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
570
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
571
+ readonly path: Schema.NonEmptyString;
572
+ readonly relativePath: Schema.NonEmptyString;
573
+ readonly bytes: Schema.Int;
574
+ readonly description: Schema.NonEmptyString;
575
+ readonly rebuildCost: Schema.NonEmptyString;
576
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
577
+ }>>;
578
+ }>>;
579
+ }>;
580
+ readonly destructiveOperationsAvailable: Schema.Literal<true>;
581
+ }, "Type">, Schema.SchemaError, never>;
582
+ export declare const decodeCustodianPrepareRequest: (input: unknown, options?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
583
+ readonly root: string;
584
+ readonly mode: "trash" | "permanent";
585
+ readonly proposalDirectory: string;
586
+ readonly targetIds: readonly (string & import("effect/Brand").Brand<"CustodianTargetId">)[];
587
+ readonly ignorePressure?: boolean;
588
+ }, Schema.SchemaError, never>;
589
+ export declare const decodeCustodianProposal: (input: unknown, options?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<Schema.Struct.ReadonlySide<{
590
+ readonly schemaVersion: Schema.Literal<1>;
591
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianProposalId">;
592
+ readonly createdAt: Schema.String;
593
+ readonly root: Schema.NonEmptyString;
594
+ readonly ignorePressure: Schema.Boolean;
595
+ readonly mode: Schema.Literals<readonly ["trash", "permanent"]>;
596
+ readonly proposalPath: Schema.NonEmptyString;
597
+ readonly receiptPath: Schema.NonEmptyString;
598
+ readonly logPath: Schema.NonEmptyString;
599
+ readonly approvalPhrase: Schema.NonEmptyString;
600
+ readonly bytes: Schema.Int;
601
+ readonly targets: Schema.$Array<Schema.Struct<{
602
+ readonly kind: Schema.Literals<readonly ["project", "engine"]>;
603
+ readonly name: Schema.NonEmptyString;
604
+ readonly root: Schema.NonEmptyString;
605
+ readonly target: Schema.Struct<{
606
+ readonly id: Schema.brand<Schema.NonEmptyString, "CustodianTargetId">;
607
+ readonly key: Schema.Union<readonly [Schema.Literals<readonly ["intermediate", "plugin_intermediate", "binaries", "plugin_binaries", "build", "ddc", "cooked", "staged", "logs", "crashes", "autosaves", "saved_config"]>, Schema.Literals<readonly ["engine_ddc", "engine_logs", "engine_crashes", "engine_intermediate", "engine_binaries"]>]>;
608
+ readonly path: Schema.NonEmptyString;
609
+ readonly relativePath: Schema.NonEmptyString;
610
+ readonly bytes: Schema.Int;
611
+ readonly description: Schema.NonEmptyString;
612
+ readonly rebuildCost: Schema.NonEmptyString;
613
+ readonly risk: Schema.Literals<readonly ["low", "medium", "high", "critical"]>;
614
+ }>;
615
+ }>>;
616
+ }, "Type">, Schema.SchemaError, never>;
617
+ export declare const decodeCustodianExecuteRequest: (input: unknown, options?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<Schema.Struct.ReadonlySide<{
618
+ readonly proposalPath: Schema.NonEmptyString;
619
+ readonly approvalPhrase: Schema.NonEmptyString;
620
+ }, "Type">, Schema.SchemaError, never>;
621
+ export declare const decodeCustodianReceipt: (input: unknown, options?: import("effect/SchemaAST").ParseOptions) => import("effect/Effect").Effect<{
622
+ readonly entries: readonly {
623
+ readonly path: string;
624
+ readonly relativePath: string;
625
+ readonly bytes: number;
626
+ readonly status: "cancelled" | "trashed" | "deleted" | "failed";
627
+ readonly targetId: string & import("effect/Brand").Brand<"CustodianTargetId">;
628
+ readonly message?: string;
629
+ }[];
630
+ readonly root: string;
631
+ readonly status: "cancelled" | "completed" | "partial" | "refused";
632
+ readonly schemaVersion: 1;
633
+ readonly mode: "trash" | "permanent";
634
+ readonly proposalPath: string;
635
+ readonly receiptPath: string;
636
+ readonly logPath: string;
637
+ readonly proposalId: string & import("effect/Brand").Brand<"CustodianProposalId">;
638
+ readonly startedAt: string;
639
+ readonly finishedAt: string;
640
+ readonly plannedBytes: number;
641
+ readonly processedBytes: number;
642
+ readonly refusal?: Schema.Struct.ReadonlySide<{
643
+ readonly code: Schema.Literals<readonly ["approval_mismatch", "editor_running", "proposal_stale", "target_invalid"]>;
644
+ readonly message: Schema.NonEmptyString;
645
+ readonly recovery: Schema.NonEmptyString;
646
+ }, "Type">;
647
+ }, Schema.SchemaError, never>;
648
+ //# sourceMappingURL=schema.d.ts.map