agent-shim 8.32.0 → 8.34.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/dist/cli.cjs +2054 -148
- package/dist/index.cjs +143 -61
- package/dist/index.mjs +143 -61
- package/dist/types/index.d.ts +939 -41
- package/package.json +2 -1
package/dist/types/index.d.ts
CHANGED
|
@@ -1,3 +1,5 @@
|
|
|
1
|
+
import * as trilean from 'trilean';
|
|
2
|
+
import { PredicateNodeSchema } from 'trilean';
|
|
1
3
|
import * as zod from 'zod';
|
|
2
4
|
import { z } from 'zod';
|
|
3
5
|
import { IncomingHttpHeaders, IncomingMessage, ServerResponse } from 'node:http';
|
|
@@ -38,37 +40,232 @@ declare const CategoryMapSchema: z.ZodPipe<z.ZodObject<{
|
|
|
38
40
|
settings?: boolean | undefined;
|
|
39
41
|
}>>;
|
|
40
42
|
/**
|
|
41
|
-
* A
|
|
43
|
+
* A `when` condition, in either form. The object form is the original sugar (every present field must hold); the predicate form is a trilean predicate tree, which expresses OR and NOT and reports a missing fact as indeterminate rather than failed. The two are one union, not a migration: every existing configuration keeps parsing, and `evaluateWhen` gives the object form the same semantics it always had by mapping it onto the equivalent predicates.
|
|
42
44
|
*/
|
|
43
|
-
declare const WhenSchema: z.ZodObject<{
|
|
45
|
+
declare const WhenSchema: z.ZodUnion<readonly [z.ZodObject<{
|
|
44
46
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
45
47
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
46
48
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
47
49
|
branch: z.ZodOptional<z.ZodString>;
|
|
48
50
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
49
|
-
}, z.core.$strict
|
|
50
|
-
|
|
51
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
52
|
+
kind: z.ZodLiteral<"not">;
|
|
53
|
+
operand: typeof PredicateNodeSchema;
|
|
54
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
55
|
+
kind: z.ZodLiteral<"and">;
|
|
56
|
+
left: typeof PredicateNodeSchema;
|
|
57
|
+
right: typeof PredicateNodeSchema;
|
|
58
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
59
|
+
kind: z.ZodLiteral<"or">;
|
|
60
|
+
left: typeof PredicateNodeSchema;
|
|
61
|
+
right: typeof PredicateNodeSchema;
|
|
62
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
63
|
+
kind: z.ZodLiteral<"allOf">;
|
|
64
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
65
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
66
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
67
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
68
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
69
|
+
kind: z.ZodLiteral<"compare">;
|
|
70
|
+
op: z.ZodEnum<{
|
|
71
|
+
gt: "gt";
|
|
72
|
+
gte: "gte";
|
|
73
|
+
lt: "lt";
|
|
74
|
+
lte: "lte";
|
|
75
|
+
eq: "eq";
|
|
76
|
+
neq: "neq";
|
|
77
|
+
}>;
|
|
78
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
79
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
80
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
81
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
82
|
+
op: z.ZodEnum<{
|
|
83
|
+
equals: "equals";
|
|
84
|
+
notEquals: "notEquals";
|
|
85
|
+
matches: "matches";
|
|
86
|
+
notMatches: "notMatches";
|
|
87
|
+
portableMatches: "portableMatches";
|
|
88
|
+
portableNotMatches: "portableNotMatches";
|
|
89
|
+
}>;
|
|
90
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
91
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
92
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
93
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
94
|
+
op: z.ZodEnum<{
|
|
95
|
+
in: "in";
|
|
96
|
+
notIn: "notIn";
|
|
97
|
+
}>;
|
|
98
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
99
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
100
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
101
|
+
kind: z.ZodLiteral<"exists">;
|
|
102
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
103
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
104
|
+
kind: z.ZodLiteral<"some">;
|
|
105
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
106
|
+
item: typeof PredicateNodeSchema;
|
|
107
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
108
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
109
|
+
kind: z.ZodLiteral<"every">;
|
|
110
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
111
|
+
item: typeof PredicateNodeSchema;
|
|
112
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
113
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
114
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
115
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
116
|
+
}, z.core.$strip>], "kind">]>;
|
|
117
|
+
type WhenCondition = z.output<typeof WhenSchema>;
|
|
51
118
|
/** An entries value: a flat boolean, or a boolean guarded by a `when` condition. */
|
|
52
119
|
declare const EntryValueSchema: z.ZodUnion<readonly [z.ZodBoolean, z.ZodObject<{
|
|
53
120
|
value: z.ZodBoolean;
|
|
54
|
-
when: z.ZodObject<{
|
|
121
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
55
122
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
56
123
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
57
124
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
58
125
|
branch: z.ZodOptional<z.ZodString>;
|
|
59
126
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
60
|
-
}, z.core.$strict
|
|
127
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
128
|
+
kind: z.ZodLiteral<"not">;
|
|
129
|
+
operand: typeof PredicateNodeSchema;
|
|
130
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
131
|
+
kind: z.ZodLiteral<"and">;
|
|
132
|
+
left: typeof PredicateNodeSchema;
|
|
133
|
+
right: typeof PredicateNodeSchema;
|
|
134
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
135
|
+
kind: z.ZodLiteral<"or">;
|
|
136
|
+
left: typeof PredicateNodeSchema;
|
|
137
|
+
right: typeof PredicateNodeSchema;
|
|
138
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
139
|
+
kind: z.ZodLiteral<"allOf">;
|
|
140
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
141
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
142
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
143
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
144
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
145
|
+
kind: z.ZodLiteral<"compare">;
|
|
146
|
+
op: z.ZodEnum<{
|
|
147
|
+
gt: "gt";
|
|
148
|
+
gte: "gte";
|
|
149
|
+
lt: "lt";
|
|
150
|
+
lte: "lte";
|
|
151
|
+
eq: "eq";
|
|
152
|
+
neq: "neq";
|
|
153
|
+
}>;
|
|
154
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
155
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
156
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
157
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
158
|
+
op: z.ZodEnum<{
|
|
159
|
+
equals: "equals";
|
|
160
|
+
notEquals: "notEquals";
|
|
161
|
+
matches: "matches";
|
|
162
|
+
notMatches: "notMatches";
|
|
163
|
+
portableMatches: "portableMatches";
|
|
164
|
+
portableNotMatches: "portableNotMatches";
|
|
165
|
+
}>;
|
|
166
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
167
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
168
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
169
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
170
|
+
op: z.ZodEnum<{
|
|
171
|
+
in: "in";
|
|
172
|
+
notIn: "notIn";
|
|
173
|
+
}>;
|
|
174
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
175
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
176
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
177
|
+
kind: z.ZodLiteral<"exists">;
|
|
178
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
179
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
180
|
+
kind: z.ZodLiteral<"some">;
|
|
181
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
182
|
+
item: typeof PredicateNodeSchema;
|
|
183
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
184
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
185
|
+
kind: z.ZodLiteral<"every">;
|
|
186
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
187
|
+
item: typeof PredicateNodeSchema;
|
|
188
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
189
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
190
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
191
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
192
|
+
}, z.core.$strip>], "kind">]>;
|
|
61
193
|
}, z.core.$strict>]>;
|
|
62
194
|
type EntryValue = z.infer<typeof EntryValueSchema>;
|
|
63
195
|
declare const EntriesSchema: z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodObject<{
|
|
64
196
|
value: z.ZodBoolean;
|
|
65
|
-
when: z.ZodObject<{
|
|
197
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
66
198
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
67
199
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
68
200
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
69
201
|
branch: z.ZodOptional<z.ZodString>;
|
|
70
202
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
71
|
-
}, z.core.$strict
|
|
203
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
204
|
+
kind: z.ZodLiteral<"not">;
|
|
205
|
+
operand: typeof PredicateNodeSchema;
|
|
206
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
207
|
+
kind: z.ZodLiteral<"and">;
|
|
208
|
+
left: typeof PredicateNodeSchema;
|
|
209
|
+
right: typeof PredicateNodeSchema;
|
|
210
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
211
|
+
kind: z.ZodLiteral<"or">;
|
|
212
|
+
left: typeof PredicateNodeSchema;
|
|
213
|
+
right: typeof PredicateNodeSchema;
|
|
214
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
215
|
+
kind: z.ZodLiteral<"allOf">;
|
|
216
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
217
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
218
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
219
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
220
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
221
|
+
kind: z.ZodLiteral<"compare">;
|
|
222
|
+
op: z.ZodEnum<{
|
|
223
|
+
gt: "gt";
|
|
224
|
+
gte: "gte";
|
|
225
|
+
lt: "lt";
|
|
226
|
+
lte: "lte";
|
|
227
|
+
eq: "eq";
|
|
228
|
+
neq: "neq";
|
|
229
|
+
}>;
|
|
230
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
231
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
232
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
233
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
234
|
+
op: z.ZodEnum<{
|
|
235
|
+
equals: "equals";
|
|
236
|
+
notEquals: "notEquals";
|
|
237
|
+
matches: "matches";
|
|
238
|
+
notMatches: "notMatches";
|
|
239
|
+
portableMatches: "portableMatches";
|
|
240
|
+
portableNotMatches: "portableNotMatches";
|
|
241
|
+
}>;
|
|
242
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
243
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
244
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
245
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
246
|
+
op: z.ZodEnum<{
|
|
247
|
+
in: "in";
|
|
248
|
+
notIn: "notIn";
|
|
249
|
+
}>;
|
|
250
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
251
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
252
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
253
|
+
kind: z.ZodLiteral<"exists">;
|
|
254
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
255
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
256
|
+
kind: z.ZodLiteral<"some">;
|
|
257
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
258
|
+
item: typeof PredicateNodeSchema;
|
|
259
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
260
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
261
|
+
kind: z.ZodLiteral<"every">;
|
|
262
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
263
|
+
item: typeof PredicateNodeSchema;
|
|
264
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
265
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
266
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
267
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
268
|
+
}, z.core.$strip>], "kind">]>;
|
|
72
269
|
}, z.core.$strict>]>>;
|
|
73
270
|
type Entries = z.infer<typeof EntriesSchema>;
|
|
74
271
|
/** Launch flags, resolved through the same cascade as categories and entries. */
|
|
@@ -334,13 +531,78 @@ declare const ConfigProfileSchema: z.ZodObject<{
|
|
|
334
531
|
}>>>;
|
|
335
532
|
entries: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodObject<{
|
|
336
533
|
value: z.ZodBoolean;
|
|
337
|
-
when: z.ZodObject<{
|
|
534
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
338
535
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
339
536
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
340
537
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
341
538
|
branch: z.ZodOptional<z.ZodString>;
|
|
342
539
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
343
|
-
}, z.core.$strict
|
|
540
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
541
|
+
kind: z.ZodLiteral<"not">;
|
|
542
|
+
operand: typeof PredicateNodeSchema;
|
|
543
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
544
|
+
kind: z.ZodLiteral<"and">;
|
|
545
|
+
left: typeof PredicateNodeSchema;
|
|
546
|
+
right: typeof PredicateNodeSchema;
|
|
547
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
548
|
+
kind: z.ZodLiteral<"or">;
|
|
549
|
+
left: typeof PredicateNodeSchema;
|
|
550
|
+
right: typeof PredicateNodeSchema;
|
|
551
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
552
|
+
kind: z.ZodLiteral<"allOf">;
|
|
553
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
554
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
555
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
556
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
557
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
558
|
+
kind: z.ZodLiteral<"compare">;
|
|
559
|
+
op: z.ZodEnum<{
|
|
560
|
+
gt: "gt";
|
|
561
|
+
gte: "gte";
|
|
562
|
+
lt: "lt";
|
|
563
|
+
lte: "lte";
|
|
564
|
+
eq: "eq";
|
|
565
|
+
neq: "neq";
|
|
566
|
+
}>;
|
|
567
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
568
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
569
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
570
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
571
|
+
op: z.ZodEnum<{
|
|
572
|
+
equals: "equals";
|
|
573
|
+
notEquals: "notEquals";
|
|
574
|
+
matches: "matches";
|
|
575
|
+
notMatches: "notMatches";
|
|
576
|
+
portableMatches: "portableMatches";
|
|
577
|
+
portableNotMatches: "portableNotMatches";
|
|
578
|
+
}>;
|
|
579
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
580
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
581
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
582
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
583
|
+
op: z.ZodEnum<{
|
|
584
|
+
in: "in";
|
|
585
|
+
notIn: "notIn";
|
|
586
|
+
}>;
|
|
587
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
588
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
589
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
590
|
+
kind: z.ZodLiteral<"exists">;
|
|
591
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
592
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
593
|
+
kind: z.ZodLiteral<"some">;
|
|
594
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
595
|
+
item: typeof PredicateNodeSchema;
|
|
596
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
597
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
598
|
+
kind: z.ZodLiteral<"every">;
|
|
599
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
600
|
+
item: typeof PredicateNodeSchema;
|
|
601
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
602
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
603
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
604
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
605
|
+
}, z.core.$strip>], "kind">]>;
|
|
344
606
|
}, z.core.$strict>]>>>;
|
|
345
607
|
launch: z.ZodOptional<z.ZodObject<{
|
|
346
608
|
skipPermissions: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -368,7 +630,81 @@ type PoolPreference = z.infer<typeof PoolPreferenceSchema>;
|
|
|
368
630
|
* `preference` decides how the member is chosen, and an absent field means "score". "score" ranks members by plan-size-weighted remaining quota per hour until reset, so the quota closest to expiring is spent first (use-it-or-lose-it). "listed" ranks members strictly in the order the pool lists them, skipping only a member that is currently refused, so a pool can pin one identity first and fall back to the others only while that one is refused.
|
|
369
631
|
*/
|
|
370
632
|
declare const PoolSchema: z.ZodObject<{
|
|
371
|
-
identities: z.ZodArray<z.ZodString
|
|
633
|
+
identities: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
634
|
+
identity: z.ZodString;
|
|
635
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
636
|
+
newerThan: z.ZodOptional<z.ZodString>;
|
|
637
|
+
olderThan: z.ZodOptional<z.ZodString>;
|
|
638
|
+
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
639
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
640
|
+
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
641
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
642
|
+
kind: z.ZodLiteral<"not">;
|
|
643
|
+
operand: typeof PredicateNodeSchema;
|
|
644
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
645
|
+
kind: z.ZodLiteral<"and">;
|
|
646
|
+
left: typeof PredicateNodeSchema;
|
|
647
|
+
right: typeof PredicateNodeSchema;
|
|
648
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
649
|
+
kind: z.ZodLiteral<"or">;
|
|
650
|
+
left: typeof PredicateNodeSchema;
|
|
651
|
+
right: typeof PredicateNodeSchema;
|
|
652
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
653
|
+
kind: z.ZodLiteral<"allOf">;
|
|
654
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
655
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
656
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
657
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
658
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
659
|
+
kind: z.ZodLiteral<"compare">;
|
|
660
|
+
op: z.ZodEnum<{
|
|
661
|
+
gt: "gt";
|
|
662
|
+
gte: "gte";
|
|
663
|
+
lt: "lt";
|
|
664
|
+
lte: "lte";
|
|
665
|
+
eq: "eq";
|
|
666
|
+
neq: "neq";
|
|
667
|
+
}>;
|
|
668
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
669
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
670
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
671
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
672
|
+
op: z.ZodEnum<{
|
|
673
|
+
equals: "equals";
|
|
674
|
+
notEquals: "notEquals";
|
|
675
|
+
matches: "matches";
|
|
676
|
+
notMatches: "notMatches";
|
|
677
|
+
portableMatches: "portableMatches";
|
|
678
|
+
portableNotMatches: "portableNotMatches";
|
|
679
|
+
}>;
|
|
680
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
681
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
682
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
683
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
684
|
+
op: z.ZodEnum<{
|
|
685
|
+
in: "in";
|
|
686
|
+
notIn: "notIn";
|
|
687
|
+
}>;
|
|
688
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
689
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
690
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
691
|
+
kind: z.ZodLiteral<"exists">;
|
|
692
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
693
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
694
|
+
kind: z.ZodLiteral<"some">;
|
|
695
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
696
|
+
item: typeof PredicateNodeSchema;
|
|
697
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
698
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
699
|
+
kind: z.ZodLiteral<"every">;
|
|
700
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
701
|
+
item: typeof PredicateNodeSchema;
|
|
702
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
703
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
704
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
705
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
706
|
+
}, z.core.$strip>], "kind">]>;
|
|
707
|
+
}, z.core.$strict>]>>;
|
|
372
708
|
preference: z.ZodOptional<z.ZodEnum<{
|
|
373
709
|
score: "score";
|
|
374
710
|
listed: "listed";
|
|
@@ -379,13 +715,78 @@ type Pool = z.infer<typeof PoolSchema>;
|
|
|
379
715
|
declare const DirectoryRuleSchema: z.ZodObject<{
|
|
380
716
|
entries: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodObject<{
|
|
381
717
|
value: z.ZodBoolean;
|
|
382
|
-
when: z.ZodObject<{
|
|
718
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
383
719
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
384
720
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
385
721
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
386
722
|
branch: z.ZodOptional<z.ZodString>;
|
|
387
723
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
388
|
-
}, z.core.$strict
|
|
724
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
725
|
+
kind: z.ZodLiteral<"not">;
|
|
726
|
+
operand: typeof PredicateNodeSchema;
|
|
727
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
728
|
+
kind: z.ZodLiteral<"and">;
|
|
729
|
+
left: typeof PredicateNodeSchema;
|
|
730
|
+
right: typeof PredicateNodeSchema;
|
|
731
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
732
|
+
kind: z.ZodLiteral<"or">;
|
|
733
|
+
left: typeof PredicateNodeSchema;
|
|
734
|
+
right: typeof PredicateNodeSchema;
|
|
735
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
736
|
+
kind: z.ZodLiteral<"allOf">;
|
|
737
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
738
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
739
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
740
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
741
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
742
|
+
kind: z.ZodLiteral<"compare">;
|
|
743
|
+
op: z.ZodEnum<{
|
|
744
|
+
gt: "gt";
|
|
745
|
+
gte: "gte";
|
|
746
|
+
lt: "lt";
|
|
747
|
+
lte: "lte";
|
|
748
|
+
eq: "eq";
|
|
749
|
+
neq: "neq";
|
|
750
|
+
}>;
|
|
751
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
752
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
753
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
754
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
755
|
+
op: z.ZodEnum<{
|
|
756
|
+
equals: "equals";
|
|
757
|
+
notEquals: "notEquals";
|
|
758
|
+
matches: "matches";
|
|
759
|
+
notMatches: "notMatches";
|
|
760
|
+
portableMatches: "portableMatches";
|
|
761
|
+
portableNotMatches: "portableNotMatches";
|
|
762
|
+
}>;
|
|
763
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
764
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
765
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
766
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
767
|
+
op: z.ZodEnum<{
|
|
768
|
+
in: "in";
|
|
769
|
+
notIn: "notIn";
|
|
770
|
+
}>;
|
|
771
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
772
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
773
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
774
|
+
kind: z.ZodLiteral<"exists">;
|
|
775
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
776
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
777
|
+
kind: z.ZodLiteral<"some">;
|
|
778
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
779
|
+
item: typeof PredicateNodeSchema;
|
|
780
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
781
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
782
|
+
kind: z.ZodLiteral<"every">;
|
|
783
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
784
|
+
item: typeof PredicateNodeSchema;
|
|
785
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
786
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
787
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
788
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
789
|
+
}, z.core.$strip>], "kind">]>;
|
|
389
790
|
}, z.core.$strict>]>>>;
|
|
390
791
|
launch: z.ZodOptional<z.ZodObject<{
|
|
391
792
|
skipPermissions: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -413,13 +814,78 @@ declare const DirectoryRuleSchema: z.ZodObject<{
|
|
|
413
814
|
path: z.ZodString;
|
|
414
815
|
configProfile: z.ZodOptional<z.ZodString>;
|
|
415
816
|
identity: z.ZodOptional<z.ZodString>;
|
|
416
|
-
when: z.ZodOptional<z.ZodObject<{
|
|
817
|
+
when: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
417
818
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
418
819
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
419
820
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
420
821
|
branch: z.ZodOptional<z.ZodString>;
|
|
421
822
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
422
|
-
}, z.core.$strict
|
|
823
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
824
|
+
kind: z.ZodLiteral<"not">;
|
|
825
|
+
operand: typeof PredicateNodeSchema;
|
|
826
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
827
|
+
kind: z.ZodLiteral<"and">;
|
|
828
|
+
left: typeof PredicateNodeSchema;
|
|
829
|
+
right: typeof PredicateNodeSchema;
|
|
830
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
831
|
+
kind: z.ZodLiteral<"or">;
|
|
832
|
+
left: typeof PredicateNodeSchema;
|
|
833
|
+
right: typeof PredicateNodeSchema;
|
|
834
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
835
|
+
kind: z.ZodLiteral<"allOf">;
|
|
836
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
837
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
838
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
839
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
840
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
841
|
+
kind: z.ZodLiteral<"compare">;
|
|
842
|
+
op: z.ZodEnum<{
|
|
843
|
+
gt: "gt";
|
|
844
|
+
gte: "gte";
|
|
845
|
+
lt: "lt";
|
|
846
|
+
lte: "lte";
|
|
847
|
+
eq: "eq";
|
|
848
|
+
neq: "neq";
|
|
849
|
+
}>;
|
|
850
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
851
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
852
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
853
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
854
|
+
op: z.ZodEnum<{
|
|
855
|
+
equals: "equals";
|
|
856
|
+
notEquals: "notEquals";
|
|
857
|
+
matches: "matches";
|
|
858
|
+
notMatches: "notMatches";
|
|
859
|
+
portableMatches: "portableMatches";
|
|
860
|
+
portableNotMatches: "portableNotMatches";
|
|
861
|
+
}>;
|
|
862
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
863
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
864
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
865
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
866
|
+
op: z.ZodEnum<{
|
|
867
|
+
in: "in";
|
|
868
|
+
notIn: "notIn";
|
|
869
|
+
}>;
|
|
870
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
871
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
872
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
873
|
+
kind: z.ZodLiteral<"exists">;
|
|
874
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
875
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
876
|
+
kind: z.ZodLiteral<"some">;
|
|
877
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
878
|
+
item: typeof PredicateNodeSchema;
|
|
879
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
880
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
881
|
+
kind: z.ZodLiteral<"every">;
|
|
882
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
883
|
+
item: typeof PredicateNodeSchema;
|
|
884
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
885
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
886
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
887
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
888
|
+
}, z.core.$strip>], "kind">]>>;
|
|
423
889
|
}, z.core.$strict>;
|
|
424
890
|
type DirectoryRule = z.infer<typeof DirectoryRuleSchema>;
|
|
425
891
|
/** The `~/.agent-shim/directory-rules.json` file. */
|
|
@@ -428,13 +894,78 @@ declare const DirectoryRulesSchema: z.ZodObject<{
|
|
|
428
894
|
rules: z.ZodArray<z.ZodObject<{
|
|
429
895
|
entries: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodObject<{
|
|
430
896
|
value: z.ZodBoolean;
|
|
431
|
-
when: z.ZodObject<{
|
|
897
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
432
898
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
433
899
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
434
900
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
435
901
|
branch: z.ZodOptional<z.ZodString>;
|
|
436
902
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
437
|
-
}, z.core.$strict
|
|
903
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
904
|
+
kind: z.ZodLiteral<"not">;
|
|
905
|
+
operand: typeof PredicateNodeSchema;
|
|
906
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
907
|
+
kind: z.ZodLiteral<"and">;
|
|
908
|
+
left: typeof PredicateNodeSchema;
|
|
909
|
+
right: typeof PredicateNodeSchema;
|
|
910
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
911
|
+
kind: z.ZodLiteral<"or">;
|
|
912
|
+
left: typeof PredicateNodeSchema;
|
|
913
|
+
right: typeof PredicateNodeSchema;
|
|
914
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
915
|
+
kind: z.ZodLiteral<"allOf">;
|
|
916
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
917
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
918
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
919
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
920
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
921
|
+
kind: z.ZodLiteral<"compare">;
|
|
922
|
+
op: z.ZodEnum<{
|
|
923
|
+
gt: "gt";
|
|
924
|
+
gte: "gte";
|
|
925
|
+
lt: "lt";
|
|
926
|
+
lte: "lte";
|
|
927
|
+
eq: "eq";
|
|
928
|
+
neq: "neq";
|
|
929
|
+
}>;
|
|
930
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
931
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
932
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
933
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
934
|
+
op: z.ZodEnum<{
|
|
935
|
+
equals: "equals";
|
|
936
|
+
notEquals: "notEquals";
|
|
937
|
+
matches: "matches";
|
|
938
|
+
notMatches: "notMatches";
|
|
939
|
+
portableMatches: "portableMatches";
|
|
940
|
+
portableNotMatches: "portableNotMatches";
|
|
941
|
+
}>;
|
|
942
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
943
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
944
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
945
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
946
|
+
op: z.ZodEnum<{
|
|
947
|
+
in: "in";
|
|
948
|
+
notIn: "notIn";
|
|
949
|
+
}>;
|
|
950
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
951
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
952
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
953
|
+
kind: z.ZodLiteral<"exists">;
|
|
954
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
955
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
956
|
+
kind: z.ZodLiteral<"some">;
|
|
957
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
958
|
+
item: typeof PredicateNodeSchema;
|
|
959
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
960
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
961
|
+
kind: z.ZodLiteral<"every">;
|
|
962
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
963
|
+
item: typeof PredicateNodeSchema;
|
|
964
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
965
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
966
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
967
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
968
|
+
}, z.core.$strip>], "kind">]>;
|
|
438
969
|
}, z.core.$strict>]>>>;
|
|
439
970
|
launch: z.ZodOptional<z.ZodObject<{
|
|
440
971
|
skipPermissions: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -462,13 +993,78 @@ declare const DirectoryRulesSchema: z.ZodObject<{
|
|
|
462
993
|
path: z.ZodString;
|
|
463
994
|
configProfile: z.ZodOptional<z.ZodString>;
|
|
464
995
|
identity: z.ZodOptional<z.ZodString>;
|
|
465
|
-
when: z.ZodOptional<z.ZodObject<{
|
|
996
|
+
when: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
466
997
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
467
998
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
468
999
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
469
1000
|
branch: z.ZodOptional<z.ZodString>;
|
|
470
1001
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
471
|
-
}, z.core.$strict
|
|
1002
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1003
|
+
kind: z.ZodLiteral<"not">;
|
|
1004
|
+
operand: typeof PredicateNodeSchema;
|
|
1005
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1006
|
+
kind: z.ZodLiteral<"and">;
|
|
1007
|
+
left: typeof PredicateNodeSchema;
|
|
1008
|
+
right: typeof PredicateNodeSchema;
|
|
1009
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1010
|
+
kind: z.ZodLiteral<"or">;
|
|
1011
|
+
left: typeof PredicateNodeSchema;
|
|
1012
|
+
right: typeof PredicateNodeSchema;
|
|
1013
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1014
|
+
kind: z.ZodLiteral<"allOf">;
|
|
1015
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1016
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1017
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
1018
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1019
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1020
|
+
kind: z.ZodLiteral<"compare">;
|
|
1021
|
+
op: z.ZodEnum<{
|
|
1022
|
+
gt: "gt";
|
|
1023
|
+
gte: "gte";
|
|
1024
|
+
lt: "lt";
|
|
1025
|
+
lte: "lte";
|
|
1026
|
+
eq: "eq";
|
|
1027
|
+
neq: "neq";
|
|
1028
|
+
}>;
|
|
1029
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1030
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1031
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1032
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
1033
|
+
op: z.ZodEnum<{
|
|
1034
|
+
equals: "equals";
|
|
1035
|
+
notEquals: "notEquals";
|
|
1036
|
+
matches: "matches";
|
|
1037
|
+
notMatches: "notMatches";
|
|
1038
|
+
portableMatches: "portableMatches";
|
|
1039
|
+
portableNotMatches: "portableNotMatches";
|
|
1040
|
+
}>;
|
|
1041
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1042
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1043
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1044
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
1045
|
+
op: z.ZodEnum<{
|
|
1046
|
+
in: "in";
|
|
1047
|
+
notIn: "notIn";
|
|
1048
|
+
}>;
|
|
1049
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1050
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
1051
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1052
|
+
kind: z.ZodLiteral<"exists">;
|
|
1053
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1054
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1055
|
+
kind: z.ZodLiteral<"some">;
|
|
1056
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1057
|
+
item: typeof PredicateNodeSchema;
|
|
1058
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1059
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1060
|
+
kind: z.ZodLiteral<"every">;
|
|
1061
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1062
|
+
item: typeof PredicateNodeSchema;
|
|
1063
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1064
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1065
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
1066
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1067
|
+
}, z.core.$strip>], "kind">]>>;
|
|
472
1068
|
}, z.core.$strict>>;
|
|
473
1069
|
}, z.core.$strict>;
|
|
474
1070
|
type DirectoryRules = z.infer<typeof DirectoryRulesSchema>;
|
|
@@ -478,13 +1074,78 @@ type DirectoryRules = z.infer<typeof DirectoryRulesSchema>;
|
|
|
478
1074
|
declare const PortableConfigSchema: z.ZodObject<{
|
|
479
1075
|
entries: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodObject<{
|
|
480
1076
|
value: z.ZodBoolean;
|
|
481
|
-
when: z.ZodObject<{
|
|
1077
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
482
1078
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
483
1079
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
484
1080
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
485
1081
|
branch: z.ZodOptional<z.ZodString>;
|
|
486
1082
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
487
|
-
}, z.core.$strict
|
|
1083
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1084
|
+
kind: z.ZodLiteral<"not">;
|
|
1085
|
+
operand: typeof PredicateNodeSchema;
|
|
1086
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1087
|
+
kind: z.ZodLiteral<"and">;
|
|
1088
|
+
left: typeof PredicateNodeSchema;
|
|
1089
|
+
right: typeof PredicateNodeSchema;
|
|
1090
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1091
|
+
kind: z.ZodLiteral<"or">;
|
|
1092
|
+
left: typeof PredicateNodeSchema;
|
|
1093
|
+
right: typeof PredicateNodeSchema;
|
|
1094
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1095
|
+
kind: z.ZodLiteral<"allOf">;
|
|
1096
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1097
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1098
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
1099
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1100
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1101
|
+
kind: z.ZodLiteral<"compare">;
|
|
1102
|
+
op: z.ZodEnum<{
|
|
1103
|
+
gt: "gt";
|
|
1104
|
+
gte: "gte";
|
|
1105
|
+
lt: "lt";
|
|
1106
|
+
lte: "lte";
|
|
1107
|
+
eq: "eq";
|
|
1108
|
+
neq: "neq";
|
|
1109
|
+
}>;
|
|
1110
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1111
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1112
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1113
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
1114
|
+
op: z.ZodEnum<{
|
|
1115
|
+
equals: "equals";
|
|
1116
|
+
notEquals: "notEquals";
|
|
1117
|
+
matches: "matches";
|
|
1118
|
+
notMatches: "notMatches";
|
|
1119
|
+
portableMatches: "portableMatches";
|
|
1120
|
+
portableNotMatches: "portableNotMatches";
|
|
1121
|
+
}>;
|
|
1122
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1123
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1124
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1125
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
1126
|
+
op: z.ZodEnum<{
|
|
1127
|
+
in: "in";
|
|
1128
|
+
notIn: "notIn";
|
|
1129
|
+
}>;
|
|
1130
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1131
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
1132
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1133
|
+
kind: z.ZodLiteral<"exists">;
|
|
1134
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1135
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1136
|
+
kind: z.ZodLiteral<"some">;
|
|
1137
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1138
|
+
item: typeof PredicateNodeSchema;
|
|
1139
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1140
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1141
|
+
kind: z.ZodLiteral<"every">;
|
|
1142
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1143
|
+
item: typeof PredicateNodeSchema;
|
|
1144
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1145
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1146
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
1147
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1148
|
+
}, z.core.$strip>], "kind">]>;
|
|
488
1149
|
}, z.core.$strict>]>>>;
|
|
489
1150
|
launch: z.ZodOptional<z.ZodObject<{
|
|
490
1151
|
skipPermissions: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -511,13 +1172,78 @@ declare const PortableConfigSchema: z.ZodObject<{
|
|
|
511
1172
|
}>>>;
|
|
512
1173
|
configProfile: z.ZodOptional<z.ZodString>;
|
|
513
1174
|
identity: z.ZodOptional<z.ZodString>;
|
|
514
|
-
when: z.ZodOptional<z.ZodObject<{
|
|
1175
|
+
when: z.ZodOptional<z.ZodUnion<readonly [z.ZodObject<{
|
|
515
1176
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
516
1177
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
517
1178
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
518
1179
|
branch: z.ZodOptional<z.ZodString>;
|
|
519
1180
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
520
|
-
}, z.core.$strict
|
|
1181
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1182
|
+
kind: z.ZodLiteral<"not">;
|
|
1183
|
+
operand: typeof PredicateNodeSchema;
|
|
1184
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1185
|
+
kind: z.ZodLiteral<"and">;
|
|
1186
|
+
left: typeof PredicateNodeSchema;
|
|
1187
|
+
right: typeof PredicateNodeSchema;
|
|
1188
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1189
|
+
kind: z.ZodLiteral<"or">;
|
|
1190
|
+
left: typeof PredicateNodeSchema;
|
|
1191
|
+
right: typeof PredicateNodeSchema;
|
|
1192
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1193
|
+
kind: z.ZodLiteral<"allOf">;
|
|
1194
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1195
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1196
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
1197
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1198
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1199
|
+
kind: z.ZodLiteral<"compare">;
|
|
1200
|
+
op: z.ZodEnum<{
|
|
1201
|
+
gt: "gt";
|
|
1202
|
+
gte: "gte";
|
|
1203
|
+
lt: "lt";
|
|
1204
|
+
lte: "lte";
|
|
1205
|
+
eq: "eq";
|
|
1206
|
+
neq: "neq";
|
|
1207
|
+
}>;
|
|
1208
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1209
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1210
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1211
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
1212
|
+
op: z.ZodEnum<{
|
|
1213
|
+
equals: "equals";
|
|
1214
|
+
notEquals: "notEquals";
|
|
1215
|
+
matches: "matches";
|
|
1216
|
+
notMatches: "notMatches";
|
|
1217
|
+
portableMatches: "portableMatches";
|
|
1218
|
+
portableNotMatches: "portableNotMatches";
|
|
1219
|
+
}>;
|
|
1220
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1221
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1222
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1223
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
1224
|
+
op: z.ZodEnum<{
|
|
1225
|
+
in: "in";
|
|
1226
|
+
notIn: "notIn";
|
|
1227
|
+
}>;
|
|
1228
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1229
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
1230
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1231
|
+
kind: z.ZodLiteral<"exists">;
|
|
1232
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1233
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1234
|
+
kind: z.ZodLiteral<"some">;
|
|
1235
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1236
|
+
item: typeof PredicateNodeSchema;
|
|
1237
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1238
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1239
|
+
kind: z.ZodLiteral<"every">;
|
|
1240
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1241
|
+
item: typeof PredicateNodeSchema;
|
|
1242
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1243
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1244
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
1245
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1246
|
+
}, z.core.$strip>], "kind">]>>;
|
|
521
1247
|
}, z.core.$strict>;
|
|
522
1248
|
type PortableConfig = z.infer<typeof PortableConfigSchema>;
|
|
523
1249
|
declare const HeadroomGlobalConfigSchema: z.ZodObject<{
|
|
@@ -567,13 +1293,78 @@ declare const GlobalConfigSchema: z.ZodObject<{
|
|
|
567
1293
|
}>>>;
|
|
568
1294
|
entries: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodBoolean, z.ZodObject<{
|
|
569
1295
|
value: z.ZodBoolean;
|
|
570
|
-
when: z.ZodObject<{
|
|
1296
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
571
1297
|
newerThan: z.ZodOptional<z.ZodString>;
|
|
572
1298
|
olderThan: z.ZodOptional<z.ZodString>;
|
|
573
1299
|
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
574
1300
|
branch: z.ZodOptional<z.ZodString>;
|
|
575
1301
|
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
576
|
-
}, z.core.$strict
|
|
1302
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1303
|
+
kind: z.ZodLiteral<"not">;
|
|
1304
|
+
operand: typeof PredicateNodeSchema;
|
|
1305
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1306
|
+
kind: z.ZodLiteral<"and">;
|
|
1307
|
+
left: typeof PredicateNodeSchema;
|
|
1308
|
+
right: typeof PredicateNodeSchema;
|
|
1309
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1310
|
+
kind: z.ZodLiteral<"or">;
|
|
1311
|
+
left: typeof PredicateNodeSchema;
|
|
1312
|
+
right: typeof PredicateNodeSchema;
|
|
1313
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1314
|
+
kind: z.ZodLiteral<"allOf">;
|
|
1315
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1316
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1317
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
1318
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1319
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1320
|
+
kind: z.ZodLiteral<"compare">;
|
|
1321
|
+
op: z.ZodEnum<{
|
|
1322
|
+
gt: "gt";
|
|
1323
|
+
gte: "gte";
|
|
1324
|
+
lt: "lt";
|
|
1325
|
+
lte: "lte";
|
|
1326
|
+
eq: "eq";
|
|
1327
|
+
neq: "neq";
|
|
1328
|
+
}>;
|
|
1329
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1330
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1331
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1332
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
1333
|
+
op: z.ZodEnum<{
|
|
1334
|
+
equals: "equals";
|
|
1335
|
+
notEquals: "notEquals";
|
|
1336
|
+
matches: "matches";
|
|
1337
|
+
notMatches: "notMatches";
|
|
1338
|
+
portableMatches: "portableMatches";
|
|
1339
|
+
portableNotMatches: "portableNotMatches";
|
|
1340
|
+
}>;
|
|
1341
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1342
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1343
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1344
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
1345
|
+
op: z.ZodEnum<{
|
|
1346
|
+
in: "in";
|
|
1347
|
+
notIn: "notIn";
|
|
1348
|
+
}>;
|
|
1349
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1350
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
1351
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1352
|
+
kind: z.ZodLiteral<"exists">;
|
|
1353
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1354
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1355
|
+
kind: z.ZodLiteral<"some">;
|
|
1356
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1357
|
+
item: typeof PredicateNodeSchema;
|
|
1358
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1359
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1360
|
+
kind: z.ZodLiteral<"every">;
|
|
1361
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1362
|
+
item: typeof PredicateNodeSchema;
|
|
1363
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1364
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1365
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
1366
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1367
|
+
}, z.core.$strip>], "kind">]>;
|
|
577
1368
|
}, z.core.$strict>]>>>;
|
|
578
1369
|
launch: z.ZodOptional<z.ZodObject<{
|
|
579
1370
|
skipPermissions: z.ZodOptional<z.ZodBoolean>;
|
|
@@ -615,7 +1406,81 @@ declare const GlobalConfigSchema: z.ZodObject<{
|
|
|
615
1406
|
}>>;
|
|
616
1407
|
}, z.core.$strict>>;
|
|
617
1408
|
pools: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
618
|
-
identities: z.ZodArray<z.ZodString
|
|
1409
|
+
identities: z.ZodArray<z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
1410
|
+
identity: z.ZodString;
|
|
1411
|
+
when: z.ZodUnion<readonly [z.ZodObject<{
|
|
1412
|
+
newerThan: z.ZodOptional<z.ZodString>;
|
|
1413
|
+
olderThan: z.ZodOptional<z.ZodString>;
|
|
1414
|
+
maxSizeBytes: z.ZodOptional<z.ZodInt>;
|
|
1415
|
+
branch: z.ZodOptional<z.ZodString>;
|
|
1416
|
+
env: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
1417
|
+
}, z.core.$strict>, z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
1418
|
+
kind: z.ZodLiteral<"not">;
|
|
1419
|
+
operand: typeof PredicateNodeSchema;
|
|
1420
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1421
|
+
kind: z.ZodLiteral<"and">;
|
|
1422
|
+
left: typeof PredicateNodeSchema;
|
|
1423
|
+
right: typeof PredicateNodeSchema;
|
|
1424
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1425
|
+
kind: z.ZodLiteral<"or">;
|
|
1426
|
+
left: typeof PredicateNodeSchema;
|
|
1427
|
+
right: typeof PredicateNodeSchema;
|
|
1428
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1429
|
+
kind: z.ZodLiteral<"allOf">;
|
|
1430
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1431
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1432
|
+
kind: z.ZodLiteral<"anyOf">;
|
|
1433
|
+
operands: z.ZodArray<typeof PredicateNodeSchema>;
|
|
1434
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1435
|
+
kind: z.ZodLiteral<"compare">;
|
|
1436
|
+
op: z.ZodEnum<{
|
|
1437
|
+
gt: "gt";
|
|
1438
|
+
gte: "gte";
|
|
1439
|
+
lt: "lt";
|
|
1440
|
+
lte: "lte";
|
|
1441
|
+
eq: "eq";
|
|
1442
|
+
neq: "neq";
|
|
1443
|
+
}>;
|
|
1444
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1445
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1446
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1447
|
+
kind: z.ZodLiteral<"textCompare">;
|
|
1448
|
+
op: z.ZodEnum<{
|
|
1449
|
+
equals: "equals";
|
|
1450
|
+
notEquals: "notEquals";
|
|
1451
|
+
matches: "matches";
|
|
1452
|
+
notMatches: "notMatches";
|
|
1453
|
+
portableMatches: "portableMatches";
|
|
1454
|
+
portableNotMatches: "portableNotMatches";
|
|
1455
|
+
}>;
|
|
1456
|
+
left: typeof trilean.ExpressionNodeSchema;
|
|
1457
|
+
right: typeof trilean.ExpressionNodeSchema;
|
|
1458
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1459
|
+
kind: z.ZodLiteral<"memberOf">;
|
|
1460
|
+
op: z.ZodEnum<{
|
|
1461
|
+
in: "in";
|
|
1462
|
+
notIn: "notIn";
|
|
1463
|
+
}>;
|
|
1464
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1465
|
+
candidates: z.ZodArray<typeof trilean.ExpressionNodeSchema>;
|
|
1466
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1467
|
+
kind: z.ZodLiteral<"exists">;
|
|
1468
|
+
operand: typeof trilean.ExpressionNodeSchema;
|
|
1469
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1470
|
+
kind: z.ZodLiteral<"some">;
|
|
1471
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1472
|
+
item: typeof PredicateNodeSchema;
|
|
1473
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1474
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1475
|
+
kind: z.ZodLiteral<"every">;
|
|
1476
|
+
collection: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1477
|
+
item: typeof PredicateNodeSchema;
|
|
1478
|
+
filter: z.ZodOptional<typeof PredicateNodeSchema>;
|
|
1479
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
1480
|
+
kind: z.ZodLiteral<"treeReference">;
|
|
1481
|
+
key: z.ZodType<trilean.JsonValue, unknown, z.core.$ZodTypeInternals<trilean.JsonValue, unknown>>;
|
|
1482
|
+
}, z.core.$strip>], "kind">]>;
|
|
1483
|
+
}, z.core.$strict>]>>;
|
|
619
1484
|
preference: z.ZodOptional<z.ZodEnum<{
|
|
620
1485
|
score: "score";
|
|
621
1486
|
listed: "listed";
|
|
@@ -4513,12 +5378,12 @@ declare function createControlApiRouter(deps: ControlApiDeps): {
|
|
|
4513
5378
|
identity: "identity";
|
|
4514
5379
|
provider: "provider";
|
|
4515
5380
|
pool: "pool";
|
|
4516
|
-
keychain: "keychain";
|
|
4517
5381
|
"ambient-credential": "ambient-credential";
|
|
4518
5382
|
"binary-discovery": "binary-discovery";
|
|
4519
5383
|
"claude-shim": "claude-shim";
|
|
4520
5384
|
"path-resolution": "path-resolution";
|
|
4521
5385
|
"legacy-name": "legacy-name";
|
|
5386
|
+
keychain: "keychain";
|
|
4522
5387
|
"directory-rules": "directory-rules";
|
|
4523
5388
|
"categories-local": "categories-local";
|
|
4524
5389
|
"active-identity": "active-identity";
|
|
@@ -5094,12 +5959,12 @@ declare function createDoorApiRouter(deps: DoorApiDeps): {
|
|
|
5094
5959
|
identity: "identity";
|
|
5095
5960
|
provider: "provider";
|
|
5096
5961
|
pool: "pool";
|
|
5097
|
-
keychain: "keychain";
|
|
5098
5962
|
"ambient-credential": "ambient-credential";
|
|
5099
5963
|
"binary-discovery": "binary-discovery";
|
|
5100
5964
|
"claude-shim": "claude-shim";
|
|
5101
5965
|
"path-resolution": "path-resolution";
|
|
5102
5966
|
"legacy-name": "legacy-name";
|
|
5967
|
+
keychain: "keychain";
|
|
5103
5968
|
"directory-rules": "directory-rules";
|
|
5104
5969
|
"categories-local": "categories-local";
|
|
5105
5970
|
"active-identity": "active-identity";
|
|
@@ -5584,12 +6449,12 @@ declare const DoctorFindingSchema: z.ZodObject<{
|
|
|
5584
6449
|
identity: "identity";
|
|
5585
6450
|
provider: "provider";
|
|
5586
6451
|
pool: "pool";
|
|
5587
|
-
keychain: "keychain";
|
|
5588
6452
|
"ambient-credential": "ambient-credential";
|
|
5589
6453
|
"binary-discovery": "binary-discovery";
|
|
5590
6454
|
"claude-shim": "claude-shim";
|
|
5591
6455
|
"path-resolution": "path-resolution";
|
|
5592
6456
|
"legacy-name": "legacy-name";
|
|
6457
|
+
keychain: "keychain";
|
|
5593
6458
|
"directory-rules": "directory-rules";
|
|
5594
6459
|
"categories-local": "categories-local";
|
|
5595
6460
|
"active-identity": "active-identity";
|
|
@@ -5613,12 +6478,12 @@ declare const DoctorRunOutputSchema: z.ZodObject<{
|
|
|
5613
6478
|
identity: "identity";
|
|
5614
6479
|
provider: "provider";
|
|
5615
6480
|
pool: "pool";
|
|
5616
|
-
keychain: "keychain";
|
|
5617
6481
|
"ambient-credential": "ambient-credential";
|
|
5618
6482
|
"binary-discovery": "binary-discovery";
|
|
5619
6483
|
"claude-shim": "claude-shim";
|
|
5620
6484
|
"path-resolution": "path-resolution";
|
|
5621
6485
|
"legacy-name": "legacy-name";
|
|
6486
|
+
keychain: "keychain";
|
|
5622
6487
|
"directory-rules": "directory-rules";
|
|
5623
6488
|
"categories-local": "categories-local";
|
|
5624
6489
|
"active-identity": "active-identity";
|
|
@@ -6067,6 +6932,8 @@ interface PoolMember {
|
|
|
6067
6932
|
readonly records: readonly UsageRecord[];
|
|
6068
6933
|
/** Present when this member stands for a nested `pool:<name>` entry rather than a direct identity. */
|
|
6069
6934
|
readonly nested?: NestedContribution;
|
|
6935
|
+
/** The member entry's policy condition, from the object form of a pool member: definite false skips the member as ineligible by policy, indeterminate demotes it to last within its class, naming the missing fact either way. */
|
|
6936
|
+
readonly policy?: WhenCondition;
|
|
6070
6937
|
}
|
|
6071
6938
|
/** The member last picked for this directory, kept so a conversation stays on the account whose prompt cache is warm. */
|
|
6072
6939
|
interface StickyPick {
|
|
@@ -6094,6 +6961,8 @@ interface Candidate {
|
|
|
6094
6961
|
/** When an `ineligible` candidate can be used again. */
|
|
6095
6962
|
readonly blockedUntilMs?: number;
|
|
6096
6963
|
readonly plan: PlanClass;
|
|
6964
|
+
/** True when the member's policy condition could not be decided and it is ranked last within its class, naming the missing fact in its reasons. */
|
|
6965
|
+
readonly policyDemoted?: boolean;
|
|
6097
6966
|
/** Human-readable facts behind the class and score, in the order they matter. */
|
|
6098
6967
|
readonly reasons: readonly string[];
|
|
6099
6968
|
}
|
|
@@ -6135,6 +7004,15 @@ declare function collectPoolPick(params: Readonly<{
|
|
|
6135
7004
|
nowMs: number;
|
|
6136
7005
|
}>): PoolPickReport;
|
|
6137
7006
|
|
|
7007
|
+
/** One quota window's pool-selection facts, in the units a policy reads: fractions of the window, and hours until it resets. */
|
|
7008
|
+
interface PoolWindowFacts {
|
|
7009
|
+
/** The fraction of the window still unused, between zero and one. */
|
|
7010
|
+
readonly remaining: number;
|
|
7011
|
+
/** The fraction of the window already used, between zero and one. */
|
|
7012
|
+
readonly utilization: number;
|
|
7013
|
+
/** How long until the window resets, in hours. */
|
|
7014
|
+
readonly hoursUntilReset: number;
|
|
7015
|
+
}
|
|
6138
7016
|
/** Everything a `when` condition can be evaluated against, injected rather than read. */
|
|
6139
7017
|
interface ConditionContext {
|
|
6140
7018
|
readonly nowMs: number;
|
|
@@ -6145,21 +7023,38 @@ interface ConditionContext {
|
|
|
6145
7023
|
/** True when the repository is in detached-HEAD state, in which case no `branch` condition can match. */
|
|
6146
7024
|
readonly branchDetached?: boolean;
|
|
6147
7025
|
readonly env: Readonly<Record<string, string | undefined>>;
|
|
7026
|
+
/**
|
|
7027
|
+
* The pool-selection facts a member entry's policy condition reads. Present only when the condition guards a pool member, so the same reference namespace serves the cascade and the pool: `quota.fiveHour.remaining`, `quota.fiveHour.utilization`, `quota.fiveHour.hoursUntilReset`, the same three under `quota.sevenDay`, `quota.burnPerHour` (the five-hour window's observed utilisation pace, in fractions per hour), `session.resuming` (this launch resumes or continues a conversation) and `session.lastPickHoursAgo` (how long ago this directory last picked this member). Conversation context is deliberately not provided: nothing the door holds knows it, so a condition referencing it is indeterminate, naming the missing fact, rather than guessed.
|
|
7028
|
+
*/
|
|
7029
|
+
readonly pool?: {
|
|
7030
|
+
readonly fiveHour?: PoolWindowFacts;
|
|
7031
|
+
readonly sevenDay?: PoolWindowFacts;
|
|
7032
|
+
readonly burnPerHour?: number;
|
|
7033
|
+
readonly resuming?: boolean;
|
|
7034
|
+
readonly lastPickHoursAgo?: number;
|
|
7035
|
+
};
|
|
6148
7036
|
}
|
|
6149
|
-
/**
|
|
6150
|
-
|
|
6151
|
-
|
|
6152
|
-
|
|
6153
|
-
readonly
|
|
6154
|
-
/** Which
|
|
7037
|
+
/**
|
|
7038
|
+
* The result of evaluating one `when`: definite, with which condition fields were present and which of those did not hold, or indeterminate, when a datum the condition needed is missing. Indeterminate is not false: a missing fact has not failed the condition, it has left it undecided, and the consumer decides what an undecided entry does (the resolver keeps today's behaviour of not passing it, so nothing changes for existing configurations; the pool ranking of #258 instead keeps such a member but ranks it last, naming the missing fact).
|
|
7039
|
+
*/
|
|
7040
|
+
type WhenEvaluation = {
|
|
7041
|
+
readonly status: "definite";
|
|
7042
|
+
readonly passed: boolean; /** Which condition fields were present and evaluated. */
|
|
7043
|
+
readonly checked: readonly string[]; /** Which of those fields did not hold. Empty when `passed` is true. */
|
|
6155
7044
|
readonly failed: readonly string[];
|
|
6156
|
-
}
|
|
7045
|
+
} | {
|
|
7046
|
+
readonly status: "indeterminate"; /** What was missing or wrong, in the evaluation's own words. */
|
|
7047
|
+
readonly reason: string;
|
|
7048
|
+
readonly checked: readonly string[];
|
|
7049
|
+
};
|
|
6157
7050
|
/** True when `branch` matches `pattern`. The pattern is glob-capable (`client/*`); a detached HEAD or a non-repository directory never matches. */
|
|
6158
7051
|
declare function matchBranch(pattern: string, branch: string | undefined, detached?: boolean): boolean;
|
|
6159
7052
|
/**
|
|
6160
|
-
* Evaluates a `when
|
|
7053
|
+
* Evaluates a `when`, in either of its two forms.
|
|
6161
7054
|
*
|
|
6162
|
-
*
|
|
7055
|
+
* The object form (`newerThan`, `olderThan`, `maxSizeBytes`, `branch`, `env`) is the original configuration sugar: every present field must hold, which is the AND of the field predicates above. It is kept unchanged, so no configuration migrates, and its per-field reporting (`checked`, `failed`) survives exactly as before.
|
|
7056
|
+
*
|
|
7057
|
+
* The predicate form is a trilean predicate tree, evaluated by the package's own synchronous evaluator over the reference namespace `resolversOf` documents: `and`/`or`/`not` compose, comparisons and text matches read the facts, and a reference the context cannot answer makes the evaluation indeterminate rather than false. A predicate form is reported as one condition (`checked: ["predicate"]`), because a tree has no per-field breakdown to give.
|
|
6163
7058
|
*
|
|
6164
7059
|
* `newerThan`, `olderThan`, and `maxSizeBytes` read the subtree-aggregated facts (`latestMtimeMs`, `totalSizeBytes`), never the entry's own inode stat: a directory's own mtime does not change when a file three levels beneath it is rewritten, and its own size is a ~4KB inode figure that says nothing about what it contains.
|
|
6165
7060
|
*/
|
|
@@ -6491,6 +7386,9 @@ declare function updateProvider(paths: LayoutPaths, name: string, input: UpdateP
|
|
|
6491
7386
|
/** Deletes a provider definition. Throws `ProviderNotFoundError` when it does not exist. */
|
|
6492
7387
|
declare function removeProvider(paths: LayoutPaths, name: string): void;
|
|
6493
7388
|
|
|
7389
|
+
/** One pool member entry, whichever form it takes: the plain selector string, or the object form carrying its policy condition. */
|
|
7390
|
+
type PoolMemberEntry = Pool["identities"][number];
|
|
7391
|
+
|
|
6494
7392
|
/** Raised when a command names a pool that is not defined in the global config. */
|
|
6495
7393
|
declare class PoolNotFoundError extends CliError {
|
|
6496
7394
|
readonly poolName: string;
|
|
@@ -6501,9 +7399,9 @@ declare function readPools(paths: LayoutPaths): Readonly<Record<string, Pool>>;
|
|
|
6501
7399
|
/** The pool named `name`; throws `PoolNotFoundError` when none is defined. */
|
|
6502
7400
|
declare function requirePool(paths: LayoutPaths, name: string): Pool;
|
|
6503
7401
|
/** Defines a new pool. Throws `InvalidPoolNameError` for a name `PoolNameSchema` rejects, `PoolAlreadyExistsError` for one already defined, and `UsageError` for a nested member that names an undefined pool or a cycle. */
|
|
6504
|
-
declare function addPool(paths: LayoutPaths, name: string, identities: readonly
|
|
7402
|
+
declare function addPool(paths: LayoutPaths, name: string, identities: readonly PoolMemberEntry[], preference?: PoolPreference): Pool;
|
|
6505
7403
|
/** Replaces an existing pool's members and preference. Throws `PoolNotFoundError` when it is not defined, and `UsageError` for a nested member that names an undefined pool or a cycle. */
|
|
6506
|
-
declare function setPool(paths: LayoutPaths, name: string, identities: readonly
|
|
7404
|
+
declare function setPool(paths: LayoutPaths, name: string, identities: readonly PoolMemberEntry[], preference?: PoolPreference): Pool;
|
|
6507
7405
|
/** Removes a pool. Throws `PoolNotFoundError` when it is not defined. Anything that selected it (an active-identity file, a directory rule) is left for `doctor` to report, as with a removed identity. */
|
|
6508
7406
|
declare function removePool(paths: LayoutPaths, name: string): void;
|
|
6509
7407
|
|