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.
@@ -1,2 +1,2 @@
1
- import { C as CargoPackage, S as CargoGraph, T as cargo, w as CargoPluginOptions } from "../types-BoQR7Hlg.js";
1
+ import { D as cargo, E as CargoPluginOptions, T as CargoPackage, w as CargoGraph } from "../types-B50RK1rR.js";
2
2
  export { CargoGraph, CargoPackage, CargoPluginOptions, cargo };
@@ -1,77 +1,502 @@
1
1
  import { n as execFailure } from "../error-BhMYq9iW.js";
2
+ import { t as _accessExpressionAsString } from "../_accessExpressionAsString-QhbUZzwv.js";
3
+ import { t as _assertGuard } from "../_assertGuard-BBn2NbSz.js";
2
4
  import { n as WorkspacePackage } from "../graph-BmXTJZxx.js";
3
5
  import { readFile, writeFile } from "node:fs/promises";
4
6
  import path from "node:path";
5
7
  import { x } from "tinyexec";
6
8
  import * as semver$1 from "semver";
7
- import z from "zod";
8
9
  import { glob } from "tinyglobby";
9
10
  import initToml, { edit, parse as parse$1 } from "@rainbowatcher/toml-edit-js";
10
11
  //#region src/plugins/cargo/schema.ts
11
- const baseDepSchema = z.object({
12
- package: z.string().optional(),
13
- features: z.array(z.string()).optional(),
14
- optional: z.boolean().optional(),
15
- "default-features": z.boolean().optional()
16
- });
17
- /** `{ workspace = true }` inherit from `[workspace.dependencies]` */
18
- const workspaceDependencySchema = baseDepSchema.extend({ workspace: z.literal(true) });
19
- /** `{ path = "../lib" }` — optional `version` for publishing */
20
- const pathDependencySchema = baseDepSchema.extend({
21
- path: z.string(),
22
- version: z.string().optional()
23
- });
24
- /** `{ git = "" }` exactly one of `branch`, `tag`, or `rev` in practice */
25
- const gitDependencySchema = baseDepSchema.extend({
26
- git: z.string(),
27
- branch: z.string().optional(),
28
- tag: z.string().optional(),
29
- rev: z.string().optional(),
30
- version: z.string().optional()
31
- });
32
- /** `{ version = "1.0" }` crates.io or `[registries]` */
33
- const registryDependencySchema = baseDepSchema.extend({
34
- version: z.string(),
35
- registry: z.string().optional()
36
- });
37
- /**
38
- * @see https://doc.rust-lang.org/cargo/reference/specifying-dependencies.html
39
- */
40
- const cargoDependencySchema = z.union([
41
- z.string(),
42
- workspaceDependencySchema,
43
- pathDependencySchema,
44
- gitDependencySchema,
45
- registryDependencySchema
46
- ]);
47
- const cargoInheritSchema = z.looseObject({ workspace: z.literal(true) });
48
- const cargoWorkspaceSchema = z.looseObject({
49
- members: z.array(z.string()).optional(),
50
- exclude: z.array(z.string()).optional(),
51
- package: z.looseObject({
52
- version: z.string().optional(),
53
- publish: z.boolean().optional()
54
- }).optional(),
55
- dependencies: z.record(z.string(), cargoDependencySchema).optional(),
56
- "dev-dependencies": z.record(z.string(), cargoDependencySchema).optional(),
57
- "build-dependencies": z.record(z.string(), cargoDependencySchema).optional()
58
- });
59
- const cargoManifestSchema = z.looseObject({
60
- package: z.looseObject({
61
- name: z.string(),
62
- version: z.string().or(cargoInheritSchema),
63
- publish: z.boolean().or(cargoInheritSchema).optional()
64
- }).optional(),
65
- workspace: cargoWorkspaceSchema.optional(),
66
- dependencies: z.record(z.string(), cargoDependencySchema).optional(),
67
- "dev-dependencies": z.record(z.string(), cargoDependencySchema).optional(),
68
- "build-dependencies": z.record(z.string(), cargoDependencySchema).optional(),
69
- target: z.record(z.string(), z.looseObject({
70
- dependencies: z.record(z.string(), cargoDependencySchema).optional(),
71
- "dev-dependencies": z.record(z.string(), cargoDependencySchema).optional(),
72
- "build-dependencies": z.record(z.string(), cargoDependencySchema).optional()
73
- })).optional()
74
- });
12
+ const assertCargoManifest = (() => {
13
+ const _io0 = (input) => (void 0 === input["package"] || "object" === typeof input["package"] && null !== input["package"] && _io1(input["package"])) && (void 0 === input.workspace || "object" === typeof input.workspace && null !== input.workspace && false === Array.isArray(input.workspace) && _io3(input.workspace)) && (void 0 === input.dependencies || "object" === typeof input.dependencies && null !== input.dependencies && false === Array.isArray(input.dependencies) && _io5(input.dependencies)) && (void 0 === input["dev-dependencies"] || "object" === typeof input["dev-dependencies"] && null !== input["dev-dependencies"] && false === Array.isArray(input["dev-dependencies"]) && _io5(input["dev-dependencies"])) && (void 0 === input["build-dependencies"] || "object" === typeof input["build-dependencies"] && null !== input["build-dependencies"] && false === Array.isArray(input["build-dependencies"]) && _io5(input["build-dependencies"])) && (void 0 === input.target || "object" === typeof input.target && null !== input.target && false === Array.isArray(input.target) && _io10(input.target));
14
+ const _io1 = (input) => "string" === typeof input.name && null !== input.version && void 0 !== input.version && ("string" === typeof input.version || "object" === typeof input.version && null !== input.version && _io2(input.version)) && null !== input.publish && (void 0 === input.publish || "boolean" === typeof input.publish || "object" === typeof input.publish && null !== input.publish && _io2(input.publish));
15
+ const _io2 = (input) => true === input.workspace;
16
+ const _io3 = (input) => (void 0 === input.members || Array.isArray(input.members) && input.members.every((elem) => "string" === typeof elem)) && (void 0 === input.exclude || Array.isArray(input.exclude) && input.exclude.every((elem) => "string" === typeof elem)) && (void 0 === input["package"] || "object" === typeof input["package"] && null !== input["package"] && false === Array.isArray(input["package"]) && _io4(input["package"])) && (void 0 === input.dependencies || "object" === typeof input.dependencies && null !== input.dependencies && false === Array.isArray(input.dependencies) && _io5(input.dependencies)) && (void 0 === input["dev-dependencies"] || "object" === typeof input["dev-dependencies"] && null !== input["dev-dependencies"] && false === Array.isArray(input["dev-dependencies"]) && _io5(input["dev-dependencies"])) && (void 0 === input["build-dependencies"] || "object" === typeof input["build-dependencies"] && null !== input["build-dependencies"] && false === Array.isArray(input["build-dependencies"]) && _io5(input["build-dependencies"]));
17
+ const _io4 = (input) => (void 0 === input.version || "string" === typeof input.version) && (void 0 === input.publish || "boolean" === typeof input.publish);
18
+ const _io5 = (input) => Object.keys(input).every((key) => {
19
+ const value = input[key];
20
+ if (void 0 === value) return true;
21
+ return null !== value && void 0 !== value && ("string" === typeof value || "object" === typeof value && null !== value && _iu0(value));
22
+ });
23
+ const _io6 = (input) => true === input.workspace && (void 0 === input["package"] || "string" === typeof input["package"]) && (void 0 === input.features || Array.isArray(input.features) && input.features.every((elem) => "string" === typeof elem)) && (void 0 === input.optional || "boolean" === typeof input.optional) && (void 0 === input["default-features"] || "boolean" === typeof input["default-features"]);
24
+ const _io7 = (input) => "string" === typeof input.path && (void 0 === input.version || "string" === typeof input.version) && (void 0 === input["package"] || "string" === typeof input["package"]) && (void 0 === input.features || Array.isArray(input.features) && input.features.every((elem) => "string" === typeof elem)) && (void 0 === input.optional || "boolean" === typeof input.optional) && (void 0 === input["default-features"] || "boolean" === typeof input["default-features"]);
25
+ const _io8 = (input) => "string" === typeof input.git && (void 0 === input.branch || "string" === typeof input.branch) && (void 0 === input.tag || "string" === typeof input.tag) && (void 0 === input.rev || "string" === typeof input.rev) && (void 0 === input.version || "string" === typeof input.version) && (void 0 === input["package"] || "string" === typeof input["package"]) && (void 0 === input.features || Array.isArray(input.features) && input.features.every((elem) => "string" === typeof elem)) && (void 0 === input.optional || "boolean" === typeof input.optional) && (void 0 === input["default-features"] || "boolean" === typeof input["default-features"]);
26
+ const _io9 = (input) => "string" === typeof input.version && (void 0 === input.registry || "string" === typeof input.registry) && (void 0 === input["package"] || "string" === typeof input["package"]) && (void 0 === input.features || Array.isArray(input.features) && input.features.every((elem) => "string" === typeof elem)) && (void 0 === input.optional || "boolean" === typeof input.optional) && (void 0 === input["default-features"] || "boolean" === typeof input["default-features"]);
27
+ const _io10 = (input) => Object.keys(input).every((key) => {
28
+ const value = input[key];
29
+ if (void 0 === value) return true;
30
+ return "object" === typeof value && null !== value && false === Array.isArray(value) && _io11(value);
31
+ });
32
+ const _io11 = (input) => (void 0 === input.dependencies || "object" === typeof input.dependencies && null !== input.dependencies && false === Array.isArray(input.dependencies) && _io5(input.dependencies)) && (void 0 === input["dev-dependencies"] || "object" === typeof input["dev-dependencies"] && null !== input["dev-dependencies"] && false === Array.isArray(input["dev-dependencies"]) && _io5(input["dev-dependencies"])) && (void 0 === input["build-dependencies"] || "object" === typeof input["build-dependencies"] && null !== input["build-dependencies"] && false === Array.isArray(input["build-dependencies"]) && _io5(input["build-dependencies"]));
33
+ const _iu0 = (input) => (() => {
34
+ if (void 0 !== input.workspace) return _io6(input);
35
+ else if (void 0 !== input.path) return _io7(input);
36
+ else if (void 0 !== input.git) return _io8(input);
37
+ else return _io9(input);
38
+ })();
39
+ const _ao0 = (input, _path, _exceptionable = true) => (void 0 === input["package"] || ("object" === typeof input["package"] && null !== input["package"] || _assertGuard(_exceptionable, {
40
+ method: "typia.createAssert",
41
+ path: _path + "[\"package\"]",
42
+ expected: "(__type | undefined)",
43
+ value: input["package"]
44
+ }, _errorFactory)) && _ao1(input["package"], _path + "[\"package\"]", _exceptionable) || _assertGuard(_exceptionable, {
45
+ method: "typia.createAssert",
46
+ path: _path + "[\"package\"]",
47
+ expected: "(__type | undefined)",
48
+ value: input["package"]
49
+ }, _errorFactory)) && (void 0 === input.workspace || ("object" === typeof input.workspace && null !== input.workspace && false === Array.isArray(input.workspace) || _assertGuard(_exceptionable, {
50
+ method: "typia.createAssert",
51
+ path: _path + ".workspace",
52
+ expected: "(CargoWorkspace | undefined)",
53
+ value: input.workspace
54
+ }, _errorFactory)) && _ao3(input.workspace, _path + ".workspace", _exceptionable) || _assertGuard(_exceptionable, {
55
+ method: "typia.createAssert",
56
+ path: _path + ".workspace",
57
+ expected: "(CargoWorkspace | undefined)",
58
+ value: input.workspace
59
+ }, _errorFactory)) && (void 0 === input.dependencies || ("object" === typeof input.dependencies && null !== input.dependencies && false === Array.isArray(input.dependencies) || _assertGuard(_exceptionable, {
60
+ method: "typia.createAssert",
61
+ path: _path + ".dependencies",
62
+ expected: "(Record<string, CargoDependency> | undefined)",
63
+ value: input.dependencies
64
+ }, _errorFactory)) && _ao5(input.dependencies, _path + ".dependencies", _exceptionable) || _assertGuard(_exceptionable, {
65
+ method: "typia.createAssert",
66
+ path: _path + ".dependencies",
67
+ expected: "(Record<string, CargoDependency> | undefined)",
68
+ value: input.dependencies
69
+ }, _errorFactory)) && (void 0 === input["dev-dependencies"] || ("object" === typeof input["dev-dependencies"] && null !== input["dev-dependencies"] && false === Array.isArray(input["dev-dependencies"]) || _assertGuard(_exceptionable, {
70
+ method: "typia.createAssert",
71
+ path: _path + "[\"dev-dependencies\"]",
72
+ expected: "(Record<string, CargoDependency> | undefined)",
73
+ value: input["dev-dependencies"]
74
+ }, _errorFactory)) && _ao5(input["dev-dependencies"], _path + "[\"dev-dependencies\"]", _exceptionable) || _assertGuard(_exceptionable, {
75
+ method: "typia.createAssert",
76
+ path: _path + "[\"dev-dependencies\"]",
77
+ expected: "(Record<string, CargoDependency> | undefined)",
78
+ value: input["dev-dependencies"]
79
+ }, _errorFactory)) && (void 0 === input["build-dependencies"] || ("object" === typeof input["build-dependencies"] && null !== input["build-dependencies"] && false === Array.isArray(input["build-dependencies"]) || _assertGuard(_exceptionable, {
80
+ method: "typia.createAssert",
81
+ path: _path + "[\"build-dependencies\"]",
82
+ expected: "(Record<string, CargoDependency> | undefined)",
83
+ value: input["build-dependencies"]
84
+ }, _errorFactory)) && _ao5(input["build-dependencies"], _path + "[\"build-dependencies\"]", _exceptionable) || _assertGuard(_exceptionable, {
85
+ method: "typia.createAssert",
86
+ path: _path + "[\"build-dependencies\"]",
87
+ expected: "(Record<string, CargoDependency> | undefined)",
88
+ value: input["build-dependencies"]
89
+ }, _errorFactory)) && (void 0 === input.target || ("object" === typeof input.target && null !== input.target && false === Array.isArray(input.target) || _assertGuard(_exceptionable, {
90
+ method: "typia.createAssert",
91
+ path: _path + ".target",
92
+ expected: "(Record<string, CargoTargetSection> | undefined)",
93
+ value: input.target
94
+ }, _errorFactory)) && _ao10(input.target, _path + ".target", _exceptionable) || _assertGuard(_exceptionable, {
95
+ method: "typia.createAssert",
96
+ path: _path + ".target",
97
+ expected: "(Record<string, CargoTargetSection> | undefined)",
98
+ value: input.target
99
+ }, _errorFactory));
100
+ const _ao1 = (input, _path, _exceptionable = true) => ("string" === typeof input.name || _assertGuard(_exceptionable, {
101
+ method: "typia.createAssert",
102
+ path: _path + ".name",
103
+ expected: "string",
104
+ value: input.name
105
+ }, _errorFactory)) && (null !== input.version || _assertGuard(_exceptionable, {
106
+ method: "typia.createAssert",
107
+ path: _path + ".version",
108
+ expected: "(CargoInherit | string)",
109
+ value: input.version
110
+ }, _errorFactory)) && (void 0 !== input.version || _assertGuard(_exceptionable, {
111
+ method: "typia.createAssert",
112
+ path: _path + ".version",
113
+ expected: "(CargoInherit | string)",
114
+ value: input.version
115
+ }, _errorFactory)) && ("string" === typeof input.version || ("object" === typeof input.version && null !== input.version || _assertGuard(_exceptionable, {
116
+ method: "typia.createAssert",
117
+ path: _path + ".version",
118
+ expected: "(CargoInherit | string)",
119
+ value: input.version
120
+ }, _errorFactory)) && _ao2(input.version, _path + ".version", _exceptionable) || _assertGuard(_exceptionable, {
121
+ method: "typia.createAssert",
122
+ path: _path + ".version",
123
+ expected: "(CargoInherit | string)",
124
+ value: input.version
125
+ }, _errorFactory)) && (null !== input.publish || _assertGuard(_exceptionable, {
126
+ method: "typia.createAssert",
127
+ path: _path + ".publish",
128
+ expected: "(CargoInherit | boolean | undefined)",
129
+ value: input.publish
130
+ }, _errorFactory)) && (void 0 === input.publish || "boolean" === typeof input.publish || ("object" === typeof input.publish && null !== input.publish || _assertGuard(_exceptionable, {
131
+ method: "typia.createAssert",
132
+ path: _path + ".publish",
133
+ expected: "(CargoInherit | boolean | undefined)",
134
+ value: input.publish
135
+ }, _errorFactory)) && _ao2(input.publish, _path + ".publish", _exceptionable) || _assertGuard(_exceptionable, {
136
+ method: "typia.createAssert",
137
+ path: _path + ".publish",
138
+ expected: "(CargoInherit | boolean | undefined)",
139
+ value: input.publish
140
+ }, _errorFactory));
141
+ const _ao2 = (input, _path, _exceptionable = true) => true === input.workspace || _assertGuard(_exceptionable, {
142
+ method: "typia.createAssert",
143
+ path: _path + ".workspace",
144
+ expected: "true",
145
+ value: input.workspace
146
+ }, _errorFactory);
147
+ const _ao3 = (input, _path, _exceptionable = true) => (void 0 === input.members || (Array.isArray(input.members) || _assertGuard(_exceptionable, {
148
+ method: "typia.createAssert",
149
+ path: _path + ".members",
150
+ expected: "(Array<string> | undefined)",
151
+ value: input.members
152
+ }, _errorFactory)) && input.members.every((elem, _index7) => "string" === typeof elem || _assertGuard(_exceptionable, {
153
+ method: "typia.createAssert",
154
+ path: _path + ".members[" + _index7 + "]",
155
+ expected: "string",
156
+ value: elem
157
+ }, _errorFactory)) || _assertGuard(_exceptionable, {
158
+ method: "typia.createAssert",
159
+ path: _path + ".members",
160
+ expected: "(Array<string> | undefined)",
161
+ value: input.members
162
+ }, _errorFactory)) && (void 0 === input.exclude || (Array.isArray(input.exclude) || _assertGuard(_exceptionable, {
163
+ method: "typia.createAssert",
164
+ path: _path + ".exclude",
165
+ expected: "(Array<string> | undefined)",
166
+ value: input.exclude
167
+ }, _errorFactory)) && input.exclude.every((elem, _index8) => "string" === typeof elem || _assertGuard(_exceptionable, {
168
+ method: "typia.createAssert",
169
+ path: _path + ".exclude[" + _index8 + "]",
170
+ expected: "string",
171
+ value: elem
172
+ }, _errorFactory)) || _assertGuard(_exceptionable, {
173
+ method: "typia.createAssert",
174
+ path: _path + ".exclude",
175
+ expected: "(Array<string> | undefined)",
176
+ value: input.exclude
177
+ }, _errorFactory)) && (void 0 === input["package"] || ("object" === typeof input["package"] && null !== input["package"] && false === Array.isArray(input["package"]) || _assertGuard(_exceptionable, {
178
+ method: "typia.createAssert",
179
+ path: _path + "[\"package\"]",
180
+ expected: "(__type.o1 | undefined)",
181
+ value: input["package"]
182
+ }, _errorFactory)) && _ao4(input["package"], _path + "[\"package\"]", _exceptionable) || _assertGuard(_exceptionable, {
183
+ method: "typia.createAssert",
184
+ path: _path + "[\"package\"]",
185
+ expected: "(__type.o1 | undefined)",
186
+ value: input["package"]
187
+ }, _errorFactory)) && (void 0 === input.dependencies || ("object" === typeof input.dependencies && null !== input.dependencies && false === Array.isArray(input.dependencies) || _assertGuard(_exceptionable, {
188
+ method: "typia.createAssert",
189
+ path: _path + ".dependencies",
190
+ expected: "(Record<string, CargoDependency> | undefined)",
191
+ value: input.dependencies
192
+ }, _errorFactory)) && _ao5(input.dependencies, _path + ".dependencies", _exceptionable) || _assertGuard(_exceptionable, {
193
+ method: "typia.createAssert",
194
+ path: _path + ".dependencies",
195
+ expected: "(Record<string, CargoDependency> | undefined)",
196
+ value: input.dependencies
197
+ }, _errorFactory)) && (void 0 === input["dev-dependencies"] || ("object" === typeof input["dev-dependencies"] && null !== input["dev-dependencies"] && false === Array.isArray(input["dev-dependencies"]) || _assertGuard(_exceptionable, {
198
+ method: "typia.createAssert",
199
+ path: _path + "[\"dev-dependencies\"]",
200
+ expected: "(Record<string, CargoDependency> | undefined)",
201
+ value: input["dev-dependencies"]
202
+ }, _errorFactory)) && _ao5(input["dev-dependencies"], _path + "[\"dev-dependencies\"]", _exceptionable) || _assertGuard(_exceptionable, {
203
+ method: "typia.createAssert",
204
+ path: _path + "[\"dev-dependencies\"]",
205
+ expected: "(Record<string, CargoDependency> | undefined)",
206
+ value: input["dev-dependencies"]
207
+ }, _errorFactory)) && (void 0 === input["build-dependencies"] || ("object" === typeof input["build-dependencies"] && null !== input["build-dependencies"] && false === Array.isArray(input["build-dependencies"]) || _assertGuard(_exceptionable, {
208
+ method: "typia.createAssert",
209
+ path: _path + "[\"build-dependencies\"]",
210
+ expected: "(Record<string, CargoDependency> | undefined)",
211
+ value: input["build-dependencies"]
212
+ }, _errorFactory)) && _ao5(input["build-dependencies"], _path + "[\"build-dependencies\"]", _exceptionable) || _assertGuard(_exceptionable, {
213
+ method: "typia.createAssert",
214
+ path: _path + "[\"build-dependencies\"]",
215
+ expected: "(Record<string, CargoDependency> | undefined)",
216
+ value: input["build-dependencies"]
217
+ }, _errorFactory));
218
+ const _ao4 = (input, _path, _exceptionable = true) => (void 0 === input.version || "string" === typeof input.version || _assertGuard(_exceptionable, {
219
+ method: "typia.createAssert",
220
+ path: _path + ".version",
221
+ expected: "(string | undefined)",
222
+ value: input.version
223
+ }, _errorFactory)) && (void 0 === input.publish || "boolean" === typeof input.publish || _assertGuard(_exceptionable, {
224
+ method: "typia.createAssert",
225
+ path: _path + ".publish",
226
+ expected: "(boolean | undefined)",
227
+ value: input.publish
228
+ }, _errorFactory));
229
+ const _ao5 = (input, _path, _exceptionable = true) => false === _exceptionable || Object.keys(input).every((key) => {
230
+ const value = input[key];
231
+ if (void 0 === value) return true;
232
+ return (null !== value || _assertGuard(_exceptionable, {
233
+ method: "typia.createAssert",
234
+ path: _path + _accessExpressionAsString(key),
235
+ expected: "(CargoGitDependency | CargoPathDependency | CargoRegistryDependency | CargoWorkspaceDependency | string)",
236
+ value
237
+ }, _errorFactory)) && (void 0 !== value || _assertGuard(_exceptionable, {
238
+ method: "typia.createAssert",
239
+ path: _path + _accessExpressionAsString(key),
240
+ expected: "(CargoGitDependency | CargoPathDependency | CargoRegistryDependency | CargoWorkspaceDependency | string)",
241
+ value
242
+ }, _errorFactory)) && ("string" === typeof value || ("object" === typeof value && null !== value || _assertGuard(_exceptionable, {
243
+ method: "typia.createAssert",
244
+ path: _path + _accessExpressionAsString(key),
245
+ expected: "(CargoGitDependency | CargoPathDependency | CargoRegistryDependency | CargoWorkspaceDependency | string)",
246
+ value
247
+ }, _errorFactory)) && _au0(value, _path + _accessExpressionAsString(key), _exceptionable) || _assertGuard(_exceptionable, {
248
+ method: "typia.createAssert",
249
+ path: _path + _accessExpressionAsString(key),
250
+ expected: "(CargoGitDependency | CargoPathDependency | CargoRegistryDependency | CargoWorkspaceDependency | string)",
251
+ value
252
+ }, _errorFactory));
253
+ });
254
+ const _ao6 = (input, _path, _exceptionable = true) => (true === input.workspace || _assertGuard(_exceptionable, {
255
+ method: "typia.createAssert",
256
+ path: _path + ".workspace",
257
+ expected: "true",
258
+ value: input.workspace
259
+ }, _errorFactory)) && (void 0 === input["package"] || "string" === typeof input["package"] || _assertGuard(_exceptionable, {
260
+ method: "typia.createAssert",
261
+ path: _path + "[\"package\"]",
262
+ expected: "(string | undefined)",
263
+ value: input["package"]
264
+ }, _errorFactory)) && (void 0 === input.features || (Array.isArray(input.features) || _assertGuard(_exceptionable, {
265
+ method: "typia.createAssert",
266
+ path: _path + ".features",
267
+ expected: "(Array<string> | undefined)",
268
+ value: input.features
269
+ }, _errorFactory)) && input.features.every((elem, _index9) => "string" === typeof elem || _assertGuard(_exceptionable, {
270
+ method: "typia.createAssert",
271
+ path: _path + ".features[" + _index9 + "]",
272
+ expected: "string",
273
+ value: elem
274
+ }, _errorFactory)) || _assertGuard(_exceptionable, {
275
+ method: "typia.createAssert",
276
+ path: _path + ".features",
277
+ expected: "(Array<string> | undefined)",
278
+ value: input.features
279
+ }, _errorFactory)) && (void 0 === input.optional || "boolean" === typeof input.optional || _assertGuard(_exceptionable, {
280
+ method: "typia.createAssert",
281
+ path: _path + ".optional",
282
+ expected: "(boolean | undefined)",
283
+ value: input.optional
284
+ }, _errorFactory)) && (void 0 === input["default-features"] || "boolean" === typeof input["default-features"] || _assertGuard(_exceptionable, {
285
+ method: "typia.createAssert",
286
+ path: _path + "[\"default-features\"]",
287
+ expected: "(boolean | undefined)",
288
+ value: input["default-features"]
289
+ }, _errorFactory));
290
+ const _ao7 = (input, _path, _exceptionable = true) => ("string" === typeof input.path || _assertGuard(_exceptionable, {
291
+ method: "typia.createAssert",
292
+ path: _path + ".path",
293
+ expected: "string",
294
+ value: input.path
295
+ }, _errorFactory)) && (void 0 === input.version || "string" === typeof input.version || _assertGuard(_exceptionable, {
296
+ method: "typia.createAssert",
297
+ path: _path + ".version",
298
+ expected: "(string | undefined)",
299
+ value: input.version
300
+ }, _errorFactory)) && (void 0 === input["package"] || "string" === typeof input["package"] || _assertGuard(_exceptionable, {
301
+ method: "typia.createAssert",
302
+ path: _path + "[\"package\"]",
303
+ expected: "(string | undefined)",
304
+ value: input["package"]
305
+ }, _errorFactory)) && (void 0 === input.features || (Array.isArray(input.features) || _assertGuard(_exceptionable, {
306
+ method: "typia.createAssert",
307
+ path: _path + ".features",
308
+ expected: "(Array<string> | undefined)",
309
+ value: input.features
310
+ }, _errorFactory)) && input.features.every((elem, _index10) => "string" === typeof elem || _assertGuard(_exceptionable, {
311
+ method: "typia.createAssert",
312
+ path: _path + ".features[" + _index10 + "]",
313
+ expected: "string",
314
+ value: elem
315
+ }, _errorFactory)) || _assertGuard(_exceptionable, {
316
+ method: "typia.createAssert",
317
+ path: _path + ".features",
318
+ expected: "(Array<string> | undefined)",
319
+ value: input.features
320
+ }, _errorFactory)) && (void 0 === input.optional || "boolean" === typeof input.optional || _assertGuard(_exceptionable, {
321
+ method: "typia.createAssert",
322
+ path: _path + ".optional",
323
+ expected: "(boolean | undefined)",
324
+ value: input.optional
325
+ }, _errorFactory)) && (void 0 === input["default-features"] || "boolean" === typeof input["default-features"] || _assertGuard(_exceptionable, {
326
+ method: "typia.createAssert",
327
+ path: _path + "[\"default-features\"]",
328
+ expected: "(boolean | undefined)",
329
+ value: input["default-features"]
330
+ }, _errorFactory));
331
+ const _ao8 = (input, _path, _exceptionable = true) => ("string" === typeof input.git || _assertGuard(_exceptionable, {
332
+ method: "typia.createAssert",
333
+ path: _path + ".git",
334
+ expected: "string",
335
+ value: input.git
336
+ }, _errorFactory)) && (void 0 === input.branch || "string" === typeof input.branch || _assertGuard(_exceptionable, {
337
+ method: "typia.createAssert",
338
+ path: _path + ".branch",
339
+ expected: "(string | undefined)",
340
+ value: input.branch
341
+ }, _errorFactory)) && (void 0 === input.tag || "string" === typeof input.tag || _assertGuard(_exceptionable, {
342
+ method: "typia.createAssert",
343
+ path: _path + ".tag",
344
+ expected: "(string | undefined)",
345
+ value: input.tag
346
+ }, _errorFactory)) && (void 0 === input.rev || "string" === typeof input.rev || _assertGuard(_exceptionable, {
347
+ method: "typia.createAssert",
348
+ path: _path + ".rev",
349
+ expected: "(string | undefined)",
350
+ value: input.rev
351
+ }, _errorFactory)) && (void 0 === input.version || "string" === typeof input.version || _assertGuard(_exceptionable, {
352
+ method: "typia.createAssert",
353
+ path: _path + ".version",
354
+ expected: "(string | undefined)",
355
+ value: input.version
356
+ }, _errorFactory)) && (void 0 === input["package"] || "string" === typeof input["package"] || _assertGuard(_exceptionable, {
357
+ method: "typia.createAssert",
358
+ path: _path + "[\"package\"]",
359
+ expected: "(string | undefined)",
360
+ value: input["package"]
361
+ }, _errorFactory)) && (void 0 === input.features || (Array.isArray(input.features) || _assertGuard(_exceptionable, {
362
+ method: "typia.createAssert",
363
+ path: _path + ".features",
364
+ expected: "(Array<string> | undefined)",
365
+ value: input.features
366
+ }, _errorFactory)) && input.features.every((elem, _index11) => "string" === typeof elem || _assertGuard(_exceptionable, {
367
+ method: "typia.createAssert",
368
+ path: _path + ".features[" + _index11 + "]",
369
+ expected: "string",
370
+ value: elem
371
+ }, _errorFactory)) || _assertGuard(_exceptionable, {
372
+ method: "typia.createAssert",
373
+ path: _path + ".features",
374
+ expected: "(Array<string> | undefined)",
375
+ value: input.features
376
+ }, _errorFactory)) && (void 0 === input.optional || "boolean" === typeof input.optional || _assertGuard(_exceptionable, {
377
+ method: "typia.createAssert",
378
+ path: _path + ".optional",
379
+ expected: "(boolean | undefined)",
380
+ value: input.optional
381
+ }, _errorFactory)) && (void 0 === input["default-features"] || "boolean" === typeof input["default-features"] || _assertGuard(_exceptionable, {
382
+ method: "typia.createAssert",
383
+ path: _path + "[\"default-features\"]",
384
+ expected: "(boolean | undefined)",
385
+ value: input["default-features"]
386
+ }, _errorFactory));
387
+ const _ao9 = (input, _path, _exceptionable = true) => ("string" === typeof input.version || _assertGuard(_exceptionable, {
388
+ method: "typia.createAssert",
389
+ path: _path + ".version",
390
+ expected: "string",
391
+ value: input.version
392
+ }, _errorFactory)) && (void 0 === input.registry || "string" === typeof input.registry || _assertGuard(_exceptionable, {
393
+ method: "typia.createAssert",
394
+ path: _path + ".registry",
395
+ expected: "(string | undefined)",
396
+ value: input.registry
397
+ }, _errorFactory)) && (void 0 === input["package"] || "string" === typeof input["package"] || _assertGuard(_exceptionable, {
398
+ method: "typia.createAssert",
399
+ path: _path + "[\"package\"]",
400
+ expected: "(string | undefined)",
401
+ value: input["package"]
402
+ }, _errorFactory)) && (void 0 === input.features || (Array.isArray(input.features) || _assertGuard(_exceptionable, {
403
+ method: "typia.createAssert",
404
+ path: _path + ".features",
405
+ expected: "(Array<string> | undefined)",
406
+ value: input.features
407
+ }, _errorFactory)) && input.features.every((elem, _index12) => "string" === typeof elem || _assertGuard(_exceptionable, {
408
+ method: "typia.createAssert",
409
+ path: _path + ".features[" + _index12 + "]",
410
+ expected: "string",
411
+ value: elem
412
+ }, _errorFactory)) || _assertGuard(_exceptionable, {
413
+ method: "typia.createAssert",
414
+ path: _path + ".features",
415
+ expected: "(Array<string> | undefined)",
416
+ value: input.features
417
+ }, _errorFactory)) && (void 0 === input.optional || "boolean" === typeof input.optional || _assertGuard(_exceptionable, {
418
+ method: "typia.createAssert",
419
+ path: _path + ".optional",
420
+ expected: "(boolean | undefined)",
421
+ value: input.optional
422
+ }, _errorFactory)) && (void 0 === input["default-features"] || "boolean" === typeof input["default-features"] || _assertGuard(_exceptionable, {
423
+ method: "typia.createAssert",
424
+ path: _path + "[\"default-features\"]",
425
+ expected: "(boolean | undefined)",
426
+ value: input["default-features"]
427
+ }, _errorFactory));
428
+ const _ao10 = (input, _path, _exceptionable = true) => false === _exceptionable || Object.keys(input).every((key) => {
429
+ const value = input[key];
430
+ if (void 0 === value) return true;
431
+ return ("object" === typeof value && null !== value && false === Array.isArray(value) || _assertGuard(_exceptionable, {
432
+ method: "typia.createAssert",
433
+ path: _path + _accessExpressionAsString(key),
434
+ expected: "CargoTargetSection",
435
+ value
436
+ }, _errorFactory)) && _ao11(value, _path + _accessExpressionAsString(key), _exceptionable) || _assertGuard(_exceptionable, {
437
+ method: "typia.createAssert",
438
+ path: _path + _accessExpressionAsString(key),
439
+ expected: "CargoTargetSection",
440
+ value
441
+ }, _errorFactory);
442
+ });
443
+ const _ao11 = (input, _path, _exceptionable = true) => (void 0 === input.dependencies || ("object" === typeof input.dependencies && null !== input.dependencies && false === Array.isArray(input.dependencies) || _assertGuard(_exceptionable, {
444
+ method: "typia.createAssert",
445
+ path: _path + ".dependencies",
446
+ expected: "(Record<string, CargoDependency> | undefined)",
447
+ value: input.dependencies
448
+ }, _errorFactory)) && _ao5(input.dependencies, _path + ".dependencies", _exceptionable) || _assertGuard(_exceptionable, {
449
+ method: "typia.createAssert",
450
+ path: _path + ".dependencies",
451
+ expected: "(Record<string, CargoDependency> | undefined)",
452
+ value: input.dependencies
453
+ }, _errorFactory)) && (void 0 === input["dev-dependencies"] || ("object" === typeof input["dev-dependencies"] && null !== input["dev-dependencies"] && false === Array.isArray(input["dev-dependencies"]) || _assertGuard(_exceptionable, {
454
+ method: "typia.createAssert",
455
+ path: _path + "[\"dev-dependencies\"]",
456
+ expected: "(Record<string, CargoDependency> | undefined)",
457
+ value: input["dev-dependencies"]
458
+ }, _errorFactory)) && _ao5(input["dev-dependencies"], _path + "[\"dev-dependencies\"]", _exceptionable) || _assertGuard(_exceptionable, {
459
+ method: "typia.createAssert",
460
+ path: _path + "[\"dev-dependencies\"]",
461
+ expected: "(Record<string, CargoDependency> | undefined)",
462
+ value: input["dev-dependencies"]
463
+ }, _errorFactory)) && (void 0 === input["build-dependencies"] || ("object" === typeof input["build-dependencies"] && null !== input["build-dependencies"] && false === Array.isArray(input["build-dependencies"]) || _assertGuard(_exceptionable, {
464
+ method: "typia.createAssert",
465
+ path: _path + "[\"build-dependencies\"]",
466
+ expected: "(Record<string, CargoDependency> | undefined)",
467
+ value: input["build-dependencies"]
468
+ }, _errorFactory)) && _ao5(input["build-dependencies"], _path + "[\"build-dependencies\"]", _exceptionable) || _assertGuard(_exceptionable, {
469
+ method: "typia.createAssert",
470
+ path: _path + "[\"build-dependencies\"]",
471
+ expected: "(Record<string, CargoDependency> | undefined)",
472
+ value: input["build-dependencies"]
473
+ }, _errorFactory));
474
+ const _au0 = (input, _path, _exceptionable = true) => (() => {
475
+ if (void 0 !== input.workspace) return _ao6(input, _path, _exceptionable);
476
+ else if (void 0 !== input.path) return _ao7(input, _path, _exceptionable);
477
+ else if (void 0 !== input.git) return _ao8(input, _path, _exceptionable);
478
+ else return _ao9(input, _path, _exceptionable);
479
+ })();
480
+ const __is = (input) => "object" === typeof input && null !== input && false === Array.isArray(input) && _io0(input);
481
+ let _errorFactory;
482
+ return (input, errorFactory) => {
483
+ if (false === __is(input)) {
484
+ _errorFactory = errorFactory;
485
+ ((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input && false === Array.isArray(input) || _assertGuard(true, {
486
+ method: "typia.createAssert",
487
+ path: _path + "",
488
+ expected: "CargoManifest",
489
+ value: input
490
+ }, _errorFactory)) && _ao0(input, _path + "", true) || _assertGuard(true, {
491
+ method: "typia.createAssert",
492
+ path: _path + "",
493
+ expected: "CargoManifest",
494
+ value: input
495
+ }, _errorFactory))(input, "$input", true);
496
+ }
497
+ return input;
498
+ };
499
+ })();
75
500
  //#endregion
76
501
  //#region src/plugins/cargo.ts
77
502
  const DEP_FIELDS = [
@@ -267,7 +692,7 @@ async function buildEntry(dir) {
267
692
  try {
268
693
  const filePath = path.join(dir, "Cargo.toml");
269
694
  const content = await readFile(filePath, "utf8");
270
- return new CargoToml(filePath, content, cargoManifestSchema.parse(parse$1(content)));
695
+ return new CargoToml(filePath, content, assertCargoManifest(parse$1(content)));
271
696
  } catch {
272
697
  return;
273
698
  }
@@ -1,4 +1,4 @@
1
- import { s as TegamiPlugin } from "../types-BoQR7Hlg.js";
1
+ import { s as TegamiPlugin } from "../types-B50RK1rR.js";
2
2
 
3
3
  //#region src/plugins/git.d.ts
4
4
  interface GitPluginOptions {
@@ -1,4 +1,4 @@
1
- import { O as WorkspacePackage, k as Draft, s as TegamiPlugin, t as Awaitable, x as TegamiContext, y as PublishPlan } from "../types-BoQR7Hlg.js";
1
+ import { A as WorkspacePackage, b as TegamiContext, j as Draft, s as TegamiPlugin, t as Awaitable, v as PublishPlan } from "../types-B50RK1rR.js";
2
2
  import { GitPluginOptions } from "./git.js";
3
3
 
4
4
  //#region src/plugins/github.d.ts