orval 7.8.0 → 7.10.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/bin/orval.js CHANGED
@@ -24,11 +24,11 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
24
24
  ));
25
25
 
26
26
  // src/bin/orval.ts
27
- var import_core12 = require("@orval/core");
27
+ var import_core13 = require("@orval/core");
28
28
  var import_cac = require("cac");
29
29
 
30
30
  // src/generate.ts
31
- var import_core11 = require("@orval/core");
31
+ var import_core12 = require("@orval/core");
32
32
 
33
33
  // src/import-specs.ts
34
34
  var import_swagger_parser = __toESM(require("@apidevtools/swagger-parser"));
@@ -2677,6 +2677,7 @@ var mock = __toESM(require("@orval/mock"));
2677
2677
  var import_query = __toESM(require("@orval/query"));
2678
2678
  var import_swr = __toESM(require("@orval/swr"));
2679
2679
  var import_zod = __toESM(require("@orval/zod"));
2680
+ var import_mcp = __toESM(require("@orval/mcp"));
2680
2681
  var DEFAULT_CLIENT = import_core.OutputClient.AXIOS;
2681
2682
  var getGeneratorClient = (outputClient, output) => {
2682
2683
  const GENERATOR_CLIENT = {
@@ -2689,7 +2690,8 @@ var getGeneratorClient = (outputClient, output) => {
2689
2690
  swr: (0, import_swr.default)()(),
2690
2691
  zod: (0, import_zod.default)()(),
2691
2692
  hono: (0, import_hono.default)()(),
2692
- fetch: (0, import_fetch.default)()()
2693
+ fetch: (0, import_fetch.default)()(),
2694
+ mcp: (0, import_mcp.default)()()
2693
2695
  };
2694
2696
  const generator = (0, import_core.isFunction)(outputClient) ? outputClient(GENERATOR_CLIENT) : GENERATOR_CLIENT[outputClient];
2695
2697
  if (!generator) {
@@ -3228,15 +3230,15 @@ var importSpecs = async (workspace, options) => {
3228
3230
  };
3229
3231
 
3230
3232
  // src/utils/options.ts
3231
- var import_core7 = require("@orval/core");
3233
+ var import_core8 = require("@orval/core");
3232
3234
  var import_mock2 = require("@orval/mock");
3233
- var import_chalk2 = __toESM(require("chalk"));
3235
+ var import_chalk3 = __toESM(require("chalk"));
3234
3236
 
3235
3237
  // package.json
3236
3238
  var package_default = {
3237
3239
  name: "orval",
3238
3240
  description: "A swagger client generator for typescript",
3239
- version: "7.8.0",
3241
+ version: "7.10.0",
3240
3242
  license: "MIT",
3241
3243
  files: [
3242
3244
  "dist"
@@ -3291,15 +3293,16 @@ var package_default = {
3291
3293
  },
3292
3294
  dependencies: {
3293
3295
  "@apidevtools/swagger-parser": "^10.1.1",
3294
- "@orval/angular": "7.8.0",
3295
- "@orval/axios": "7.8.0",
3296
- "@orval/core": "7.8.0",
3297
- "@orval/fetch": "7.8.0",
3298
- "@orval/hono": "7.8.0",
3299
- "@orval/mock": "7.8.0",
3300
- "@orval/query": "7.8.0",
3301
- "@orval/swr": "7.8.0",
3302
- "@orval/zod": "7.8.0",
3296
+ "@orval/angular": "7.10.0",
3297
+ "@orval/axios": "7.10.0",
3298
+ "@orval/core": "7.10.0",
3299
+ "@orval/fetch": "7.10.0",
3300
+ "@orval/hono": "7.10.0",
3301
+ "@orval/mcp": "7.10.0",
3302
+ "@orval/mock": "7.10.0",
3303
+ "@orval/query": "7.10.0",
3304
+ "@orval/swr": "7.10.0",
3305
+ "@orval/zod": "7.10.0",
3303
3306
  ajv: "^8.17.1",
3304
3307
  cac: "^6.7.14",
3305
3308
  chalk: "^4.1.2",
@@ -3307,7 +3310,7 @@ var package_default = {
3307
3310
  enquirer: "^2.4.1",
3308
3311
  execa: "^5.1.1",
3309
3312
  "find-up": "5.0.0",
3310
- "fs-extra": "^11.2.0",
3313
+ "fs-extra": "^11.3.0",
3311
3314
  "lodash.uniq": "^4.5.0",
3312
3315
  "openapi3-ts": "4.2.2",
3313
3316
  "string-argv": "^0.3.2",
@@ -3470,6 +3473,8 @@ var githubResolver = {
3470
3473
  };
3471
3474
 
3472
3475
  // src/utils/package-json.ts
3476
+ var import_core6 = require("@orval/core");
3477
+ var import_chalk2 = __toESM(require("chalk"));
3473
3478
  var import_find_up = __toESM(require("find-up"));
3474
3479
  var import_fs_extra3 = __toESM(require("fs-extra"));
3475
3480
  var loadPackageJson = async (packageJson, workspace = process.cwd()) => {
@@ -3479,26 +3484,88 @@ var loadPackageJson = async (packageJson, workspace = process.cwd()) => {
3479
3484
  });
3480
3485
  if (pkgPath) {
3481
3486
  const pkg = await Promise.resolve().then(() => __toESM(require(pkgPath)));
3482
- return pkg;
3487
+ return await maybeReplaceCatalog(pkg, workspace);
3483
3488
  }
3484
3489
  return;
3485
3490
  }
3486
3491
  const normalizedPath = normalizePath(packageJson, workspace);
3487
3492
  if (import_fs_extra3.default.existsSync(normalizedPath)) {
3488
3493
  const pkg = await Promise.resolve().then(() => __toESM(require(normalizedPath)));
3489
- return pkg;
3494
+ return await maybeReplaceCatalog(pkg, workspace);
3490
3495
  }
3491
3496
  return;
3492
3497
  };
3498
+ var maybeReplaceCatalog = async (pkg, workspace) => {
3499
+ var _a, _b, _c;
3500
+ if (![
3501
+ ...Object.entries((_a = pkg.dependencies) != null ? _a : {}),
3502
+ ...Object.entries((_b = pkg.devDependencies) != null ? _b : {}),
3503
+ ...Object.entries((_c = pkg.peerDependencies) != null ? _c : {})
3504
+ ].some(([, value]) => (0, import_core6.isString)(value) && value.startsWith("catalog:"))) {
3505
+ return pkg;
3506
+ }
3507
+ const filePath = await (0, import_find_up.default)("pnpm-workspace.yaml", { cwd: workspace });
3508
+ if (!filePath) {
3509
+ (0, import_core6.log)(
3510
+ `\u26A0\uFE0F ${import_chalk2.default.yellow("package.json contains pnpm catalog: in dependencies, but no pnpm-workspace.yaml was found.")}`
3511
+ );
3512
+ return pkg;
3513
+ }
3514
+ const file = await import_fs_extra3.default.readFile(filePath, "utf8");
3515
+ const pnpmWorkspaceFile = js_yaml_default.load(file);
3516
+ performSubstitution(pkg.dependencies, pnpmWorkspaceFile);
3517
+ performSubstitution(pkg.devDependencies, pnpmWorkspaceFile);
3518
+ performSubstitution(pkg.peerDependencies, pnpmWorkspaceFile);
3519
+ return pkg;
3520
+ };
3521
+ var performSubstitution = (dependencies, pnpmWorkspaceFile) => {
3522
+ var _a, _b;
3523
+ if (!dependencies) return;
3524
+ for (const [packageName, version] of Object.entries(dependencies)) {
3525
+ if (version === "catalog:" || version === "catalog:default") {
3526
+ if (!pnpmWorkspaceFile.catalog) {
3527
+ (0, import_core6.log)(
3528
+ `\u26A0\uFE0F ${import_chalk2.default.yellow(`when reading from pnpm-workspace.yaml, catalog: substitution for the package '${packageName}' failed as there were no default catalog.`)}`
3529
+ );
3530
+ continue;
3531
+ }
3532
+ const sub = pnpmWorkspaceFile.catalog[packageName];
3533
+ if (!sub) {
3534
+ (0, import_core6.log)(
3535
+ `\u26A0\uFE0F ${import_chalk2.default.yellow(`when reading from pnpm-workspace.yaml, catalog: substitution for the package '${packageName}' failed as there were no matching package in the default catalog.`)}`
3536
+ );
3537
+ continue;
3538
+ }
3539
+ dependencies[packageName] = sub;
3540
+ } else if (version.startsWith("catalog:")) {
3541
+ const catalogName = version.substring("catalog:".length);
3542
+ const catalog = (_a = pnpmWorkspaceFile.catalogs) == null ? void 0 : _a[catalogName];
3543
+ if (!catalog) {
3544
+ (0, import_core6.log)(
3545
+ `\u26A0\uFE0F ${import_chalk2.default.yellow(`when reading from pnpm-workspace.yaml, '${version}' substitution for the package '${packageName}' failed as there were no matching catalog named '${catalogName}'. (available named catalogs are: ${Object.keys((_b = pnpmWorkspaceFile.catalogs) != null ? _b : {}).join(", ")})`)}`
3546
+ );
3547
+ continue;
3548
+ }
3549
+ const sub = catalog[packageName];
3550
+ if (!sub) {
3551
+ (0, import_core6.log)(
3552
+ `\u26A0\uFE0F ${import_chalk2.default.yellow(`when reading from pnpm-workspace.yaml, '${version}' substitution for the package '${packageName}' failed as there were no package in the catalog named '${catalogName}'. (packages in the catalog are: ${Object.keys(catalog).join(", ")})`)}`
3553
+ );
3554
+ continue;
3555
+ }
3556
+ dependencies[packageName] = sub;
3557
+ }
3558
+ }
3559
+ };
3493
3560
 
3494
3561
  // src/utils/tsconfig.ts
3495
- var import_core6 = require("@orval/core");
3562
+ var import_core7 = require("@orval/core");
3496
3563
  var import_find_up2 = __toESM(require("find-up"));
3497
3564
  var import_fs_extra4 = __toESM(require("fs-extra"));
3498
3565
  var import_tsconfck = require("tsconfck");
3499
3566
  var loadTsconfig = async (tsconfig, workspace = process.cwd()) => {
3500
3567
  var _a, _b;
3501
- if ((0, import_core6.isUndefined)(tsconfig)) {
3568
+ if ((0, import_core7.isUndefined)(tsconfig)) {
3502
3569
  const configPath = await (0, import_find_up2.default)(["tsconfig.json", "jsconfig.json"], {
3503
3570
  cwd: workspace
3504
3571
  });
@@ -3508,7 +3575,7 @@ var loadTsconfig = async (tsconfig, workspace = process.cwd()) => {
3508
3575
  }
3509
3576
  return;
3510
3577
  }
3511
- if ((0, import_core6.isString)(tsconfig)) {
3578
+ if ((0, import_core7.isString)(tsconfig)) {
3512
3579
  const normalizedPath = normalizePath(tsconfig, workspace);
3513
3580
  if (import_fs_extra4.default.existsSync(normalizedPath)) {
3514
3581
  const config = await (0, import_tsconfck.parse)(normalizedPath);
@@ -3519,26 +3586,51 @@ var loadTsconfig = async (tsconfig, workspace = process.cwd()) => {
3519
3586
  }
3520
3587
  return;
3521
3588
  }
3522
- if ((0, import_core6.isObject)(tsconfig)) {
3589
+ if ((0, import_core7.isObject)(tsconfig)) {
3523
3590
  return tsconfig;
3524
3591
  }
3525
3592
  return;
3526
3593
  };
3527
3594
 
3528
3595
  // src/utils/options.ts
3596
+ var createFormData = (workspace, formData) => {
3597
+ var _a;
3598
+ const defaultArrayHandling = import_core8.FormDataArrayHandling.SERIALIZE;
3599
+ if (formData === void 0)
3600
+ return { disabled: false, arrayHandling: defaultArrayHandling };
3601
+ if ((0, import_core8.isBoolean)(formData))
3602
+ return { disabled: !formData, arrayHandling: defaultArrayHandling };
3603
+ if ((0, import_core8.isString)(formData))
3604
+ return {
3605
+ disabled: false,
3606
+ mutator: normalizeMutator(workspace, formData),
3607
+ arrayHandling: defaultArrayHandling
3608
+ };
3609
+ if ("mutator" in formData || "arrayHandling" in formData)
3610
+ return {
3611
+ disabled: false,
3612
+ mutator: normalizeMutator(workspace, formData.mutator),
3613
+ arrayHandling: (_a = formData.arrayHandling) != null ? _a : defaultArrayHandling
3614
+ };
3615
+ return {
3616
+ disabled: false,
3617
+ mutator: normalizeMutator(workspace, formData),
3618
+ arrayHandling: defaultArrayHandling
3619
+ };
3620
+ };
3529
3621
  var normalizeOptions = async (optionsExport, workspace = process.cwd(), globalOptions = {}) => {
3530
- var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __, _$, _aa, _ba, _ca, _da, _ea, _fa, _ga, _ha, _ia, _ja, _ka, _la, _ma, _na, _oa, _pa, _qa, _ra, _sa, _ta, _ua, _va, _wa, _xa, _ya, _za, _Aa, _Ba, _Ca, _Da, _Ea, _Fa, _Ga, _Ha, _Ia, _Ja, _Ka, _La, _Ma, _Na, _Oa, _Pa, _Qa, _Ra, _Sa, _Ta, _Ua, _Va, _Wa, _Xa, _Ya, _Za, __a, _$a, _ab, _bb, _cb, _db, _eb, _fb, _gb, _hb, _ib, _jb, _kb, _lb, _mb, _nb, _ob, _pb, _qb, _rb, _sb, _tb, _ub, _vb, _wb, _xb, _yb, _zb, _Ab, _Bb, _Cb, _Db, _Eb, _Fb, _Gb, _Hb, _Ib, _Jb, _Kb, _Lb, _Mb, _Nb, _Ob, _Pb, _Qb, _Rb, _Sb, _Tb, _Ub, _Vb, _Wb, _Xb, _Yb, _Zb, __b, _$b, _ac, _bc, _cc, _dc, _ec;
3531
- const options = await ((0, import_core7.isFunction)(optionsExport) ? optionsExport() : optionsExport);
3622
+ var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j, _k, _l, _m, _n, _o, _p, _q, _r, _s, _t, _u, _v, _w, _x, _y, _z, _A, _B, _C, _D, _E, _F, _G, _H, _I, _J, _K, _L, _M, _N, _O, _P, _Q, _R, _S, _T, _U, _V, _W, _X, _Y, _Z, __, _$, _aa, _ba, _ca, _da, _ea, _fa, _ga, _ha, _ia, _ja, _ka, _la, _ma, _na, _oa, _pa, _qa, _ra, _sa, _ta, _ua, _va, _wa, _xa, _ya, _za, _Aa, _Ba, _Ca, _Da, _Ea, _Fa, _Ga, _Ha, _Ia, _Ja, _Ka, _La, _Ma, _Na, _Oa, _Pa, _Qa, _Ra, _Sa, _Ta, _Ua, _Va, _Wa, _Xa, _Ya, _Za, __a, _$a, _ab, _bb, _cb, _db, _eb, _fb, _gb, _hb, _ib, _jb, _kb, _lb, _mb, _nb, _ob, _pb, _qb, _rb, _sb, _tb, _ub, _vb, _wb, _xb, _yb, _zb, _Ab, _Bb, _Cb, _Db, _Eb, _Fb, _Gb, _Hb, _Ib, _Jb, _Kb, _Lb, _Mb, _Nb, _Ob, _Pb, _Qb, _Rb, _Sb, _Tb, _Ub, _Vb, _Wb, _Xb, _Yb, _Zb, __b, _$b, _ac, _bc, _cc, _dc, _ec, _fc, _gc, _hc, _ic, _jc, _kc, _lc, _mc;
3623
+ const options = await ((0, import_core8.isFunction)(optionsExport) ? optionsExport() : optionsExport);
3532
3624
  if (!options.input) {
3533
- (0, import_core7.createLogger)().error(import_chalk2.default.red(`Config require an input`));
3625
+ (0, import_core8.createLogger)().error(import_chalk3.default.red(`Config require an input`));
3534
3626
  process.exit(1);
3535
3627
  }
3536
3628
  if (!options.output) {
3537
- (0, import_core7.createLogger)().error(import_chalk2.default.red(`Config require an output`));
3629
+ (0, import_core8.createLogger)().error(import_chalk3.default.red(`Config require an output`));
3538
3630
  process.exit(1);
3539
3631
  }
3540
- const inputOptions = (0, import_core7.isString)(options.input) ? { target: options.input } : options.input;
3541
- const outputOptions = (0, import_core7.isString)(options.output) ? { target: options.output } : options.output;
3632
+ const inputOptions = (0, import_core8.isString)(options.input) ? { target: options.input } : options.input;
3633
+ const outputOptions = (0, import_core8.isString)(options.output) ? { target: options.output } : options.output;
3542
3634
  const outputWorkspace = normalizePath(
3543
3635
  outputOptions.workspace || "",
3544
3636
  workspace
@@ -3556,7 +3648,8 @@ var normalizeOptions = async (optionsExport, workspace = process.cwd(), globalOp
3556
3648
  let mock2;
3557
3649
  if (typeof mockOption === "boolean" && mockOption) {
3558
3650
  mock2 = import_mock2.DEFAULT_MOCK_OPTIONS;
3559
- } else if ((0, import_core7.isFunction)(mockOption)) {
3651
+ } else if ((0, import_core8.isFunction)(mockOption)) {
3652
+ mock2 = mockOption;
3560
3653
  } else if (!mockOption) {
3561
3654
  mock2 = void 0;
3562
3655
  } else {
@@ -3587,7 +3680,7 @@ var normalizeOptions = async (optionsExport, workspace = process.cwd(), globalOp
3587
3680
  )
3588
3681
  },
3589
3682
  converterOptions: (_d = inputOptions.converterOptions) != null ? _d : {},
3590
- parserOptions: (0, import_core7.mergeDeep)(
3683
+ parserOptions: (0, import_core8.mergeDeep)(
3591
3684
  parserDefaultOptions,
3592
3685
  (_e = inputOptions.parserOptions) != null ? _e : {}
3593
3686
  ),
@@ -3596,11 +3689,11 @@ var normalizeOptions = async (optionsExport, workspace = process.cwd(), globalOp
3596
3689
  output: {
3597
3690
  target: globalOptions.output ? normalizePath(globalOptions.output, process.cwd()) : normalizePath(outputOptions.target, outputWorkspace),
3598
3691
  schemas: normalizePath(outputOptions.schemas, outputWorkspace),
3599
- namingConvention: outputOptions.namingConvention || import_core7.NamingConvention.CAMEL_CASE,
3692
+ namingConvention: outputOptions.namingConvention || import_core8.NamingConvention.CAMEL_CASE,
3600
3693
  fileExtension: outputOptions.fileExtension || defaultFileExtension,
3601
3694
  workspace: outputOptions.workspace ? outputWorkspace : void 0,
3602
- client: (_g = (_f = outputOptions.client) != null ? _f : client) != null ? _g : import_core7.OutputClient.AXIOS_FUNCTIONS,
3603
- httpClient: (_i = (_h = outputOptions.httpClient) != null ? _h : httpClient) != null ? _i : import_core7.OutputHttpClient.AXIOS,
3695
+ client: (_g = (_f = outputOptions.client) != null ? _f : client) != null ? _g : import_core8.OutputClient.AXIOS_FUNCTIONS,
3696
+ httpClient: (_i = (_h = outputOptions.httpClient) != null ? _h : httpClient) != null ? _i : import_core8.OutputHttpClient.AXIOS,
3604
3697
  mode: normalizeOutputMode((_j = outputOptions.mode) != null ? _j : mode),
3605
3698
  mock: mock2,
3606
3699
  clean: (_l = (_k = outputOptions.clean) != null ? _k : clean) != null ? _l : false,
@@ -3619,17 +3712,20 @@ var normalizeOptions = async (optionsExport, workspace = process.cwd(), globalOp
3619
3712
  mock: {
3620
3713
  arrayMin: (_y = (_x = (_w = outputOptions.override) == null ? void 0 : _w.mock) == null ? void 0 : _x.arrayMin) != null ? _y : 1,
3621
3714
  arrayMax: (_B = (_A = (_z = outputOptions.override) == null ? void 0 : _z.mock) == null ? void 0 : _A.arrayMax) != null ? _B : 10,
3622
- ...(_D = (_C = outputOptions.override) == null ? void 0 : _C.mock) != null ? _D : {}
3715
+ stringMin: (_E = (_D = (_C = outputOptions.override) == null ? void 0 : _C.mock) == null ? void 0 : _D.stringMin) != null ? _E : 10,
3716
+ stringMax: (_H = (_G = (_F = outputOptions.override) == null ? void 0 : _F.mock) == null ? void 0 : _G.stringMax) != null ? _H : 20,
3717
+ fractionDigits: (_K = (_J = (_I = outputOptions.override) == null ? void 0 : _I.mock) == null ? void 0 : _J.fractionDigits) != null ? _K : 2,
3718
+ ...(_L = outputOptions.override) == null ? void 0 : _L.mock
3623
3719
  },
3624
3720
  operations: normalizeOperationsAndTags(
3625
- (_F = (_E = outputOptions.override) == null ? void 0 : _E.operations) != null ? _F : {},
3721
+ (_N = (_M = outputOptions.override) == null ? void 0 : _M.operations) != null ? _N : {},
3626
3722
  outputWorkspace,
3627
3723
  {
3628
3724
  query: globalQueryOptions
3629
3725
  }
3630
3726
  ),
3631
3727
  tags: normalizeOperationsAndTags(
3632
- (_H = (_G = outputOptions.override) == null ? void 0 : _G.tags) != null ? _H : {},
3728
+ (_P = (_O = outputOptions.override) == null ? void 0 : _O.tags) != null ? _P : {},
3633
3729
  outputWorkspace,
3634
3730
  {
3635
3731
  query: globalQueryOptions
@@ -3637,129 +3733,130 @@ var normalizeOptions = async (optionsExport, workspace = process.cwd(), globalOp
3637
3733
  ),
3638
3734
  mutator: normalizeMutator(
3639
3735
  outputWorkspace,
3640
- (_I = outputOptions.override) == null ? void 0 : _I.mutator
3736
+ (_Q = outputOptions.override) == null ? void 0 : _Q.mutator
3641
3737
  ),
3642
- formData: (_M = !(0, import_core7.isBoolean)((_J = outputOptions.override) == null ? void 0 : _J.formData) ? normalizeMutator(
3738
+ formData: createFormData(
3643
3739
  outputWorkspace,
3644
- (_K = outputOptions.override) == null ? void 0 : _K.formData
3645
- ) : (_L = outputOptions.override) == null ? void 0 : _L.formData) != null ? _M : true,
3646
- formUrlEncoded: (_Q = !(0, import_core7.isBoolean)((_N = outputOptions.override) == null ? void 0 : _N.formUrlEncoded) ? normalizeMutator(
3740
+ (_R = outputOptions.override) == null ? void 0 : _R.formData
3741
+ ),
3742
+ formUrlEncoded: (_V = !(0, import_core8.isBoolean)((_S = outputOptions.override) == null ? void 0 : _S.formUrlEncoded) ? normalizeMutator(
3647
3743
  outputWorkspace,
3648
- (_O = outputOptions.override) == null ? void 0 : _O.formUrlEncoded
3649
- ) : (_P = outputOptions.override) == null ? void 0 : _P.formUrlEncoded) != null ? _Q : true,
3744
+ (_T = outputOptions.override) == null ? void 0 : _T.formUrlEncoded
3745
+ ) : (_U = outputOptions.override) == null ? void 0 : _U.formUrlEncoded) != null ? _V : true,
3650
3746
  paramsSerializer: normalizeMutator(
3651
3747
  outputWorkspace,
3652
- (_R = outputOptions.override) == null ? void 0 : _R.paramsSerializer
3748
+ (_W = outputOptions.override) == null ? void 0 : _W.paramsSerializer
3653
3749
  ),
3654
- header: ((_S = outputOptions.override) == null ? void 0 : _S.header) === false ? false : (0, import_core7.isFunction)((_T = outputOptions.override) == null ? void 0 : _T.header) ? (_U = outputOptions.override) == null ? void 0 : _U.header : getDefaultFilesHeader,
3655
- requestOptions: (_W = (_V = outputOptions.override) == null ? void 0 : _V.requestOptions) != null ? _W : true,
3750
+ header: ((_X = outputOptions.override) == null ? void 0 : _X.header) === false ? false : (0, import_core8.isFunction)((_Y = outputOptions.override) == null ? void 0 : _Y.header) ? (_Z = outputOptions.override) == null ? void 0 : _Z.header : getDefaultFilesHeader,
3751
+ requestOptions: (_$ = (__ = outputOptions.override) == null ? void 0 : __.requestOptions) != null ? _$ : true,
3656
3752
  components: {
3657
3753
  schemas: {
3658
- suffix: import_core7.RefComponentSuffix.schemas,
3659
- itemSuffix: (__ = (_Z = (_Y = (_X = outputOptions.override) == null ? void 0 : _X.components) == null ? void 0 : _Y.schemas) == null ? void 0 : _Z.itemSuffix) != null ? __ : "Item",
3660
- ...(_ba = (_aa = (_$ = outputOptions.override) == null ? void 0 : _$.components) == null ? void 0 : _aa.schemas) != null ? _ba : {}
3754
+ suffix: import_core8.RefComponentSuffix.schemas,
3755
+ itemSuffix: (_da = (_ca = (_ba = (_aa = outputOptions.override) == null ? void 0 : _aa.components) == null ? void 0 : _ba.schemas) == null ? void 0 : _ca.itemSuffix) != null ? _da : "Item",
3756
+ ...(_ga = (_fa = (_ea = outputOptions.override) == null ? void 0 : _ea.components) == null ? void 0 : _fa.schemas) != null ? _ga : {}
3661
3757
  },
3662
3758
  responses: {
3663
- suffix: import_core7.RefComponentSuffix.responses,
3664
- ...(_ea = (_da = (_ca = outputOptions.override) == null ? void 0 : _ca.components) == null ? void 0 : _da.responses) != null ? _ea : {}
3759
+ suffix: import_core8.RefComponentSuffix.responses,
3760
+ ...(_ja = (_ia = (_ha = outputOptions.override) == null ? void 0 : _ha.components) == null ? void 0 : _ia.responses) != null ? _ja : {}
3665
3761
  },
3666
3762
  parameters: {
3667
- suffix: import_core7.RefComponentSuffix.parameters,
3668
- ...(_ha = (_ga = (_fa = outputOptions.override) == null ? void 0 : _fa.components) == null ? void 0 : _ga.parameters) != null ? _ha : {}
3763
+ suffix: import_core8.RefComponentSuffix.parameters,
3764
+ ...(_ma = (_la = (_ka = outputOptions.override) == null ? void 0 : _ka.components) == null ? void 0 : _la.parameters) != null ? _ma : {}
3669
3765
  },
3670
3766
  requestBodies: {
3671
- suffix: import_core7.RefComponentSuffix.requestBodies,
3672
- ...(_ka = (_ja = (_ia = outputOptions.override) == null ? void 0 : _ia.components) == null ? void 0 : _ja.requestBodies) != null ? _ka : {}
3767
+ suffix: import_core8.RefComponentSuffix.requestBodies,
3768
+ ...(_pa = (_oa = (_na = outputOptions.override) == null ? void 0 : _na.components) == null ? void 0 : _oa.requestBodies) != null ? _pa : {}
3673
3769
  }
3674
3770
  },
3675
- hono: normalizeHonoOptions((_la = outputOptions.override) == null ? void 0 : _la.hono, workspace),
3771
+ hono: normalizeHonoOptions((_qa = outputOptions.override) == null ? void 0 : _qa.hono, workspace),
3772
+ jsDoc: normalizeJSDocOptions((_ra = outputOptions.override) == null ? void 0 : _ra.jsDoc),
3676
3773
  query: globalQueryOptions,
3677
3774
  zod: {
3678
3775
  strict: {
3679
- param: (_pa = (_oa = (_na = (_ma = outputOptions.override) == null ? void 0 : _ma.zod) == null ? void 0 : _na.strict) == null ? void 0 : _oa.param) != null ? _pa : false,
3680
- query: (_ta = (_sa = (_ra = (_qa = outputOptions.override) == null ? void 0 : _qa.zod) == null ? void 0 : _ra.strict) == null ? void 0 : _sa.query) != null ? _ta : false,
3681
- header: (_xa = (_wa = (_va = (_ua = outputOptions.override) == null ? void 0 : _ua.zod) == null ? void 0 : _va.strict) == null ? void 0 : _wa.header) != null ? _xa : false,
3682
- body: (_Ba = (_Aa = (_za = (_ya = outputOptions.override) == null ? void 0 : _ya.zod) == null ? void 0 : _za.strict) == null ? void 0 : _Aa.body) != null ? _Ba : false,
3683
- response: (_Fa = (_Ea = (_Da = (_Ca = outputOptions.override) == null ? void 0 : _Ca.zod) == null ? void 0 : _Da.strict) == null ? void 0 : _Ea.response) != null ? _Fa : false
3776
+ param: (_va = (_ua = (_ta = (_sa = outputOptions.override) == null ? void 0 : _sa.zod) == null ? void 0 : _ta.strict) == null ? void 0 : _ua.param) != null ? _va : false,
3777
+ query: (_za = (_ya = (_xa = (_wa = outputOptions.override) == null ? void 0 : _wa.zod) == null ? void 0 : _xa.strict) == null ? void 0 : _ya.query) != null ? _za : false,
3778
+ header: (_Da = (_Ca = (_Ba = (_Aa = outputOptions.override) == null ? void 0 : _Aa.zod) == null ? void 0 : _Ba.strict) == null ? void 0 : _Ca.header) != null ? _Da : false,
3779
+ body: (_Ha = (_Ga = (_Fa = (_Ea = outputOptions.override) == null ? void 0 : _Ea.zod) == null ? void 0 : _Fa.strict) == null ? void 0 : _Ga.body) != null ? _Ha : false,
3780
+ response: (_La = (_Ka = (_Ja = (_Ia = outputOptions.override) == null ? void 0 : _Ia.zod) == null ? void 0 : _Ja.strict) == null ? void 0 : _Ka.response) != null ? _La : false
3684
3781
  },
3685
3782
  generate: {
3686
- param: (_Ja = (_Ia = (_Ha = (_Ga = outputOptions.override) == null ? void 0 : _Ga.zod) == null ? void 0 : _Ha.generate) == null ? void 0 : _Ia.param) != null ? _Ja : true,
3687
- query: (_Na = (_Ma = (_La = (_Ka = outputOptions.override) == null ? void 0 : _Ka.zod) == null ? void 0 : _La.generate) == null ? void 0 : _Ma.query) != null ? _Na : true,
3688
- header: (_Ra = (_Qa = (_Pa = (_Oa = outputOptions.override) == null ? void 0 : _Oa.zod) == null ? void 0 : _Pa.generate) == null ? void 0 : _Qa.header) != null ? _Ra : true,
3689
- body: (_Va = (_Ua = (_Ta = (_Sa = outputOptions.override) == null ? void 0 : _Sa.zod) == null ? void 0 : _Ta.generate) == null ? void 0 : _Ua.body) != null ? _Va : true,
3690
- response: (_Za = (_Ya = (_Xa = (_Wa = outputOptions.override) == null ? void 0 : _Wa.zod) == null ? void 0 : _Xa.generate) == null ? void 0 : _Ya.response) != null ? _Za : true
3783
+ param: (_Pa = (_Oa = (_Na = (_Ma = outputOptions.override) == null ? void 0 : _Ma.zod) == null ? void 0 : _Na.generate) == null ? void 0 : _Oa.param) != null ? _Pa : true,
3784
+ query: (_Ta = (_Sa = (_Ra = (_Qa = outputOptions.override) == null ? void 0 : _Qa.zod) == null ? void 0 : _Ra.generate) == null ? void 0 : _Sa.query) != null ? _Ta : true,
3785
+ header: (_Xa = (_Wa = (_Va = (_Ua = outputOptions.override) == null ? void 0 : _Ua.zod) == null ? void 0 : _Va.generate) == null ? void 0 : _Wa.header) != null ? _Xa : true,
3786
+ body: (_$a = (__a = (_Za = (_Ya = outputOptions.override) == null ? void 0 : _Ya.zod) == null ? void 0 : _Za.generate) == null ? void 0 : __a.body) != null ? _$a : true,
3787
+ response: (_db = (_cb = (_bb = (_ab = outputOptions.override) == null ? void 0 : _ab.zod) == null ? void 0 : _bb.generate) == null ? void 0 : _cb.response) != null ? _db : true
3691
3788
  },
3692
3789
  coerce: {
3693
- param: (_bb = (_ab = (_$a = (__a = outputOptions.override) == null ? void 0 : __a.zod) == null ? void 0 : _$a.coerce) == null ? void 0 : _ab.param) != null ? _bb : false,
3694
- query: (_fb = (_eb = (_db = (_cb = outputOptions.override) == null ? void 0 : _cb.zod) == null ? void 0 : _db.coerce) == null ? void 0 : _eb.query) != null ? _fb : false,
3695
- header: (_jb = (_ib = (_hb = (_gb = outputOptions.override) == null ? void 0 : _gb.zod) == null ? void 0 : _hb.coerce) == null ? void 0 : _ib.header) != null ? _jb : false,
3696
- body: (_nb = (_mb = (_lb = (_kb = outputOptions.override) == null ? void 0 : _kb.zod) == null ? void 0 : _lb.coerce) == null ? void 0 : _mb.body) != null ? _nb : false,
3697
- response: (_rb = (_qb = (_pb = (_ob = outputOptions.override) == null ? void 0 : _ob.zod) == null ? void 0 : _pb.coerce) == null ? void 0 : _qb.response) != null ? _rb : false
3790
+ param: (_hb = (_gb = (_fb = (_eb = outputOptions.override) == null ? void 0 : _eb.zod) == null ? void 0 : _fb.coerce) == null ? void 0 : _gb.param) != null ? _hb : false,
3791
+ query: (_lb = (_kb = (_jb = (_ib = outputOptions.override) == null ? void 0 : _ib.zod) == null ? void 0 : _jb.coerce) == null ? void 0 : _kb.query) != null ? _lb : false,
3792
+ header: (_pb = (_ob = (_nb = (_mb = outputOptions.override) == null ? void 0 : _mb.zod) == null ? void 0 : _nb.coerce) == null ? void 0 : _ob.header) != null ? _pb : false,
3793
+ body: (_tb = (_sb = (_rb = (_qb = outputOptions.override) == null ? void 0 : _qb.zod) == null ? void 0 : _rb.coerce) == null ? void 0 : _sb.body) != null ? _tb : false,
3794
+ response: (_xb = (_wb = (_vb = (_ub = outputOptions.override) == null ? void 0 : _ub.zod) == null ? void 0 : _vb.coerce) == null ? void 0 : _wb.response) != null ? _xb : false
3698
3795
  },
3699
3796
  preprocess: {
3700
- ...((_ub = (_tb = (_sb = outputOptions.override) == null ? void 0 : _sb.zod) == null ? void 0 : _tb.preprocess) == null ? void 0 : _ub.param) ? {
3797
+ ...((_Ab = (_zb = (_yb = outputOptions.override) == null ? void 0 : _yb.zod) == null ? void 0 : _zb.preprocess) == null ? void 0 : _Ab.param) ? {
3701
3798
  param: normalizeMutator(
3702
3799
  workspace,
3703
3800
  outputOptions.override.zod.preprocess.param
3704
3801
  )
3705
3802
  } : {},
3706
- ...((_xb = (_wb = (_vb = outputOptions.override) == null ? void 0 : _vb.zod) == null ? void 0 : _wb.preprocess) == null ? void 0 : _xb.query) ? {
3803
+ ...((_Db = (_Cb = (_Bb = outputOptions.override) == null ? void 0 : _Bb.zod) == null ? void 0 : _Cb.preprocess) == null ? void 0 : _Db.query) ? {
3707
3804
  query: normalizeMutator(
3708
3805
  workspace,
3709
3806
  outputOptions.override.zod.preprocess.query
3710
3807
  )
3711
3808
  } : {},
3712
- ...((_Ab = (_zb = (_yb = outputOptions.override) == null ? void 0 : _yb.zod) == null ? void 0 : _zb.preprocess) == null ? void 0 : _Ab.header) ? {
3809
+ ...((_Gb = (_Fb = (_Eb = outputOptions.override) == null ? void 0 : _Eb.zod) == null ? void 0 : _Fb.preprocess) == null ? void 0 : _Gb.header) ? {
3713
3810
  header: normalizeMutator(
3714
3811
  workspace,
3715
3812
  outputOptions.override.zod.preprocess.header
3716
3813
  )
3717
3814
  } : {},
3718
- ...((_Db = (_Cb = (_Bb = outputOptions.override) == null ? void 0 : _Bb.zod) == null ? void 0 : _Cb.preprocess) == null ? void 0 : _Db.body) ? {
3815
+ ...((_Jb = (_Ib = (_Hb = outputOptions.override) == null ? void 0 : _Hb.zod) == null ? void 0 : _Ib.preprocess) == null ? void 0 : _Jb.body) ? {
3719
3816
  body: normalizeMutator(
3720
3817
  workspace,
3721
3818
  outputOptions.override.zod.preprocess.body
3722
3819
  )
3723
3820
  } : {},
3724
- ...((_Gb = (_Fb = (_Eb = outputOptions.override) == null ? void 0 : _Eb.zod) == null ? void 0 : _Fb.preprocess) == null ? void 0 : _Gb.response) ? {
3821
+ ...((_Mb = (_Lb = (_Kb = outputOptions.override) == null ? void 0 : _Kb.zod) == null ? void 0 : _Lb.preprocess) == null ? void 0 : _Mb.response) ? {
3725
3822
  response: normalizeMutator(
3726
3823
  workspace,
3727
3824
  outputOptions.override.zod.preprocess.response
3728
3825
  )
3729
3826
  } : {}
3730
3827
  },
3731
- generateEachHttpStatus: (_Jb = (_Ib = (_Hb = outputOptions.override) == null ? void 0 : _Hb.zod) == null ? void 0 : _Ib.generateEachHttpStatus) != null ? _Jb : false,
3732
- dateTimeOptions: (_Mb = (_Lb = (_Kb = outputOptions.override) == null ? void 0 : _Kb.zod) == null ? void 0 : _Lb.dateTimeOptions) != null ? _Mb : {}
3828
+ generateEachHttpStatus: (_Pb = (_Ob = (_Nb = outputOptions.override) == null ? void 0 : _Nb.zod) == null ? void 0 : _Ob.generateEachHttpStatus) != null ? _Pb : false,
3829
+ dateTimeOptions: (_Sb = (_Rb = (_Qb = outputOptions.override) == null ? void 0 : _Qb.zod) == null ? void 0 : _Rb.dateTimeOptions) != null ? _Sb : {}
3733
3830
  },
3734
3831
  swr: {
3735
- ...(_Ob = (_Nb = outputOptions.override) == null ? void 0 : _Nb.swr) != null ? _Ob : {}
3832
+ ...(_Ub = (_Tb = outputOptions.override) == null ? void 0 : _Tb.swr) != null ? _Ub : {}
3736
3833
  },
3737
3834
  angular: {
3738
- provideIn: (_Rb = (_Qb = (_Pb = outputOptions.override) == null ? void 0 : _Pb.angular) == null ? void 0 : _Qb.provideIn) != null ? _Rb : "root"
3835
+ provideIn: (_Xb = (_Wb = (_Vb = outputOptions.override) == null ? void 0 : _Vb.angular) == null ? void 0 : _Wb.provideIn) != null ? _Xb : "root"
3739
3836
  },
3740
3837
  fetch: {
3741
- includeHttpResponseReturnType: (_Ub = (_Tb = (_Sb = outputOptions.override) == null ? void 0 : _Sb.fetch) == null ? void 0 : _Tb.includeHttpResponseReturnType) != null ? _Ub : true,
3742
- ...(_Wb = (_Vb = outputOptions.override) == null ? void 0 : _Vb.fetch) != null ? _Wb : {}
3838
+ includeHttpResponseReturnType: (__b = (_Zb = (_Yb = outputOptions.override) == null ? void 0 : _Yb.fetch) == null ? void 0 : _Zb.includeHttpResponseReturnType) != null ? __b : true,
3839
+ ...(_ac = (_$b = outputOptions.override) == null ? void 0 : _$b.fetch) != null ? _ac : {}
3743
3840
  },
3744
- useDates: ((_Xb = outputOptions.override) == null ? void 0 : _Xb.useDates) || false,
3745
- useDeprecatedOperations: (_Zb = (_Yb = outputOptions.override) == null ? void 0 : _Yb.useDeprecatedOperations) != null ? _Zb : true,
3746
- useNativeEnums: (_$b = (__b = outputOptions.override) == null ? void 0 : __b.useNativeEnums) != null ? _$b : false,
3747
- suppressReadonlyModifier: ((_ac = outputOptions.override) == null ? void 0 : _ac.suppressReadonlyModifier) || false
3841
+ useDates: ((_bc = outputOptions.override) == null ? void 0 : _bc.useDates) || false,
3842
+ useDeprecatedOperations: (_dc = (_cc = outputOptions.override) == null ? void 0 : _cc.useDeprecatedOperations) != null ? _dc : true,
3843
+ enumGenerationType: ((_fc = (_ec = outputOptions.override) == null ? void 0 : _ec.useNativeEnums) != null ? _fc : false) ? "enum" : (_hc = (_gc = outputOptions.override) == null ? void 0 : _gc.enumGenerationType) != null ? _hc : "const",
3844
+ suppressReadonlyModifier: ((_ic = outputOptions.override) == null ? void 0 : _ic.suppressReadonlyModifier) || false
3748
3845
  },
3749
- allParamsOptional: (_bc = outputOptions.allParamsOptional) != null ? _bc : false,
3750
- urlEncodeParameters: (_cc = outputOptions.urlEncodeParameters) != null ? _cc : false,
3751
- optionsParamRequired: (_dc = outputOptions.optionsParamRequired) != null ? _dc : false,
3752
- propertySortOrder: (_ec = outputOptions.propertySortOrder) != null ? _ec : import_core7.PropertySortOrder.SPECIFICATION
3846
+ allParamsOptional: (_jc = outputOptions.allParamsOptional) != null ? _jc : false,
3847
+ urlEncodeParameters: (_kc = outputOptions.urlEncodeParameters) != null ? _kc : false,
3848
+ optionsParamRequired: (_lc = outputOptions.optionsParamRequired) != null ? _lc : false,
3849
+ propertySortOrder: (_mc = outputOptions.propertySortOrder) != null ? _mc : import_core8.PropertySortOrder.SPECIFICATION
3753
3850
  },
3754
3851
  hooks: options.hooks ? normalizeHooks(options.hooks) : {}
3755
3852
  };
3756
3853
  if (!normalizedOptions.input.target) {
3757
- (0, import_core7.createLogger)().error(import_chalk2.default.red(`Config require an input target`));
3854
+ (0, import_core8.createLogger)().error(import_chalk3.default.red(`Config require an input target`));
3758
3855
  process.exit(1);
3759
3856
  }
3760
3857
  if (!normalizedOptions.output.target && !normalizedOptions.output.schemas) {
3761
- (0, import_core7.createLogger)().error(
3762
- import_chalk2.default.red(`Config require an output target or schemas`)
3858
+ (0, import_core8.createLogger)().error(
3859
+ import_chalk3.default.red(`Config require an output target or schemas`)
3763
3860
  );
3764
3861
  process.exit(1);
3765
3862
  }
@@ -3771,36 +3868,36 @@ var parserDefaultOptions = {
3771
3868
  };
3772
3869
  var normalizeMutator = (workspace, mutator) => {
3773
3870
  var _a;
3774
- if ((0, import_core7.isObject)(mutator)) {
3871
+ if ((0, import_core8.isObject)(mutator)) {
3775
3872
  if (!mutator.path) {
3776
- (0, import_core7.createLogger)().error(import_chalk2.default.red(`Mutator need a path`));
3873
+ (0, import_core8.createLogger)().error(import_chalk3.default.red(`Mutator need a path`));
3777
3874
  process.exit(1);
3778
3875
  }
3779
3876
  return {
3780
3877
  ...mutator,
3781
- path: import_core7.upath.resolve(workspace, mutator.path),
3878
+ path: import_core8.upath.resolve(workspace, mutator.path),
3782
3879
  default: (_a = mutator.default || !mutator.name) != null ? _a : false
3783
3880
  };
3784
3881
  }
3785
- if ((0, import_core7.isString)(mutator)) {
3882
+ if ((0, import_core8.isString)(mutator)) {
3786
3883
  return {
3787
- path: import_core7.upath.resolve(workspace, mutator),
3884
+ path: import_core8.upath.resolve(workspace, mutator),
3788
3885
  default: true
3789
3886
  };
3790
3887
  }
3791
3888
  return mutator;
3792
3889
  };
3793
3890
  var normalizePathOrUrl = (path, workspace) => {
3794
- if ((0, import_core7.isString)(path) && !(0, import_core7.isUrl)(path)) {
3891
+ if ((0, import_core8.isString)(path) && !(0, import_core8.isUrl)(path)) {
3795
3892
  return normalizePath(path, workspace);
3796
3893
  }
3797
3894
  return path;
3798
3895
  };
3799
3896
  var normalizePath = (path, workspace) => {
3800
- if (!(0, import_core7.isString)(path)) {
3897
+ if (!(0, import_core8.isString)(path)) {
3801
3898
  return path;
3802
3899
  }
3803
- return import_core7.upath.resolve(workspace, path);
3900
+ return import_core8.upath.resolve(workspace, path);
3804
3901
  };
3805
3902
  var normalizeOperationsAndTags = (operationsOrTags, workspace, global) => {
3806
3903
  return Object.fromEntries(
@@ -3887,11 +3984,9 @@ var normalizeOperationsAndTags = (operationsOrTags, workspace, global) => {
3887
3984
  } : {},
3888
3985
  ...transformer ? { transformer: normalizePath(transformer, workspace) } : {},
3889
3986
  ...mutator ? { mutator: normalizeMutator(workspace, mutator) } : {},
3890
- ...formData ? {
3891
- formData: !(0, import_core7.isBoolean)(formData) ? normalizeMutator(workspace, formData) : formData
3892
- } : {},
3987
+ ...createFormData(workspace, formData),
3893
3988
  ...formUrlEncoded ? {
3894
- formUrlEncoded: !(0, import_core7.isBoolean)(formUrlEncoded) ? normalizeMutator(workspace, formUrlEncoded) : formUrlEncoded
3989
+ formUrlEncoded: !(0, import_core8.isBoolean)(formUrlEncoded) ? normalizeMutator(workspace, formUrlEncoded) : formUrlEncoded
3895
3990
  } : {},
3896
3991
  ...paramsSerializer ? {
3897
3992
  paramsSerializer: normalizeMutator(
@@ -3907,18 +4002,18 @@ var normalizeOperationsAndTags = (operationsOrTags, workspace, global) => {
3907
4002
  };
3908
4003
  var normalizeOutputMode = (mode) => {
3909
4004
  if (!mode) {
3910
- return import_core7.OutputMode.SINGLE;
4005
+ return import_core8.OutputMode.SINGLE;
3911
4006
  }
3912
- if (!Object.values(import_core7.OutputMode).includes(mode)) {
3913
- (0, import_core7.createLogger)().warn(import_chalk2.default.yellow(`Unknown the provided mode => ${mode}`));
3914
- return import_core7.OutputMode.SINGLE;
4007
+ if (!Object.values(import_core8.OutputMode).includes(mode)) {
4008
+ (0, import_core8.createLogger)().warn(import_chalk3.default.yellow(`Unknown the provided mode => ${mode}`));
4009
+ return import_core8.OutputMode.SINGLE;
3915
4010
  }
3916
4011
  return mode;
3917
4012
  };
3918
4013
  var normalizeHooks = (hooks) => {
3919
4014
  const keys = Object.keys(hooks);
3920
4015
  return keys.reduce((acc, key) => {
3921
- if ((0, import_core7.isString)(hooks[key])) {
4016
+ if ((0, import_core8.isString)(hooks[key])) {
3922
4017
  return {
3923
4018
  ...acc,
3924
4019
  [key]: [hooks[key]]
@@ -3928,12 +4023,12 @@ var normalizeHooks = (hooks) => {
3928
4023
  ...acc,
3929
4024
  [key]: hooks[key]
3930
4025
  };
3931
- } else if ((0, import_core7.isFunction)(hooks[key])) {
4026
+ } else if ((0, import_core8.isFunction)(hooks[key])) {
3932
4027
  return {
3933
4028
  ...acc,
3934
4029
  [key]: [hooks[key]]
3935
4030
  };
3936
- } else if ((0, import_core7.isObject)(hooks[key])) {
4031
+ } else if ((0, import_core8.isObject)(hooks[key])) {
3937
4032
  return {
3938
4033
  ...acc,
3939
4034
  [key]: [hooks[key]]
@@ -3945,10 +4040,15 @@ var normalizeHooks = (hooks) => {
3945
4040
  var normalizeHonoOptions = (hono2 = {}, workspace) => {
3946
4041
  var _a, _b;
3947
4042
  return {
3948
- ...hono2.handlers ? { handlers: import_core7.upath.resolve(workspace, hono2.handlers) } : {},
4043
+ ...hono2.handlers ? { handlers: import_core8.upath.resolve(workspace, hono2.handlers) } : {},
3949
4044
  compositeRoute: (_a = hono2.compositeRoute) != null ? _a : "",
3950
4045
  validator: (_b = hono2.validator) != null ? _b : true,
3951
- validatorOutputPath: hono2.validatorOutputPath ? import_core7.upath.resolve(workspace, hono2.validatorOutputPath) : ""
4046
+ validatorOutputPath: hono2.validatorOutputPath ? import_core8.upath.resolve(workspace, hono2.validatorOutputPath) : ""
4047
+ };
4048
+ };
4049
+ var normalizeJSDocOptions = (jsdoc = {}) => {
4050
+ return {
4051
+ ...jsdoc
3952
4052
  };
3953
4053
  };
3954
4054
  var normalizeQueryOptions = (queryOptions = {}, outputWorkspace, globalOptions = {}) => {
@@ -3958,12 +4058,12 @@ var normalizeQueryOptions = (queryOptions = {}, outputWorkspace, globalOptions =
3958
4058
  );
3959
4059
  }
3960
4060
  return {
3961
- ...!(0, import_core7.isUndefined)(queryOptions.usePrefetch) ? { usePrefetch: queryOptions.usePrefetch } : {},
3962
- ...!(0, import_core7.isUndefined)(queryOptions.useQuery) ? { useQuery: queryOptions.useQuery } : {},
3963
- ...!(0, import_core7.isUndefined)(queryOptions.useSuspenseQuery) ? { useSuspenseQuery: queryOptions.useSuspenseQuery } : {},
3964
- ...!(0, import_core7.isUndefined)(queryOptions.useMutation) ? { useMutation: queryOptions.useMutation } : {},
3965
- ...!(0, import_core7.isUndefined)(queryOptions.useInfinite) ? { useInfinite: queryOptions.useInfinite } : {},
3966
- ...!(0, import_core7.isUndefined)(queryOptions.useSuspenseInfiniteQuery) ? { useSuspenseInfiniteQuery: queryOptions.useSuspenseInfiniteQuery } : {},
4061
+ ...!(0, import_core8.isUndefined)(queryOptions.usePrefetch) ? { usePrefetch: queryOptions.usePrefetch } : {},
4062
+ ...!(0, import_core8.isUndefined)(queryOptions.useQuery) ? { useQuery: queryOptions.useQuery } : {},
4063
+ ...!(0, import_core8.isUndefined)(queryOptions.useSuspenseQuery) ? { useSuspenseQuery: queryOptions.useSuspenseQuery } : {},
4064
+ ...!(0, import_core8.isUndefined)(queryOptions.useMutation) ? { useMutation: queryOptions.useMutation } : {},
4065
+ ...!(0, import_core8.isUndefined)(queryOptions.useInfinite) ? { useInfinite: queryOptions.useInfinite } : {},
4066
+ ...!(0, import_core8.isUndefined)(queryOptions.useSuspenseInfiniteQuery) ? { useSuspenseInfiniteQuery: queryOptions.useSuspenseInfiniteQuery } : {},
3967
4067
  ...queryOptions.useInfiniteQueryParam ? { useInfiniteQueryParam: queryOptions.useInfiniteQueryParam } : {},
3968
4068
  ...queryOptions.options ? { options: queryOptions.options } : {},
3969
4069
  ...globalOptions.queryKey ? {
@@ -3990,30 +4090,30 @@ var normalizeQueryOptions = (queryOptions = {}, outputWorkspace, globalOptions =
3990
4090
  queryOptions == null ? void 0 : queryOptions.mutationOptions
3991
4091
  )
3992
4092
  } : {},
3993
- ...!(0, import_core7.isUndefined)(globalOptions.shouldExportQueryKey) ? {
4093
+ ...!(0, import_core8.isUndefined)(globalOptions.shouldExportQueryKey) ? {
3994
4094
  shouldExportQueryKey: globalOptions.shouldExportQueryKey
3995
4095
  } : {},
3996
- ...!(0, import_core7.isUndefined)(queryOptions.shouldExportQueryKey) ? { shouldExportQueryKey: queryOptions.shouldExportQueryKey } : {},
3997
- ...!(0, import_core7.isUndefined)(globalOptions.shouldExportHttpClient) ? {
4096
+ ...!(0, import_core8.isUndefined)(queryOptions.shouldExportQueryKey) ? { shouldExportQueryKey: queryOptions.shouldExportQueryKey } : {},
4097
+ ...!(0, import_core8.isUndefined)(globalOptions.shouldExportHttpClient) ? {
3998
4098
  shouldExportHttpClient: globalOptions.shouldExportHttpClient
3999
4099
  } : {},
4000
- ...!(0, import_core7.isUndefined)(queryOptions.shouldExportHttpClient) ? { shouldExportHttpClient: queryOptions.shouldExportHttpClient } : {},
4001
- ...!(0, import_core7.isUndefined)(globalOptions.shouldExportMutatorHooks) ? {
4100
+ ...!(0, import_core8.isUndefined)(queryOptions.shouldExportHttpClient) ? { shouldExportHttpClient: queryOptions.shouldExportHttpClient } : {},
4101
+ ...!(0, import_core8.isUndefined)(globalOptions.shouldExportMutatorHooks) ? {
4002
4102
  shouldExportMutatorHooks: globalOptions.shouldExportMutatorHooks
4003
4103
  } : {},
4004
- ...!(0, import_core7.isUndefined)(queryOptions.shouldExportMutatorHooks) ? { shouldExportMutatorHooks: queryOptions.shouldExportMutatorHooks } : {},
4005
- ...!(0, import_core7.isUndefined)(globalOptions.shouldSplitQueryKey) ? {
4104
+ ...!(0, import_core8.isUndefined)(queryOptions.shouldExportMutatorHooks) ? { shouldExportMutatorHooks: queryOptions.shouldExportMutatorHooks } : {},
4105
+ ...!(0, import_core8.isUndefined)(globalOptions.shouldSplitQueryKey) ? {
4006
4106
  shouldSplitQueryKey: globalOptions.shouldSplitQueryKey
4007
4107
  } : {},
4008
- ...!(0, import_core7.isUndefined)(queryOptions.shouldSplitQueryKey) ? { shouldSplitQueryKey: queryOptions.shouldSplitQueryKey } : {},
4009
- ...!(0, import_core7.isUndefined)(globalOptions.signal) ? {
4108
+ ...!(0, import_core8.isUndefined)(queryOptions.shouldSplitQueryKey) ? { shouldSplitQueryKey: queryOptions.shouldSplitQueryKey } : {},
4109
+ ...!(0, import_core8.isUndefined)(globalOptions.signal) ? {
4010
4110
  signal: globalOptions.signal
4011
4111
  } : {},
4012
- ...!(0, import_core7.isUndefined)(queryOptions.signal) ? { signal: queryOptions.signal } : {},
4013
- ...!(0, import_core7.isUndefined)(globalOptions.version) ? {
4112
+ ...!(0, import_core8.isUndefined)(queryOptions.signal) ? { signal: queryOptions.signal } : {},
4113
+ ...!(0, import_core8.isUndefined)(globalOptions.version) ? {
4014
4114
  version: globalOptions.version
4015
4115
  } : {},
4016
- ...!(0, import_core7.isUndefined)(queryOptions.version) ? { version: queryOptions.version } : {}
4116
+ ...!(0, import_core8.isUndefined)(queryOptions.version) ? { version: queryOptions.version } : {}
4017
4117
  };
4018
4118
  };
4019
4119
  var getDefaultFilesHeader = ({
@@ -4029,7 +4129,7 @@ var getDefaultFilesHeader = ({
4029
4129
  ];
4030
4130
 
4031
4131
  // src/utils/watcher.ts
4032
- var import_core8 = require("@orval/core");
4132
+ var import_core9 = require("@orval/core");
4033
4133
  var startWatcher = async (watchOptions, watchFn, defaultTarget = ".") => {
4034
4134
  if (!watchOptions) return;
4035
4135
  const { watch } = await Promise.resolve().then(() => __toESM(require("chokidar")));
@@ -4037,7 +4137,7 @@ var startWatcher = async (watchOptions, watchFn, defaultTarget = ".") => {
4037
4137
  const watchPaths = typeof watchOptions === "boolean" ? defaultTarget : Array.isArray(watchOptions) ? watchOptions.filter(
4038
4138
  (path) => typeof path === "string"
4039
4139
  ) : watchOptions;
4040
- (0, import_core8.log)(
4140
+ (0, import_core9.log)(
4041
4141
  `Watching for changes in ${Array.isArray(watchPaths) ? watchPaths.map((v) => '"' + v + '"').join(" | ") : '"' + watchPaths + '"'}`
4042
4142
  );
4043
4143
  const watcher = watch(watchPaths, {
@@ -4045,40 +4145,40 @@ var startWatcher = async (watchOptions, watchFn, defaultTarget = ".") => {
4045
4145
  ignored
4046
4146
  });
4047
4147
  watcher.on("all", async (type2, file) => {
4048
- (0, import_core8.log)(`Change detected: ${type2} ${file}`);
4148
+ (0, import_core9.log)(`Change detected: ${type2} ${file}`);
4049
4149
  try {
4050
4150
  await watchFn();
4051
4151
  } catch (e) {
4052
- (0, import_core8.logError)(e);
4152
+ (0, import_core9.logError)(e);
4053
4153
  }
4054
4154
  });
4055
4155
  };
4056
4156
 
4057
4157
  // src/write-specs.ts
4058
- var import_core10 = require("@orval/core");
4059
- var import_chalk4 = __toESM(require("chalk"));
4158
+ var import_core11 = require("@orval/core");
4159
+ var import_chalk5 = __toESM(require("chalk"));
4060
4160
  var import_execa2 = __toESM(require("execa"));
4061
4161
  var import_fs_extra5 = __toESM(require("fs-extra"));
4062
4162
  var import_lodash = __toESM(require("lodash.uniq"));
4063
4163
 
4064
4164
  // src/utils/executeHook.ts
4065
- var import_core9 = require("@orval/core");
4066
- var import_chalk3 = __toESM(require("chalk"));
4165
+ var import_core10 = require("@orval/core");
4166
+ var import_chalk4 = __toESM(require("chalk"));
4067
4167
  var import_execa = __toESM(require("execa"));
4068
4168
  var import_string_argv = require("string-argv");
4069
4169
  var executeHook = async (name, commands = [], args = []) => {
4070
- (0, import_core9.log)(import_chalk3.default.white(`Running ${name} hook...`));
4170
+ (0, import_core10.log)(import_chalk4.default.white(`Running ${name} hook...`));
4071
4171
  for (const command of commands) {
4072
4172
  try {
4073
- if ((0, import_core9.isString)(command)) {
4173
+ if ((0, import_core10.isString)(command)) {
4074
4174
  await executeCommand(command, args);
4075
- } else if ((0, import_core9.isFunction)(command)) {
4175
+ } else if ((0, import_core10.isFunction)(command)) {
4076
4176
  await command(args);
4077
- } else if ((0, import_core9.isObject)(command)) {
4177
+ } else if ((0, import_core10.isObject)(command)) {
4078
4178
  await executeObjectCommand(command, args);
4079
4179
  }
4080
4180
  } catch (e) {
4081
- (0, import_core9.logError)(e, `Failed to run ${name} hook`);
4181
+ (0, import_core10.logError)(e, `Failed to run ${name} hook`);
4082
4182
  }
4083
4183
  }
4084
4184
  };
@@ -4090,9 +4190,9 @@ async function executeObjectCommand(command, args) {
4090
4190
  if (command.injectGeneratedDirsAndFiles === false) {
4091
4191
  args = [];
4092
4192
  }
4093
- if ((0, import_core9.isString)(command.command)) {
4193
+ if ((0, import_core10.isString)(command.command)) {
4094
4194
  await executeCommand(command.command, args);
4095
- } else if ((0, import_core9.isFunction)(command.command)) {
4195
+ } else if ((0, import_core10.isFunction)(command.command)) {
4096
4196
  await command.command();
4097
4197
  }
4098
4198
  }
@@ -4103,7 +4203,7 @@ var getHeader = (option, info) => {
4103
4203
  return "";
4104
4204
  }
4105
4205
  const header = option(info);
4106
- return Array.isArray(header) ? (0, import_core10.jsDoc)({ description: header }) : header;
4206
+ return Array.isArray(header) ? (0, import_core11.jsDoc)({ description: header }) : header;
4107
4207
  };
4108
4208
  var writeSpecs = async (builder, workspace, options, projectName) => {
4109
4209
  var _a, _b;
@@ -4112,7 +4212,7 @@ var writeSpecs = async (builder, workspace, options, projectName) => {
4112
4212
  const projectTitle = projectName || info.title;
4113
4213
  const specsName = Object.keys(schemas).reduce(
4114
4214
  (acc, specKey) => {
4115
- const basePath = import_core10.upath.getSpecName(specKey, target);
4215
+ const basePath = import_core11.upath.getSpecName(specKey, target);
4116
4216
  const name = basePath.slice(1).split("/").join("-");
4117
4217
  acc[specKey] = name;
4118
4218
  return acc;
@@ -4125,8 +4225,8 @@ var writeSpecs = async (builder, workspace, options, projectName) => {
4125
4225
  const fileExtension = ["tags", "tags-split", "split"].includes(output.mode) ? ".ts" : (_a = output.fileExtension) != null ? _a : ".ts";
4126
4226
  await Promise.all(
4127
4227
  Object.entries(schemas).map(([specKey, schemas2]) => {
4128
- const schemaPath = !(0, import_core10.isRootKey)(specKey, target) ? import_core10.upath.join(rootSchemaPath, specsName[specKey]) : rootSchemaPath;
4129
- return (0, import_core10.writeSchemas)({
4228
+ const schemaPath = !(0, import_core11.isRootKey)(specKey, target) ? import_core11.upath.join(rootSchemaPath, specsName[specKey]) : rootSchemaPath;
4229
+ return (0, import_core11.writeSchemas)({
4130
4230
  schemaPath,
4131
4231
  schemas: schemas2,
4132
4232
  target,
@@ -4134,7 +4234,7 @@ var writeSpecs = async (builder, workspace, options, projectName) => {
4134
4234
  fileExtension,
4135
4235
  specsName,
4136
4236
  specKey,
4137
- isRootKey: (0, import_core10.isRootKey)(specKey, target),
4237
+ isRootKey: (0, import_core11.isRootKey)(specKey, target),
4138
4238
  header,
4139
4239
  indexFiles: output.indexFiles
4140
4240
  });
@@ -4156,20 +4256,20 @@ var writeSpecs = async (builder, workspace, options, projectName) => {
4156
4256
  if (output.workspace) {
4157
4257
  const workspacePath = output.workspace;
4158
4258
  const imports = implementationPaths.filter(
4159
- (path) => !output.mock || !path.endsWith(`.${(0, import_core10.getMockFileExtensionByTypeName)(output.mock)}.ts`)
4259
+ (path) => !output.mock || !path.endsWith(`.${(0, import_core11.getMockFileExtensionByTypeName)(output.mock)}.ts`)
4160
4260
  ).map(
4161
- (path) => import_core10.upath.relativeSafe(
4261
+ (path) => import_core11.upath.relativeSafe(
4162
4262
  workspacePath,
4163
- (0, import_core10.getFileInfo)(path).pathWithoutExtension
4263
+ (0, import_core11.getFileInfo)(path).pathWithoutExtension
4164
4264
  )
4165
4265
  );
4166
4266
  if (output.schemas) {
4167
4267
  imports.push(
4168
- import_core10.upath.relativeSafe(workspacePath, (0, import_core10.getFileInfo)(output.schemas).dirname)
4268
+ import_core11.upath.relativeSafe(workspacePath, (0, import_core11.getFileInfo)(output.schemas).dirname)
4169
4269
  );
4170
4270
  }
4171
4271
  if (output.indexFiles) {
4172
- const indexFile = import_core10.upath.join(workspacePath, "/index.ts");
4272
+ const indexFile = import_core11.upath.join(workspacePath, "/index.ts");
4173
4273
  if (await import_fs_extra5.default.pathExists(indexFile)) {
4174
4274
  const data = await import_fs_extra5.default.readFile(indexFile, "utf8");
4175
4275
  const importsNotDeclared = imports.filter((imp) => !data.includes(imp));
@@ -4199,7 +4299,7 @@ var writeSpecs = async (builder, workspace, options, projectName) => {
4199
4299
  ];
4200
4300
  }
4201
4301
  const paths = [
4202
- ...output.schemas ? [(0, import_core10.getFileInfo)(output.schemas).dirname] : [],
4302
+ ...output.schemas ? [(0, import_core11.getFileInfo)(output.schemas).dirname] : [],
4203
4303
  ...implementationPaths
4204
4304
  ];
4205
4305
  if (options.hooks.afterAllFilesWrite) {
@@ -4213,8 +4313,8 @@ var writeSpecs = async (builder, workspace, options, projectName) => {
4213
4313
  try {
4214
4314
  await (0, import_execa2.default)("prettier", ["--write", ...paths]);
4215
4315
  } catch {
4216
- (0, import_core10.log)(
4217
- import_chalk4.default.yellow(
4316
+ (0, import_core11.log)(
4317
+ import_chalk5.default.yellow(
4218
4318
  `\u26A0\uFE0F ${projectTitle ? `${projectTitle} - ` : ""}Prettier not found`
4219
4319
  )
4220
4320
  );
@@ -4225,7 +4325,7 @@ var writeSpecs = async (builder, workspace, options, projectName) => {
4225
4325
  await (0, import_execa2.default)("biome", ["check", "--write", ...paths]);
4226
4326
  } catch (e) {
4227
4327
  const message = e.exitCode === 1 ? e.stdout + e.stderr : `\u26A0\uFE0F ${projectTitle ? `${projectTitle} - ` : ""}biome not found`;
4228
- (0, import_core10.log)(import_chalk4.default.yellow(message));
4328
+ (0, import_core11.log)(import_chalk5.default.yellow(message));
4229
4329
  }
4230
4330
  }
4231
4331
  if (output.docs) {
@@ -4264,22 +4364,22 @@ var writeSpecs = async (builder, workspace, options, projectName) => {
4264
4364
  }
4265
4365
  } catch (e) {
4266
4366
  const message = e.exitCode === 1 ? e.stdout + e.stderr : `\u26A0\uFE0F ${projectTitle ? `${projectTitle} - ` : ""}Unable to generate docs`;
4267
- (0, import_core10.log)(import_chalk4.default.yellow(message));
4367
+ (0, import_core11.log)(import_chalk5.default.yellow(message));
4268
4368
  }
4269
4369
  }
4270
- (0, import_core10.createSuccessMessage)(projectTitle);
4370
+ (0, import_core11.createSuccessMessage)(projectTitle);
4271
4371
  };
4272
4372
  var getWriteMode = (mode) => {
4273
4373
  switch (mode) {
4274
- case import_core10.OutputMode.SPLIT:
4275
- return import_core10.writeSplitMode;
4276
- case import_core10.OutputMode.TAGS:
4277
- return import_core10.writeTagsMode;
4278
- case import_core10.OutputMode.TAGS_SPLIT:
4279
- return import_core10.writeSplitTagsMode;
4280
- case import_core10.OutputMode.SINGLE:
4374
+ case import_core11.OutputMode.SPLIT:
4375
+ return import_core11.writeSplitMode;
4376
+ case import_core11.OutputMode.TAGS:
4377
+ return import_core11.writeTagsMode;
4378
+ case import_core11.OutputMode.TAGS_SPLIT:
4379
+ return import_core11.writeSplitTagsMode;
4380
+ case import_core11.OutputMode.SINGLE:
4281
4381
  default:
4282
- return import_core10.writeSingleMode;
4382
+ return import_core11.writeSingleMode;
4283
4383
  }
4284
4384
  };
4285
4385
 
@@ -4288,18 +4388,18 @@ var generateSpec = async (workspace, options, projectName) => {
4288
4388
  if (options.output.clean) {
4289
4389
  const extraPatterns = Array.isArray(options.output.clean) ? options.output.clean : [];
4290
4390
  if (options.output.target) {
4291
- await (0, import_core11.removeFiles)(
4391
+ await (0, import_core12.removeFiles)(
4292
4392
  ["**/*", "!**/*.d.ts", ...extraPatterns],
4293
- (0, import_core11.getFileInfo)(options.output.target).dirname
4393
+ (0, import_core12.getFileInfo)(options.output.target).dirname
4294
4394
  );
4295
4395
  }
4296
4396
  if (options.output.schemas) {
4297
- await (0, import_core11.removeFiles)(
4397
+ await (0, import_core12.removeFiles)(
4298
4398
  ["**/*", "!**/*.d.ts", ...extraPatterns],
4299
- (0, import_core11.getFileInfo)(options.output.schemas).dirname
4399
+ (0, import_core12.getFileInfo)(options.output.schemas).dirname
4300
4400
  );
4301
4401
  }
4302
- (0, import_core11.log)(`${projectName ? `${projectName}: ` : ""}Cleaning output folder`);
4402
+ (0, import_core12.log)(`${projectName ? `${projectName}: ` : ""}Cleaning output folder`);
4303
4403
  }
4304
4404
  const writeSpecBuilder = await importSpecs(workspace, options);
4305
4405
  await writeSpecs(writeSpecBuilder, workspace, options, projectName);
@@ -4311,24 +4411,24 @@ var generateSpecs = async (config, workspace, projectName) => {
4311
4411
  try {
4312
4412
  await generateSpec(workspace, options, projectName);
4313
4413
  } catch (e) {
4314
- (0, import_core11.logError)(e, projectName);
4414
+ (0, import_core12.logError)(e, projectName);
4315
4415
  process.exit(1);
4316
4416
  }
4317
4417
  } else {
4318
- (0, import_core11.logError)("Project not found");
4418
+ (0, import_core12.logError)("Project not found");
4319
4419
  process.exit(1);
4320
4420
  }
4321
4421
  return;
4322
4422
  }
4323
4423
  let hasErrors;
4324
- const accumulate = await (0, import_core11.asyncReduce)(
4424
+ const accumulate = await (0, import_core12.asyncReduce)(
4325
4425
  Object.entries(config),
4326
4426
  async (acc, [projectName2, options]) => {
4327
4427
  try {
4328
4428
  acc.push(await generateSpec(workspace, options, projectName2));
4329
4429
  } catch (e) {
4330
4430
  hasErrors = true;
4331
- (0, import_core11.logError)(e, projectName2);
4431
+ (0, import_core12.logError)(e, projectName2);
4332
4432
  }
4333
4433
  return acc;
4334
4434
  },
@@ -4342,15 +4442,15 @@ var generateConfig = async (configFile, options) => {
4342
4442
  path,
4343
4443
  file: configExternal,
4344
4444
  error
4345
- } = await (0, import_core11.loadFile)(configFile, {
4445
+ } = await (0, import_core12.loadFile)(configFile, {
4346
4446
  defaultFileName: "orval.config"
4347
4447
  });
4348
4448
  if (!configExternal) {
4349
4449
  throw `failed to load from ${path} => ${error}`;
4350
4450
  }
4351
- const workspace = import_core11.upath.dirname(path);
4352
- const config = await ((0, import_core11.isFunction)(configExternal) ? configExternal() : configExternal);
4353
- const normalizedConfig = await (0, import_core11.asyncReduce)(
4451
+ const workspace = import_core12.upath.dirname(path);
4452
+ const config = await ((0, import_core12.isFunction)(configExternal) ? configExternal() : configExternal);
4453
+ const normalizedConfig = await (0, import_core12.asyncReduce)(
4354
4454
  Object.entries(config),
4355
4455
  async (acc, [key, value]) => {
4356
4456
  acc[key] = await normalizeOptions(value, workspace, options);
@@ -4360,7 +4460,7 @@ var generateConfig = async (configFile, options) => {
4360
4460
  );
4361
4461
  const fileToWatch = Object.entries(normalizedConfig).filter(
4362
4462
  ([project]) => (options == null ? void 0 : options.projectName) === void 0 || project === (options == null ? void 0 : options.projectName)
4363
- ).map(([, { input }]) => input.target).filter((target) => (0, import_core11.isString)(target));
4463
+ ).map(([, { input }]) => input.target).filter((target) => (0, import_core12.isString)(target));
4364
4464
  if ((options == null ? void 0 : options.watch) && fileToWatch.length) {
4365
4465
  startWatcher(
4366
4466
  options == null ? void 0 : options.watch,
@@ -4374,7 +4474,7 @@ var generateConfig = async (configFile, options) => {
4374
4474
 
4375
4475
  // src/bin/orval.ts
4376
4476
  var cli = (0, import_cac.cac)("orval");
4377
- (0, import_core12.startMessage)({
4477
+ (0, import_core13.startMessage)({
4378
4478
  name: package_default.name,
4379
4479
  version: package_default.version,
4380
4480
  description: package_default.description
@@ -4390,7 +4490,7 @@ cli.command(
4390
4490
  "-w, --watch [path]",
4391
4491
  "Watch mode, if path is not specified, it watches the input target"
4392
4492
  ).option("--clean [path]", "Clean output directory").option("--prettier [path]", "Prettier generated files").option("--tslint [path]", "tslint generated files").option("--biome [path]", "biome generated files").option("--tsconfig [path]", "path to your tsconfig file").action(async (paths, cmd) => {
4393
- if (!cmd.config && (0, import_core12.isString)(cmd.input) && (0, import_core12.isString)(cmd.output)) {
4493
+ if (!cmd.config && (0, import_core13.isString)(cmd.input) && (0, import_core13.isString)(cmd.output)) {
4394
4494
  const normalizedOptions = await normalizeOptions({
4395
4495
  input: cmd.input,
4396
4496
  output: {
@@ -4412,7 +4512,7 @@ cli.command(
4412
4512
  try {
4413
4513
  await generateSpec(process.cwd(), normalizedOptions);
4414
4514
  } catch (e) {
4415
- (0, import_core12.logError)(e);
4515
+ (0, import_core13.logError)(e);
4416
4516
  }
4417
4517
  },
4418
4518
  normalizedOptions.input.target
@@ -4421,7 +4521,7 @@ cli.command(
4421
4521
  try {
4422
4522
  await generateSpec(process.cwd(), normalizedOptions);
4423
4523
  } catch (e) {
4424
- (0, import_core12.logError)(e);
4524
+ (0, import_core13.logError)(e);
4425
4525
  }
4426
4526
  }
4427
4527
  } else {