tegami 1.1.0 → 1.1.2
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/_accessExpressionAsString-QhbUZzwv.js +44 -0
- package/dist/_assertGuard-BBn2NbSz.js +91 -0
- package/dist/_createStandardSchema-BGQyz-uA.js +89 -0
- package/dist/cli/index.d.ts +1 -1
- package/dist/cli/index.js +2 -2
- package/dist/{draft-BLbt4bSG.js → draft-CzUiQasJ.js} +168 -37
- package/dist/{generate-Rvz4Lu98.js → generate-Bg86OJP4.js} +1 -1
- package/dist/generators/simple.d.ts +1 -1
- package/dist/index.d.ts +1 -1
- package/dist/index.js +3 -3
- package/dist/npm-DoPhFKji.js +1252 -0
- package/dist/plugins/cargo.d.ts +1 -1
- package/dist/plugins/cargo.js +491 -66
- package/dist/plugins/git.d.ts +1 -1
- package/dist/plugins/github.d.ts +1 -1
- package/dist/plugins/github.js +39 -12
- package/dist/plugins/gitlab.d.ts +1 -1
- package/dist/plugins/gitlab.js +2 -2
- package/dist/plugins/go.d.ts +1 -1
- package/dist/plugins/go.js +243 -28
- package/dist/providers/npm.d.ts +2 -2
- package/dist/providers/npm.js +1 -1
- package/dist/shared-C_iSTp_s.js +115 -0
- package/dist/{types-BoQR7Hlg.d.ts → types-B50RK1rR.d.ts} +295 -406
- package/package.json +7 -3
- package/dist/npm-Cj685Ddn.js +0 -681
- package/dist/shared-C92toqVI.js +0 -32
|
@@ -1,19 +1,159 @@
|
|
|
1
|
-
import z from "zod";
|
|
2
1
|
import { AgentName } from "package-manager-detector";
|
|
3
2
|
|
|
4
3
|
//#region src/utils/semver.d.ts
|
|
5
4
|
type BumpType = "major" | "minor" | "patch";
|
|
6
5
|
//#endregion
|
|
6
|
+
//#region ../../node_modules/.pnpm/@typia+interface@12.1.1/node_modules/@typia/interface/lib/tags/TagBase.d.ts
|
|
7
|
+
/**
|
|
8
|
+
* Base type for all typia validation tags.
|
|
9
|
+
*
|
|
10
|
+
* `TagBase` is the foundation for all typia type tags (constraints like
|
|
11
|
+
* `Minimum`, `MaxLength`, `Format`, etc.). It attaches compile-time metadata to
|
|
12
|
+
* TypeScript types using a phantom property pattern.
|
|
13
|
+
*
|
|
14
|
+
* The typia transformer reads these tags at compile time and generates
|
|
15
|
+
* appropriate runtime validation code. The tags themselves have no runtime
|
|
16
|
+
* presence - they exist only in the type system.
|
|
17
|
+
*
|
|
18
|
+
* This is an internal implementation detail. Use the specific tag types (e.g.,
|
|
19
|
+
* {@link Minimum}, {@link Format}, {@link Pattern}) rather than `TagBase`
|
|
20
|
+
* directly.
|
|
21
|
+
*
|
|
22
|
+
* @author Jeongho Nam - https://github.com/samchon
|
|
23
|
+
* @template Props Tag properties defining validation behavior and schema output
|
|
24
|
+
*/
|
|
25
|
+
type TagBase<Props extends TagBase.IProps<any, any, any, any, any, any>> = {
|
|
26
|
+
/**
|
|
27
|
+
* Compile-time marker property for typia transformer.
|
|
28
|
+
*
|
|
29
|
+
* This phantom property carries tag metadata in the type system. It is never
|
|
30
|
+
* assigned at runtime - it exists only for the transformer to read during
|
|
31
|
+
* compilation.
|
|
32
|
+
*/
|
|
33
|
+
"typia.tag"?: Props;
|
|
34
|
+
};
|
|
35
|
+
declare namespace TagBase {
|
|
36
|
+
/**
|
|
37
|
+
* Configuration interface for validation tag properties.
|
|
38
|
+
*
|
|
39
|
+
* Defines all the metadata a validation tag can specify, including what types
|
|
40
|
+
* it applies to, how to validate values, and what to output in JSON Schema.
|
|
41
|
+
*
|
|
42
|
+
* @template Target Which primitive type(s) this tag can be applied to
|
|
43
|
+
* @template Kind Unique identifier for this tag type
|
|
44
|
+
* @template Value The constraint value specified by the user
|
|
45
|
+
* @template Validate The validation expression to generate
|
|
46
|
+
* @template Exclusive Whether this tag conflicts with others
|
|
47
|
+
* @template Schema Additional JSON Schema properties to output
|
|
48
|
+
*/
|
|
49
|
+
interface IProps<Target extends "boolean" | "bigint" | "number" | "string" | "array" | "object", Kind extends string, Value extends boolean | bigint | number | string | undefined, Validate extends string | { [key in Target]?: string }, Exclusive extends boolean | string[], Schema extends object | undefined> {
|
|
50
|
+
/**
|
|
51
|
+
* Target primitive type(s) this tag applies to.
|
|
52
|
+
*
|
|
53
|
+
* The transformer will error if the tag is applied to a property of a
|
|
54
|
+
* different type. For example, `MinLength` targets `"string"` and cannot be
|
|
55
|
+
* applied to numbers.
|
|
56
|
+
*/
|
|
57
|
+
target: Target;
|
|
58
|
+
/**
|
|
59
|
+
* Unique identifier for this tag type.
|
|
60
|
+
*
|
|
61
|
+
* Used internally to identify the constraint kind. Examples: `"minimum"`,
|
|
62
|
+
* `"maxLength"`, `"format"`, `"pattern"`.
|
|
63
|
+
*/
|
|
64
|
+
kind: Kind;
|
|
65
|
+
/**
|
|
66
|
+
* User-configured constraint value.
|
|
67
|
+
*
|
|
68
|
+
* The value provided by the user when applying the tag. For `Minimum<5>`,
|
|
69
|
+
* this would be `5`. For `Format<"email">`, this would be `"email"`.
|
|
70
|
+
*/
|
|
71
|
+
value: Value;
|
|
72
|
+
/**
|
|
73
|
+
* Validation expression template.
|
|
74
|
+
*
|
|
75
|
+
* JavaScript expression string that validates the input value. Use `$input`
|
|
76
|
+
* as a placeholder for the actual value. The expression is inserted into
|
|
77
|
+
* the generated validation function.
|
|
78
|
+
*
|
|
79
|
+
* Can be a single string or an object mapping target types to different
|
|
80
|
+
* expressions (for tags supporting multiple types).
|
|
81
|
+
*
|
|
82
|
+
* @example
|
|
83
|
+
* `"5 <= $input"`; // For Minimum<5>
|
|
84
|
+
*
|
|
85
|
+
* @example
|
|
86
|
+
* `"$input.length <= 10"`; // For MaxLength<10>
|
|
87
|
+
*/
|
|
88
|
+
validate?: Validate;
|
|
89
|
+
/**
|
|
90
|
+
* Tag exclusivity configuration.
|
|
91
|
+
*
|
|
92
|
+
* Controls which other tags cannot be combined with this one:
|
|
93
|
+
*
|
|
94
|
+
* - `true`: No duplicate tags of the same kind allowed
|
|
95
|
+
* - `string[]`: List of incompatible tag kinds
|
|
96
|
+
* - `false` (default): No exclusivity restrictions
|
|
97
|
+
*
|
|
98
|
+
* For example, `Minimum` and `ExclusiveMinimum` are mutually exclusive -
|
|
99
|
+
* only one can be applied to a property.
|
|
100
|
+
*
|
|
101
|
+
* @default false
|
|
102
|
+
*/
|
|
103
|
+
exclusive?: Exclusive | string[];
|
|
104
|
+
/**
|
|
105
|
+
* Additional JSON Schema properties to output.
|
|
106
|
+
*
|
|
107
|
+
* Object containing schema properties to merge into the generated JSON
|
|
108
|
+
* Schema for the annotated type. For `Minimum<5>`, this would be `{
|
|
109
|
+
* minimum: 5 }`.
|
|
110
|
+
*/
|
|
111
|
+
schema?: Schema;
|
|
112
|
+
}
|
|
113
|
+
}
|
|
114
|
+
//#endregion
|
|
115
|
+
//#region ../../node_modules/.pnpm/@typia+interface@12.1.1/node_modules/@typia/interface/lib/tags/MinLength.d.ts
|
|
116
|
+
/**
|
|
117
|
+
* String minimum length constraint.
|
|
118
|
+
*
|
|
119
|
+
* `MinLength<N>` is a type tag that validates string values have at least the
|
|
120
|
+
* specified number of characters. Apply it to `string` properties using
|
|
121
|
+
* TypeScript intersection types.
|
|
122
|
+
*
|
|
123
|
+
* This constraint is commonly combined with {@link MaxLength} to define a valid
|
|
124
|
+
* length range. Multiple length constraints can be applied to the same property
|
|
125
|
+
* (all must pass).
|
|
126
|
+
*
|
|
127
|
+
* The constraint is enforced at runtime by `typia.is()`, `typia.assert()`, and
|
|
128
|
+
* `typia.validate()`. It generates `minLength` in JSON Schema output.
|
|
129
|
+
*
|
|
130
|
+
* @author Jeongho Nam - https://github.com/samchon
|
|
131
|
+
* @example
|
|
132
|
+
* interface User {
|
|
133
|
+
* // Username must be at least 3 characters
|
|
134
|
+
* username: string & MinLength<3> & MaxLength<20>;
|
|
135
|
+
* // Password must be at least 8 characters
|
|
136
|
+
* password: string & MinLength<8>;
|
|
137
|
+
* }
|
|
138
|
+
*
|
|
139
|
+
* @template Value Minimum number of characters required
|
|
140
|
+
*/
|
|
141
|
+
type MinLength<Value extends number> = TagBase<{
|
|
142
|
+
target: "string";
|
|
143
|
+
kind: "minLength";
|
|
144
|
+
value: Value;
|
|
145
|
+
validate: `${Value} <= $input.length`;
|
|
146
|
+
exclusive: true;
|
|
147
|
+
schema: {
|
|
148
|
+
minLength: Value;
|
|
149
|
+
};
|
|
150
|
+
}>;
|
|
151
|
+
//#endregion
|
|
7
152
|
//#region src/changelog/shared.d.ts
|
|
8
|
-
|
|
9
|
-
type
|
|
10
|
-
|
|
11
|
-
|
|
12
|
-
patch: "patch";
|
|
13
|
-
}>>;
|
|
14
|
-
replay: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
15
|
-
}, z.core.$strip>;
|
|
16
|
-
type ChangelogPackageConfig = z.output<typeof changelogPackageConfigSchema>;
|
|
153
|
+
interface ChangelogPackageConfig {
|
|
154
|
+
type?: BumpType;
|
|
155
|
+
replay?: (string & MinLength<1>)[];
|
|
156
|
+
}
|
|
17
157
|
//#endregion
|
|
18
158
|
//#region src/changelog/parse.d.ts
|
|
19
159
|
interface ChangelogEntry {
|
|
@@ -154,342 +294,62 @@ interface GitLabToken {
|
|
|
154
294
|
}
|
|
155
295
|
//#endregion
|
|
156
296
|
//#region src/plugins/cargo/schema.d.ts
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
"
|
|
188
|
-
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
version
|
|
195
|
-
|
|
196
|
-
|
|
197
|
-
|
|
198
|
-
|
|
199
|
-
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
203
|
-
|
|
204
|
-
|
|
205
|
-
|
|
206
|
-
|
|
207
|
-
|
|
208
|
-
|
|
209
|
-
|
|
210
|
-
|
|
211
|
-
|
|
212
|
-
|
|
213
|
-
workspace: z.ZodLiteral<true>;
|
|
214
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
215
|
-
package: z.ZodOptional<z.ZodString>;
|
|
216
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
217
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
218
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
219
|
-
path: z.ZodString;
|
|
220
|
-
version: z.ZodOptional<z.ZodString>;
|
|
221
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
222
|
-
package: z.ZodOptional<z.ZodString>;
|
|
223
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
224
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
225
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
226
|
-
git: z.ZodString;
|
|
227
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
228
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
229
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
230
|
-
version: z.ZodOptional<z.ZodString>;
|
|
231
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
232
|
-
package: z.ZodOptional<z.ZodString>;
|
|
233
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
234
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
235
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
236
|
-
version: z.ZodString;
|
|
237
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
238
|
-
}, z.core.$strip>]>>>;
|
|
239
|
-
"dev-dependencies": z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
240
|
-
package: z.ZodOptional<z.ZodString>;
|
|
241
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
242
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
243
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
244
|
-
workspace: z.ZodLiteral<true>;
|
|
245
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
246
|
-
package: z.ZodOptional<z.ZodString>;
|
|
247
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
248
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
249
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
250
|
-
path: z.ZodString;
|
|
251
|
-
version: z.ZodOptional<z.ZodString>;
|
|
252
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
253
|
-
package: z.ZodOptional<z.ZodString>;
|
|
254
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
255
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
256
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
257
|
-
git: z.ZodString;
|
|
258
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
259
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
260
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
261
|
-
version: z.ZodOptional<z.ZodString>;
|
|
262
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
263
|
-
package: z.ZodOptional<z.ZodString>;
|
|
264
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
265
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
266
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
267
|
-
version: z.ZodString;
|
|
268
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
269
|
-
}, z.core.$strip>]>>>;
|
|
270
|
-
"build-dependencies": z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
271
|
-
package: z.ZodOptional<z.ZodString>;
|
|
272
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
273
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
274
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
275
|
-
workspace: z.ZodLiteral<true>;
|
|
276
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
277
|
-
package: z.ZodOptional<z.ZodString>;
|
|
278
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
279
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
280
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
281
|
-
path: z.ZodString;
|
|
282
|
-
version: z.ZodOptional<z.ZodString>;
|
|
283
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
284
|
-
package: z.ZodOptional<z.ZodString>;
|
|
285
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
286
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
287
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
288
|
-
git: z.ZodString;
|
|
289
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
290
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
291
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
292
|
-
version: z.ZodOptional<z.ZodString>;
|
|
293
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
294
|
-
package: z.ZodOptional<z.ZodString>;
|
|
295
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
296
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
297
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
298
|
-
version: z.ZodString;
|
|
299
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
300
|
-
}, z.core.$strip>]>>>;
|
|
301
|
-
}, z.core.$loose>>;
|
|
302
|
-
dependencies: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
303
|
-
package: z.ZodOptional<z.ZodString>;
|
|
304
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
305
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
306
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
307
|
-
workspace: z.ZodLiteral<true>;
|
|
308
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
309
|
-
package: z.ZodOptional<z.ZodString>;
|
|
310
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
311
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
312
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
313
|
-
path: z.ZodString;
|
|
314
|
-
version: z.ZodOptional<z.ZodString>;
|
|
315
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
316
|
-
package: z.ZodOptional<z.ZodString>;
|
|
317
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
318
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
319
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
320
|
-
git: z.ZodString;
|
|
321
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
322
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
323
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
324
|
-
version: z.ZodOptional<z.ZodString>;
|
|
325
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
326
|
-
package: z.ZodOptional<z.ZodString>;
|
|
327
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
328
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
329
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
330
|
-
version: z.ZodString;
|
|
331
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
332
|
-
}, z.core.$strip>]>>>;
|
|
333
|
-
"dev-dependencies": z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
334
|
-
package: z.ZodOptional<z.ZodString>;
|
|
335
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
336
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
337
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
338
|
-
workspace: z.ZodLiteral<true>;
|
|
339
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
340
|
-
package: z.ZodOptional<z.ZodString>;
|
|
341
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
342
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
343
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
344
|
-
path: z.ZodString;
|
|
345
|
-
version: z.ZodOptional<z.ZodString>;
|
|
346
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
347
|
-
package: z.ZodOptional<z.ZodString>;
|
|
348
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
349
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
350
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
351
|
-
git: z.ZodString;
|
|
352
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
353
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
354
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
355
|
-
version: z.ZodOptional<z.ZodString>;
|
|
356
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
357
|
-
package: z.ZodOptional<z.ZodString>;
|
|
358
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
359
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
360
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
361
|
-
version: z.ZodString;
|
|
362
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
363
|
-
}, z.core.$strip>]>>>;
|
|
364
|
-
"build-dependencies": z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
365
|
-
package: z.ZodOptional<z.ZodString>;
|
|
366
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
367
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
368
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
369
|
-
workspace: z.ZodLiteral<true>;
|
|
370
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
371
|
-
package: z.ZodOptional<z.ZodString>;
|
|
372
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
373
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
374
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
375
|
-
path: z.ZodString;
|
|
376
|
-
version: z.ZodOptional<z.ZodString>;
|
|
377
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
378
|
-
package: z.ZodOptional<z.ZodString>;
|
|
379
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
380
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
381
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
382
|
-
git: z.ZodString;
|
|
383
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
384
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
385
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
386
|
-
version: z.ZodOptional<z.ZodString>;
|
|
387
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
388
|
-
package: z.ZodOptional<z.ZodString>;
|
|
389
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
390
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
391
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
392
|
-
version: z.ZodString;
|
|
393
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
394
|
-
}, z.core.$strip>]>>>;
|
|
395
|
-
target: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodObject<{
|
|
396
|
-
dependencies: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
397
|
-
package: z.ZodOptional<z.ZodString>;
|
|
398
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
399
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
400
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
401
|
-
workspace: z.ZodLiteral<true>;
|
|
402
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
403
|
-
package: z.ZodOptional<z.ZodString>;
|
|
404
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
405
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
406
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
407
|
-
path: z.ZodString;
|
|
408
|
-
version: z.ZodOptional<z.ZodString>;
|
|
409
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
410
|
-
package: z.ZodOptional<z.ZodString>;
|
|
411
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
412
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
413
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
414
|
-
git: z.ZodString;
|
|
415
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
416
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
417
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
418
|
-
version: z.ZodOptional<z.ZodString>;
|
|
419
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
420
|
-
package: z.ZodOptional<z.ZodString>;
|
|
421
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
422
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
423
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
424
|
-
version: z.ZodString;
|
|
425
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
426
|
-
}, z.core.$strip>]>>>;
|
|
427
|
-
"dev-dependencies": z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
428
|
-
package: z.ZodOptional<z.ZodString>;
|
|
429
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
430
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
431
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
432
|
-
workspace: z.ZodLiteral<true>;
|
|
433
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
434
|
-
package: z.ZodOptional<z.ZodString>;
|
|
435
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
436
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
437
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
438
|
-
path: z.ZodString;
|
|
439
|
-
version: z.ZodOptional<z.ZodString>;
|
|
440
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
441
|
-
package: z.ZodOptional<z.ZodString>;
|
|
442
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
443
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
444
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
445
|
-
git: z.ZodString;
|
|
446
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
447
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
448
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
449
|
-
version: z.ZodOptional<z.ZodString>;
|
|
450
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
451
|
-
package: z.ZodOptional<z.ZodString>;
|
|
452
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
453
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
454
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
455
|
-
version: z.ZodString;
|
|
456
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
457
|
-
}, z.core.$strip>]>>>;
|
|
458
|
-
"build-dependencies": z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodUnion<readonly [z.ZodString, z.ZodObject<{
|
|
459
|
-
package: z.ZodOptional<z.ZodString>;
|
|
460
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
461
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
462
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
463
|
-
workspace: z.ZodLiteral<true>;
|
|
464
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
465
|
-
package: z.ZodOptional<z.ZodString>;
|
|
466
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
467
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
468
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
469
|
-
path: z.ZodString;
|
|
470
|
-
version: z.ZodOptional<z.ZodString>;
|
|
471
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
472
|
-
package: z.ZodOptional<z.ZodString>;
|
|
473
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
474
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
475
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
476
|
-
git: z.ZodString;
|
|
477
|
-
branch: z.ZodOptional<z.ZodString>;
|
|
478
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
479
|
-
rev: z.ZodOptional<z.ZodString>;
|
|
480
|
-
version: z.ZodOptional<z.ZodString>;
|
|
481
|
-
}, z.core.$strip>, z.ZodObject<{
|
|
482
|
-
package: z.ZodOptional<z.ZodString>;
|
|
483
|
-
features: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
484
|
-
optional: z.ZodOptional<z.ZodBoolean>;
|
|
485
|
-
"default-features": z.ZodOptional<z.ZodBoolean>;
|
|
486
|
-
version: z.ZodString;
|
|
487
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
488
|
-
}, z.core.$strip>]>>>;
|
|
489
|
-
}, z.core.$loose>>>;
|
|
490
|
-
}, z.core.$loose>;
|
|
491
|
-
type CargoDependency = z.infer<typeof cargoDependencySchema>;
|
|
492
|
-
type CargoManifest = z.infer<typeof cargoManifestSchema>;
|
|
297
|
+
interface CargoDepBase {
|
|
298
|
+
package?: string;
|
|
299
|
+
features?: string[];
|
|
300
|
+
optional?: boolean;
|
|
301
|
+
"default-features"?: boolean;
|
|
302
|
+
}
|
|
303
|
+
interface CargoWorkspaceDependency extends CargoDepBase {
|
|
304
|
+
workspace: true;
|
|
305
|
+
}
|
|
306
|
+
interface CargoPathDependency extends CargoDepBase {
|
|
307
|
+
path: string;
|
|
308
|
+
version?: string;
|
|
309
|
+
}
|
|
310
|
+
interface CargoGitDependency extends CargoDepBase {
|
|
311
|
+
git: string;
|
|
312
|
+
branch?: string;
|
|
313
|
+
tag?: string;
|
|
314
|
+
rev?: string;
|
|
315
|
+
version?: string;
|
|
316
|
+
}
|
|
317
|
+
interface CargoRegistryDependency extends CargoDepBase {
|
|
318
|
+
version: string;
|
|
319
|
+
registry?: string;
|
|
320
|
+
}
|
|
321
|
+
type CargoDependency = string | CargoWorkspaceDependency | CargoPathDependency | CargoGitDependency | CargoRegistryDependency;
|
|
322
|
+
interface CargoInherit {
|
|
323
|
+
workspace: true;
|
|
324
|
+
}
|
|
325
|
+
interface CargoTargetSection {
|
|
326
|
+
dependencies?: Record<string, CargoDependency>;
|
|
327
|
+
"dev-dependencies"?: Record<string, CargoDependency>;
|
|
328
|
+
"build-dependencies"?: Record<string, CargoDependency>;
|
|
329
|
+
}
|
|
330
|
+
interface CargoWorkspace {
|
|
331
|
+
members?: string[];
|
|
332
|
+
exclude?: string[];
|
|
333
|
+
package?: {
|
|
334
|
+
version?: string;
|
|
335
|
+
publish?: boolean;
|
|
336
|
+
};
|
|
337
|
+
dependencies?: Record<string, CargoDependency>;
|
|
338
|
+
"dev-dependencies"?: Record<string, CargoDependency>;
|
|
339
|
+
"build-dependencies"?: Record<string, CargoDependency>;
|
|
340
|
+
}
|
|
341
|
+
interface CargoManifest {
|
|
342
|
+
package?: {
|
|
343
|
+
name: string;
|
|
344
|
+
version: string | CargoInherit;
|
|
345
|
+
publish?: boolean | CargoInherit;
|
|
346
|
+
};
|
|
347
|
+
workspace?: CargoWorkspace;
|
|
348
|
+
dependencies?: Record<string, CargoDependency>;
|
|
349
|
+
"dev-dependencies"?: Record<string, CargoDependency>;
|
|
350
|
+
"build-dependencies"?: Record<string, CargoDependency>;
|
|
351
|
+
target?: Record<string, CargoTargetSection>;
|
|
352
|
+
}
|
|
493
353
|
//#endregion
|
|
494
354
|
//#region src/plugins/cargo.d.ts
|
|
495
355
|
declare const DEP_FIELDS$1: readonly ["dependencies", "dev-dependencies", "build-dependencies"];
|
|
@@ -554,6 +414,90 @@ interface CargoGraph {
|
|
|
554
414
|
packages: Map<string, CargoPackage>;
|
|
555
415
|
}
|
|
556
416
|
//#endregion
|
|
417
|
+
//#region src/providers/npm/graph.d.ts
|
|
418
|
+
declare class NpmPackage extends WorkspacePackage {
|
|
419
|
+
readonly path: string;
|
|
420
|
+
readonly manifest: PackageManifest;
|
|
421
|
+
readonly manager = "npm";
|
|
422
|
+
private dependencies;
|
|
423
|
+
constructor(path: string, manifest: PackageManifest);
|
|
424
|
+
get name(): string;
|
|
425
|
+
get version(): string | undefined;
|
|
426
|
+
write(): Promise<void>;
|
|
427
|
+
initDraft(): PackageDraft;
|
|
428
|
+
getRegistry(): string;
|
|
429
|
+
configureDraft({
|
|
430
|
+
draft
|
|
431
|
+
}: {
|
|
432
|
+
draft: PackageDraft;
|
|
433
|
+
}): void;
|
|
434
|
+
listDependencies(graph: NpmGraph): ResolvedNpmDependency[];
|
|
435
|
+
}
|
|
436
|
+
interface BunWorkspaces {
|
|
437
|
+
packages?: string[];
|
|
438
|
+
catalog?: Record<string, string>;
|
|
439
|
+
catalogs?: Record<string, Record<string, string>>;
|
|
440
|
+
}
|
|
441
|
+
interface PackageManifest {
|
|
442
|
+
name: string;
|
|
443
|
+
version?: string;
|
|
444
|
+
private?: boolean;
|
|
445
|
+
publishConfig?: {
|
|
446
|
+
access?: "public" | "restricted";
|
|
447
|
+
registry?: string;
|
|
448
|
+
tag?: string;
|
|
449
|
+
};
|
|
450
|
+
scripts?: Record<string, string>;
|
|
451
|
+
workspaces?: string[] | BunWorkspaces;
|
|
452
|
+
catalog?: Record<string, string>;
|
|
453
|
+
catalogs?: Record<string, Record<string, string>>;
|
|
454
|
+
dependencies?: Record<string, string>;
|
|
455
|
+
devDependencies?: Record<string, string>;
|
|
456
|
+
peerDependencies?: Record<string, string>;
|
|
457
|
+
optionalDependencies?: Record<string, string>;
|
|
458
|
+
}
|
|
459
|
+
declare const DEP_FIELDS: readonly ["dependencies", "devDependencies", "peerDependencies", "optionalDependencies"];
|
|
460
|
+
type DepField = (typeof DEP_FIELDS)[number];
|
|
461
|
+
type DependencySpec = {
|
|
462
|
+
protocol: "workspace";
|
|
463
|
+
range: string;
|
|
464
|
+
packageName?: string;
|
|
465
|
+
path?: string;
|
|
466
|
+
} | {
|
|
467
|
+
protocol: "file" | "portal";
|
|
468
|
+
path: string;
|
|
469
|
+
} | {
|
|
470
|
+
protocol: "catalog";
|
|
471
|
+
catalogName: string;
|
|
472
|
+
} | {
|
|
473
|
+
protocol: "npm";
|
|
474
|
+
alias: string;
|
|
475
|
+
range: string;
|
|
476
|
+
} | {
|
|
477
|
+
range: string;
|
|
478
|
+
protocol?: undefined;
|
|
479
|
+
};
|
|
480
|
+
interface ResolvedNpmDependency {
|
|
481
|
+
field: DepField;
|
|
482
|
+
name: string;
|
|
483
|
+
spec: DependencySpec;
|
|
484
|
+
linked?: NpmPackage;
|
|
485
|
+
range?: string;
|
|
486
|
+
setRange?: (range: string) => void;
|
|
487
|
+
}
|
|
488
|
+
interface NpmGraph {
|
|
489
|
+
root: string;
|
|
490
|
+
/** package name -> package */
|
|
491
|
+
packages: Map<string, NpmPackage>;
|
|
492
|
+
packagesByPath: Map<string, NpmPackage>;
|
|
493
|
+
catalogs: CatalogSource[];
|
|
494
|
+
}
|
|
495
|
+
interface CatalogSource {
|
|
496
|
+
resolve(name: string, catalogName: string): string | undefined;
|
|
497
|
+
setRange(name: string, catalogName: string, range: string): void;
|
|
498
|
+
write?: () => Promise<void>;
|
|
499
|
+
}
|
|
500
|
+
//#endregion
|
|
557
501
|
//#region src/context.d.ts
|
|
558
502
|
interface TegamiContext {
|
|
559
503
|
/** absolute path */
|
|
@@ -579,35 +523,14 @@ interface TegamiContext {
|
|
|
579
523
|
};
|
|
580
524
|
/** additional context when npm plugin is configured */
|
|
581
525
|
npm?: {
|
|
582
|
-
client: AgentName;
|
|
526
|
+
client: AgentName; /** available after resolve */
|
|
527
|
+
graph?: NpmGraph;
|
|
583
528
|
};
|
|
584
529
|
cargo?: {
|
|
585
530
|
graph: CargoGraph;
|
|
586
531
|
};
|
|
587
532
|
}
|
|
588
533
|
//#endregion
|
|
589
|
-
//#region src/providers/npm/schema.d.ts
|
|
590
|
-
declare const packageManifestSchema: z.ZodObject<{
|
|
591
|
-
name: z.ZodString;
|
|
592
|
-
version: z.ZodOptional<z.ZodString>;
|
|
593
|
-
private: z.ZodOptional<z.ZodBoolean>;
|
|
594
|
-
publishConfig: z.ZodOptional<z.ZodObject<{
|
|
595
|
-
access: z.ZodOptional<z.ZodEnum<{
|
|
596
|
-
public: "public";
|
|
597
|
-
restricted: "restricted";
|
|
598
|
-
}>>;
|
|
599
|
-
registry: z.ZodOptional<z.ZodString>;
|
|
600
|
-
tag: z.ZodOptional<z.ZodString>;
|
|
601
|
-
}, z.core.$loose>>;
|
|
602
|
-
scripts: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
603
|
-
workspaces: z.ZodOptional<z.ZodArray<z.ZodString>>;
|
|
604
|
-
dependencies: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
605
|
-
devDependencies: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
606
|
-
peerDependencies: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
607
|
-
optionalDependencies: z.ZodOptional<z.ZodRecord<z.ZodString, z.ZodString>>;
|
|
608
|
-
}, z.core.$loose>;
|
|
609
|
-
type PackageManifest = z.infer<typeof packageManifestSchema>;
|
|
610
|
-
//#endregion
|
|
611
534
|
//#region src/changelog/generate.d.ts
|
|
612
535
|
interface GenerateFromCommitsOptions {
|
|
613
536
|
/** Start revision. Defaults to the latest reachable git tag, or all history if none exists. */
|
|
@@ -761,46 +684,12 @@ type TrustedPublishOptions = {
|
|
|
761
684
|
};
|
|
762
685
|
//#endregion
|
|
763
686
|
//#region src/providers/npm.d.ts
|
|
764
|
-
declare const DEP_FIELDS: readonly ["dependencies", "devDependencies", "peerDependencies", "optionalDependencies"];
|
|
765
|
-
declare class NpmPackage extends WorkspacePackage {
|
|
766
|
-
readonly path: string;
|
|
767
|
-
readonly manifest: PackageManifest;
|
|
768
|
-
readonly manager = "npm";
|
|
769
|
-
constructor(path: string, manifest: PackageManifest);
|
|
770
|
-
get name(): string;
|
|
771
|
-
get version(): string | undefined;
|
|
772
|
-
write(): Promise<void>;
|
|
773
|
-
initDraft(): PackageDraft;
|
|
774
|
-
getRegistry(): string;
|
|
775
|
-
configureDraft({
|
|
776
|
-
draft
|
|
777
|
-
}: {
|
|
778
|
-
draft: PackageDraft;
|
|
779
|
-
}): void;
|
|
780
|
-
}
|
|
781
|
-
type DependencySpec = {
|
|
782
|
-
protocol: "npm";
|
|
783
|
-
alias: string;
|
|
784
|
-
range: string;
|
|
785
|
-
linked?: WorkspacePackage;
|
|
786
|
-
} | {
|
|
787
|
-
protocol: "workspace";
|
|
788
|
-
range: string;
|
|
789
|
-
linked?: WorkspacePackage;
|
|
790
|
-
} | {
|
|
791
|
-
protocol: "file";
|
|
792
|
-
raw: string;
|
|
793
|
-
linked?: WorkspacePackage;
|
|
794
|
-
} | {
|
|
795
|
-
range: string;
|
|
796
|
-
linked?: WorkspacePackage;
|
|
797
|
-
protocol?: undefined;
|
|
798
|
-
};
|
|
799
687
|
interface DependentRef {
|
|
800
688
|
dependent: NpmPackage;
|
|
801
|
-
kind:
|
|
689
|
+
kind: DepField;
|
|
802
690
|
name: string;
|
|
803
691
|
spec: DependencySpec;
|
|
692
|
+
resolved: ResolvedNpmDependency;
|
|
804
693
|
}
|
|
805
694
|
interface NpmPluginOptions {
|
|
806
695
|
/** Package manager command used for npm registry operations. */
|
|
@@ -985,4 +874,4 @@ interface PublishPreflight {
|
|
|
985
874
|
wait?: string[];
|
|
986
875
|
}
|
|
987
876
|
//#endregion
|
|
988
|
-
export {
|
|
877
|
+
export { WorkspacePackage as A, NpmPackage as C, cargo as D, CargoPluginOptions as E, DraftPolicy as M, PackageDraft as N, PackageGraph as O, BumpType as P, NpmGraph as S, CargoPackage as T, PublishOptions as _, PublishPreflight as a, TegamiContext as b, TegamiPluginOption as c, GenerateChangelogOptions as d, Tegami as f, PackagePublishResult as g, PackagePublishPlan as h, PackageOptions as i, Draft as j, PackageGroup as k, NpmPluginOptions as l, PublishLock as m, GroupOptions as n, TegamiOptions as o, tegami as p, LogGenerator as r, TegamiPlugin as s, Awaitable as t, npm as u, PublishPlan as v, CargoGraph as w, DependencySpec as x, CommitChangelog as y };
|