@kubb/core 2.5.3 → 2.6.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.
Files changed (66) hide show
  1. package/dist/{chunk-3TKNCRJ4.js → chunk-42FTVCX7.js} +2 -2
  2. package/dist/chunk-4YVJ5P2R.cjs +15 -0
  3. package/dist/{chunk-FTZMI4WB.js → chunk-5X45CG5S.js} +3 -3
  4. package/dist/{chunk-FTZMI4WB.js.map → chunk-5X45CG5S.js.map} +1 -1
  5. package/dist/{chunk-77RJ5DJW.cjs → chunk-7XH3IIIO.cjs} +3 -3
  6. package/dist/{chunk-6WTZL3YP.js → chunk-F6NVPUP6.js} +2 -2
  7. package/dist/{chunk-G6LB76OA.cjs → chunk-IQLE5TWS.cjs} +6 -6
  8. package/dist/{chunk-SZ54MX56.cjs → chunk-J5QWFPI4.cjs} +3 -3
  9. package/dist/{chunk-SZ54MX56.cjs.map → chunk-J5QWFPI4.cjs.map} +1 -1
  10. package/dist/{chunk-UKW32O5T.js → chunk-JSSTXTHS.js} +2 -2
  11. package/dist/{chunk-UTRM3BSJ.cjs → chunk-JVC5YZVA.cjs} +14 -14
  12. package/dist/{chunk-4HMCTZVL.cjs → chunk-JVCA27M5.cjs} +214 -214
  13. package/dist/{chunk-HM4ZU273.cjs → chunk-KQZNQA3D.cjs} +90 -90
  14. package/dist/{chunk-65KNHWCO.js → chunk-MAQLBPOG.js} +3 -3
  15. package/dist/{chunk-2QWFVPYY.cjs → chunk-MSMNDHDO.cjs} +5 -5
  16. package/dist/{chunk-CIHAHMSS.js → chunk-MSOTSQG5.js} +7 -7
  17. package/dist/{chunk-SC6FZSNN.js → chunk-R4FBPLRJ.js} +2 -2
  18. package/dist/{chunk-SUPR72XS.js → chunk-RC2A4MWB.js} +2 -2
  19. package/dist/{chunk-UQCQ5BUS.cjs → chunk-UCW7372N.cjs} +5 -5
  20. package/dist/{chunk-UQCQ5BUS.cjs.map → chunk-UCW7372N.cjs.map} +1 -1
  21. package/dist/{chunk-XR7R5ICB.js → chunk-VM6OSFNQ.js} +2 -2
  22. package/dist/{chunk-HL4EB6OW.cjs → chunk-Z2DIGHSC.cjs} +5 -5
  23. package/dist/{chunk-R2IZ7YIQ.js → chunk-ZFWX24A2.js} +3 -3
  24. package/dist/fs.cjs +10 -10
  25. package/dist/fs.d.cts +1 -1
  26. package/dist/fs.d.ts +1 -1
  27. package/dist/fs.js +4 -4
  28. package/dist/index.cjs +103 -103
  29. package/dist/index.d.cts +2 -2
  30. package/dist/index.d.ts +2 -2
  31. package/dist/index.js +11 -11
  32. package/dist/logger.cjs +7 -7
  33. package/dist/logger.d.cts +1 -1
  34. package/dist/logger.d.ts +1 -1
  35. package/dist/logger.js +3 -3
  36. package/dist/mocks.cjs +10 -10
  37. package/dist/mocks.d.cts +2 -2
  38. package/dist/mocks.d.ts +2 -2
  39. package/dist/mocks.js +8 -8
  40. package/dist/transformers.cjs +23 -23
  41. package/dist/transformers.js +5 -5
  42. package/dist/utils.cjs +13 -13
  43. package/dist/utils.js +4 -4
  44. package/package.json +8 -8
  45. package/dist/chunk-UTVI3BZ7.cjs +0 -15
  46. /package/dist/{chunk-3TKNCRJ4.js.map → chunk-42FTVCX7.js.map} +0 -0
  47. /package/dist/{chunk-UTVI3BZ7.cjs.map → chunk-4YVJ5P2R.cjs.map} +0 -0
  48. /package/dist/{chunk-6WTZL3YP.js.map → chunk-7XH3IIIO.cjs.map} +0 -0
  49. /package/dist/{chunk-77RJ5DJW.cjs.map → chunk-F6NVPUP6.js.map} +0 -0
  50. /package/dist/{chunk-G6LB76OA.cjs.map → chunk-IQLE5TWS.cjs.map} +0 -0
  51. /package/dist/{chunk-UKW32O5T.js.map → chunk-JSSTXTHS.js.map} +0 -0
  52. /package/dist/{chunk-65KNHWCO.js.map → chunk-JVC5YZVA.cjs.map} +0 -0
  53. /package/dist/{chunk-4HMCTZVL.cjs.map → chunk-JVCA27M5.cjs.map} +0 -0
  54. /package/dist/{chunk-HM4ZU273.cjs.map → chunk-KQZNQA3D.cjs.map} +0 -0
  55. /package/dist/{chunk-UTRM3BSJ.cjs.map → chunk-MAQLBPOG.js.map} +0 -0
  56. /package/dist/{chunk-2QWFVPYY.cjs.map → chunk-MSMNDHDO.cjs.map} +0 -0
  57. /package/dist/{chunk-CIHAHMSS.js.map → chunk-MSOTSQG5.js.map} +0 -0
  58. /package/dist/{chunk-SC6FZSNN.js.map → chunk-R4FBPLRJ.js.map} +0 -0
  59. /package/dist/{chunk-HL4EB6OW.cjs.map → chunk-RC2A4MWB.js.map} +0 -0
  60. /package/dist/{chunk-XR7R5ICB.js.map → chunk-VM6OSFNQ.js.map} +0 -0
  61. /package/dist/{chunk-SUPR72XS.js.map → chunk-Z2DIGHSC.cjs.map} +0 -0
  62. /package/dist/{chunk-R2IZ7YIQ.js.map → chunk-ZFWX24A2.js.map} +0 -0
  63. /package/dist/{logger-wryz32Ex.d.cts → logger-DjcF5DGc.d.cts} +0 -0
  64. /package/dist/{logger-wryz32Ex.d.ts → logger-DjcF5DGc.d.ts} +0 -0
  65. /package/dist/{write-A6VgHkYA.d.cts → write-CN8f7bYv.d.cts} +0 -0
  66. /package/dist/{write-A6VgHkYA.d.ts → write-CN8f7bYv.d.ts} +0 -0
package/dist/index.cjs CHANGED
@@ -2,16 +2,16 @@
2
2
 
3
3
  Object.defineProperty(exports, '__esModule', { value: true });
4
4
 
5
- var chunkG6LB76OA_cjs = require('./chunk-G6LB76OA.cjs');
6
- var chunkUTVI3BZ7_cjs = require('./chunk-UTVI3BZ7.cjs');
7
- var chunk4HMCTZVL_cjs = require('./chunk-4HMCTZVL.cjs');
8
- require('./chunk-HL4EB6OW.cjs');
9
- require('./chunk-77RJ5DJW.cjs');
10
- require('./chunk-UQCQ5BUS.cjs');
11
- var chunkUTRM3BSJ_cjs = require('./chunk-UTRM3BSJ.cjs');
12
- var chunk2QWFVPYY_cjs = require('./chunk-2QWFVPYY.cjs');
13
- require('./chunk-HM4ZU273.cjs');
14
- var chunkSZ54MX56_cjs = require('./chunk-SZ54MX56.cjs');
5
+ var chunkIQLE5TWS_cjs = require('./chunk-IQLE5TWS.cjs');
6
+ var chunk4YVJ5P2R_cjs = require('./chunk-4YVJ5P2R.cjs');
7
+ var chunkJVCA27M5_cjs = require('./chunk-JVCA27M5.cjs');
8
+ require('./chunk-Z2DIGHSC.cjs');
9
+ require('./chunk-7XH3IIIO.cjs');
10
+ require('./chunk-UCW7372N.cjs');
11
+ var chunkJVC5YZVA_cjs = require('./chunk-JVC5YZVA.cjs');
12
+ var chunkMSMNDHDO_cjs = require('./chunk-MSMNDHDO.cjs');
13
+ require('./chunk-KQZNQA3D.cjs');
14
+ var chunkJ5QWFPI4_cjs = require('./chunk-J5QWFPI4.cjs');
15
15
  var mod = require('module');
16
16
  var os = require('os');
17
17
  var url = require('url');
@@ -29,13 +29,13 @@ var process__default = /*#__PURE__*/_interopDefault(process);
29
29
  var fs__default = /*#__PURE__*/_interopDefault(fs);
30
30
 
31
31
  // src/index.ts
32
- chunkSZ54MX56_cjs.init_cjs_shims();
32
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
33
33
 
34
34
  // src/build.ts
35
- chunkSZ54MX56_cjs.init_cjs_shims();
35
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
36
36
 
37
37
  // src/config.ts
38
- chunkSZ54MX56_cjs.init_cjs_shims();
38
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
39
39
  function defineConfig(options) {
40
40
  return options;
41
41
  }
@@ -48,16 +48,16 @@ async function transformReducer(_previousCode, result, _plugin) {
48
48
  return result;
49
49
  }
50
50
  async function setup(options) {
51
- const { config, logger = chunkUTRM3BSJ_cjs.createLogger({ logLevel: chunkUTRM3BSJ_cjs.LogLevel.silent }) } = options;
51
+ const { config, logger = chunkJVC5YZVA_cjs.createLogger({ logLevel: chunkJVC5YZVA_cjs.LogLevel.silent }) } = options;
52
52
  let count = 0;
53
53
  try {
54
- if (isInputPath(config) && !new chunkG6LB76OA_cjs.URLPath(config.input.path).isURL) {
55
- await chunk2QWFVPYY_cjs.read(config.input.path);
54
+ if (isInputPath(config) && !new chunkIQLE5TWS_cjs.URLPath(config.input.path).isURL) {
55
+ await chunkMSMNDHDO_cjs.read(config.input.path);
56
56
  }
57
57
  } catch (e) {
58
58
  if (isInputPath(config)) {
59
59
  throw new Error(
60
- "Cannot read file/URL defined in `input.path` or set with `kubb generate PATH` in the CLI of your Kubb config " + chunkUTRM3BSJ_cjs.p.dim(config.input.path),
60
+ "Cannot read file/URL defined in `input.path` or set with `kubb generate PATH` in the CLI of your Kubb config " + chunkJVC5YZVA_cjs.p.dim(config.input.path),
61
61
  {
62
62
  cause: e
63
63
  }
@@ -65,19 +65,19 @@ async function setup(options) {
65
65
  }
66
66
  }
67
67
  if (config.output.clean) {
68
- await chunkUTVI3BZ7_cjs.clean(config.output.path);
68
+ await chunk4YVJ5P2R_cjs.clean(config.output.path);
69
69
  }
70
70
  const task = async (file) => {
71
71
  const { path: path3 } = file;
72
- let source = chunk4HMCTZVL_cjs.FileManager.getSource(file);
72
+ let source = chunkJVCA27M5_cjs.FileManager.getSource(file);
73
73
  const { result: loadedResult } = await pluginManager.hookFirst({
74
74
  hookName: "load",
75
75
  parameters: [path3]
76
76
  });
77
- if (loadedResult && chunk4HMCTZVL_cjs.isPromise(loadedResult)) {
77
+ if (loadedResult && chunkJVCA27M5_cjs.isPromise(loadedResult)) {
78
78
  source = await loadedResult;
79
79
  }
80
- if (loadedResult && !chunk4HMCTZVL_cjs.isPromise(loadedResult)) {
80
+ if (loadedResult && !chunkJVCA27M5_cjs.isPromise(loadedResult)) {
81
81
  source = loadedResult;
82
82
  }
83
83
  if (source) {
@@ -105,13 +105,13 @@ async function setup(options) {
105
105
  source: source || ""
106
106
  };
107
107
  };
108
- const pluginManager = new chunk4HMCTZVL_cjs.PluginManager(config, { logger, task });
108
+ const pluginManager = new chunkJVCA27M5_cjs.PluginManager(config, { logger, task });
109
109
  pluginManager.on("execute", (executer) => {
110
110
  const { hookName, parameters, plugin } = executer;
111
111
  if (hookName === "writeFile") {
112
112
  const [code] = parameters;
113
- if (logger.logLevel === chunkUTRM3BSJ_cjs.LogLevel.debug) {
114
- logger.emit("debug", [`PluginKey ${chunkUTRM3BSJ_cjs.p.dim(JSON.stringify(plugin.key))}
113
+ if (logger.logLevel === chunkJVC5YZVA_cjs.LogLevel.debug) {
114
+ logger.emit("debug", [`PluginKey ${chunkJVC5YZVA_cjs.p.dim(JSON.stringify(plugin.key))}
115
115
  with source
116
116
 
117
117
  ${code}`]);
@@ -119,7 +119,7 @@ ${code}`]);
119
119
  }
120
120
  });
121
121
  pluginManager.queue.on("add", () => {
122
- if (logger.logLevel !== chunkUTRM3BSJ_cjs.LogLevel.info) {
122
+ if (logger.logLevel !== chunkJVC5YZVA_cjs.LogLevel.info) {
123
123
  return;
124
124
  }
125
125
  if (count === 0) {
@@ -127,32 +127,32 @@ ${code}`]);
127
127
  }
128
128
  });
129
129
  pluginManager.queue.on("active", () => {
130
- if (logger.logLevel !== chunkUTRM3BSJ_cjs.LogLevel.info) {
130
+ if (logger.logLevel !== chunkJVC5YZVA_cjs.LogLevel.info) {
131
131
  return;
132
132
  }
133
133
  if (logger.spinner && pluginManager.queue.size > 0) {
134
134
  const text = `Item: ${count} Size: ${pluginManager.queue.size} Pending: ${pluginManager.queue.pending}`;
135
- logger.spinner.suffixText = chunkUTRM3BSJ_cjs.p.dim(text);
135
+ logger.spinner.suffixText = chunkJVC5YZVA_cjs.p.dim(text);
136
136
  }
137
137
  ++count;
138
138
  });
139
139
  pluginManager.queue.on("completed", () => {
140
- if (logger.logLevel !== chunkUTRM3BSJ_cjs.LogLevel.info) {
140
+ if (logger.logLevel !== chunkJVC5YZVA_cjs.LogLevel.info) {
141
141
  return;
142
142
  }
143
143
  if (logger.spinner) {
144
144
  const text = `Item: ${count} Size: ${pluginManager.queue.size} Pending: ${pluginManager.queue.pending}`;
145
- logger.spinner.suffixText = chunkUTRM3BSJ_cjs.p.dim(text);
145
+ logger.spinner.suffixText = chunkJVC5YZVA_cjs.p.dim(text);
146
146
  }
147
147
  });
148
148
  pluginManager.on("executed", (executer) => {
149
149
  const { hookName, plugin, output, parameters } = executer;
150
- if (logger.logLevel === chunkUTRM3BSJ_cjs.LogLevel.debug) {
150
+ if (logger.logLevel === chunkJVC5YZVA_cjs.LogLevel.debug) {
151
151
  const logs = [
152
- `${chunkUTRM3BSJ_cjs.randomCliColour(plugin.name)} Executing ${hookName}`,
153
- parameters && `${chunkUTRM3BSJ_cjs.p.bgWhite(`Parameters`)} ${chunkUTRM3BSJ_cjs.randomCliColour(plugin.name)} ${hookName}`,
152
+ `${chunkJVC5YZVA_cjs.randomCliColour(plugin.name)} Executing ${hookName}`,
153
+ parameters && `${chunkJVC5YZVA_cjs.p.bgWhite(`Parameters`)} ${chunkJVC5YZVA_cjs.randomCliColour(plugin.name)} ${hookName}`,
154
154
  JSON.stringify(parameters, void 0, 2),
155
- output && `${chunkUTRM3BSJ_cjs.p.bgWhite("Output")} ${chunkUTRM3BSJ_cjs.randomCliColour(plugin.name)} ${hookName}`,
155
+ output && `${chunkJVC5YZVA_cjs.p.bgWhite("Output")} ${chunkJVC5YZVA_cjs.randomCliColour(plugin.name)} ${hookName}`,
156
156
  output
157
157
  ].filter(Boolean);
158
158
  logger.emit("debug", logs);
@@ -168,10 +168,10 @@ async function build(options) {
168
168
  parameters: [options.config]
169
169
  });
170
170
  await pluginManager.hookParallel({ hookName: "buildEnd" });
171
- if (logger.logLevel === chunkUTRM3BSJ_cjs.LogLevel.info) {
171
+ if (logger.logLevel === chunkJVC5YZVA_cjs.LogLevel.info) {
172
172
  logger.emit("end", `\u{1F4BE} Writing completed`);
173
173
  }
174
- return { files: fileManager.files.map((file) => ({ ...file, source: chunk4HMCTZVL_cjs.FileManager.getSource(file) })), pluginManager };
174
+ return { files: fileManager.files.map((file) => ({ ...file, source: chunkJVCA27M5_cjs.FileManager.getSource(file) })), pluginManager };
175
175
  }
176
176
  async function safeBuild(options) {
177
177
  const pluginManager = await setup(options);
@@ -182,105 +182,105 @@ async function safeBuild(options) {
182
182
  parameters: [options.config]
183
183
  });
184
184
  await pluginManager.hookParallel({ hookName: "buildEnd" });
185
- if (logger.logLevel === chunkUTRM3BSJ_cjs.LogLevel.info) {
185
+ if (logger.logLevel === chunkJVC5YZVA_cjs.LogLevel.info) {
186
186
  logger.emit("end", `\u{1F4BE} Writing completed`);
187
187
  }
188
188
  } catch (e) {
189
- return { files: fileManager.files.map((file) => ({ ...file, source: chunk4HMCTZVL_cjs.FileManager.getSource(file) })), pluginManager, error: e };
189
+ return { files: fileManager.files.map((file) => ({ ...file, source: chunkJVCA27M5_cjs.FileManager.getSource(file) })), pluginManager, error: e };
190
190
  }
191
- return { files: fileManager.files.map((file) => ({ ...file, source: chunk4HMCTZVL_cjs.FileManager.getSource(file) })), pluginManager };
191
+ return { files: fileManager.files.map((file) => ({ ...file, source: chunkJVCA27M5_cjs.FileManager.getSource(file) })), pluginManager };
192
192
  }
193
193
 
194
194
  // src/Generator.ts
195
- chunkSZ54MX56_cjs.init_cjs_shims();
195
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
196
196
  var _options, _context;
197
197
  var Generator = class {
198
198
  constructor(options, context) {
199
- chunkSZ54MX56_cjs.__privateAdd(this, _options, {});
200
- chunkSZ54MX56_cjs.__privateAdd(this, _context, {});
199
+ chunkJ5QWFPI4_cjs.__privateAdd(this, _options, {});
200
+ chunkJ5QWFPI4_cjs.__privateAdd(this, _context, {});
201
201
  if (context) {
202
- chunkSZ54MX56_cjs.__privateSet(this, _context, context);
202
+ chunkJ5QWFPI4_cjs.__privateSet(this, _context, context);
203
203
  }
204
204
  if (options) {
205
- chunkSZ54MX56_cjs.__privateSet(this, _options, options);
205
+ chunkJ5QWFPI4_cjs.__privateSet(this, _options, options);
206
206
  }
207
207
  return this;
208
208
  }
209
209
  get options() {
210
- return chunkSZ54MX56_cjs.__privateGet(this, _options);
210
+ return chunkJ5QWFPI4_cjs.__privateGet(this, _options);
211
211
  }
212
212
  get context() {
213
- return chunkSZ54MX56_cjs.__privateGet(this, _context);
213
+ return chunkJ5QWFPI4_cjs.__privateGet(this, _context);
214
214
  }
215
215
  set options(options) {
216
- chunkSZ54MX56_cjs.__privateSet(this, _options, { ...chunkSZ54MX56_cjs.__privateGet(this, _options), ...options });
216
+ chunkJ5QWFPI4_cjs.__privateSet(this, _options, { ...chunkJ5QWFPI4_cjs.__privateGet(this, _options), ...options });
217
217
  }
218
218
  };
219
219
  _options = new WeakMap();
220
220
  _context = new WeakMap();
221
221
 
222
222
  // src/PackageManager.ts
223
- chunkSZ54MX56_cjs.init_cjs_shims();
223
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
224
224
 
225
225
  // ../../node_modules/.pnpm/find-up@7.0.0/node_modules/find-up/index.js
226
- chunkSZ54MX56_cjs.init_cjs_shims();
226
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
227
227
 
228
228
  // ../../node_modules/.pnpm/locate-path@7.2.0/node_modules/locate-path/index.js
229
- chunkSZ54MX56_cjs.init_cjs_shims();
229
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
230
230
 
231
231
  // ../../node_modules/.pnpm/p-locate@6.0.0/node_modules/p-locate/index.js
232
- chunkSZ54MX56_cjs.init_cjs_shims();
232
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
233
233
 
234
234
  // ../../node_modules/.pnpm/p-limit@4.0.0/node_modules/p-limit/index.js
235
- chunkSZ54MX56_cjs.init_cjs_shims();
235
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
236
236
 
237
237
  // ../../node_modules/.pnpm/yocto-queue@1.0.0/node_modules/yocto-queue/index.js
238
- chunkSZ54MX56_cjs.init_cjs_shims();
238
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
239
239
  var Node = class {
240
240
  constructor(value) {
241
- chunkSZ54MX56_cjs.__publicField(this, "value");
242
- chunkSZ54MX56_cjs.__publicField(this, "next");
241
+ chunkJ5QWFPI4_cjs.__publicField(this, "value");
242
+ chunkJ5QWFPI4_cjs.__publicField(this, "next");
243
243
  this.value = value;
244
244
  }
245
245
  };
246
246
  var _head, _tail, _size;
247
247
  var Queue = class {
248
248
  constructor() {
249
- chunkSZ54MX56_cjs.__privateAdd(this, _head, void 0);
250
- chunkSZ54MX56_cjs.__privateAdd(this, _tail, void 0);
251
- chunkSZ54MX56_cjs.__privateAdd(this, _size, void 0);
249
+ chunkJ5QWFPI4_cjs.__privateAdd(this, _head, void 0);
250
+ chunkJ5QWFPI4_cjs.__privateAdd(this, _tail, void 0);
251
+ chunkJ5QWFPI4_cjs.__privateAdd(this, _size, void 0);
252
252
  this.clear();
253
253
  }
254
254
  enqueue(value) {
255
255
  const node = new Node(value);
256
- if (chunkSZ54MX56_cjs.__privateGet(this, _head)) {
257
- chunkSZ54MX56_cjs.__privateGet(this, _tail).next = node;
258
- chunkSZ54MX56_cjs.__privateSet(this, _tail, node);
256
+ if (chunkJ5QWFPI4_cjs.__privateGet(this, _head)) {
257
+ chunkJ5QWFPI4_cjs.__privateGet(this, _tail).next = node;
258
+ chunkJ5QWFPI4_cjs.__privateSet(this, _tail, node);
259
259
  } else {
260
- chunkSZ54MX56_cjs.__privateSet(this, _head, node);
261
- chunkSZ54MX56_cjs.__privateSet(this, _tail, node);
260
+ chunkJ5QWFPI4_cjs.__privateSet(this, _head, node);
261
+ chunkJ5QWFPI4_cjs.__privateSet(this, _tail, node);
262
262
  }
263
- chunkSZ54MX56_cjs.__privateWrapper(this, _size)._++;
263
+ chunkJ5QWFPI4_cjs.__privateWrapper(this, _size)._++;
264
264
  }
265
265
  dequeue() {
266
- const current = chunkSZ54MX56_cjs.__privateGet(this, _head);
266
+ const current = chunkJ5QWFPI4_cjs.__privateGet(this, _head);
267
267
  if (!current) {
268
268
  return;
269
269
  }
270
- chunkSZ54MX56_cjs.__privateSet(this, _head, chunkSZ54MX56_cjs.__privateGet(this, _head).next);
271
- chunkSZ54MX56_cjs.__privateWrapper(this, _size)._--;
270
+ chunkJ5QWFPI4_cjs.__privateSet(this, _head, chunkJ5QWFPI4_cjs.__privateGet(this, _head).next);
271
+ chunkJ5QWFPI4_cjs.__privateWrapper(this, _size)._--;
272
272
  return current.value;
273
273
  }
274
274
  clear() {
275
- chunkSZ54MX56_cjs.__privateSet(this, _head, void 0);
276
- chunkSZ54MX56_cjs.__privateSet(this, _tail, void 0);
277
- chunkSZ54MX56_cjs.__privateSet(this, _size, 0);
275
+ chunkJ5QWFPI4_cjs.__privateSet(this, _head, void 0);
276
+ chunkJ5QWFPI4_cjs.__privateSet(this, _tail, void 0);
277
+ chunkJ5QWFPI4_cjs.__privateSet(this, _size, 0);
278
278
  }
279
279
  get size() {
280
- return chunkSZ54MX56_cjs.__privateGet(this, _size);
280
+ return chunkJ5QWFPI4_cjs.__privateGet(this, _size);
281
281
  }
282
282
  *[Symbol.iterator]() {
283
- let current = chunkSZ54MX56_cjs.__privateGet(this, _head);
283
+ let current = chunkJ5QWFPI4_cjs.__privateGet(this, _head);
284
284
  while (current) {
285
285
  yield current.value;
286
286
  current = current.next;
@@ -431,13 +431,13 @@ function locatePathSync(paths, {
431
431
  }
432
432
 
433
433
  // ../../node_modules/.pnpm/unicorn-magic@0.1.0/node_modules/unicorn-magic/node.js
434
- chunkSZ54MX56_cjs.init_cjs_shims();
434
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
435
435
  function toPath2(urlOrPath) {
436
436
  return urlOrPath instanceof URL ? url.fileURLToPath(urlOrPath) : urlOrPath;
437
437
  }
438
438
 
439
439
  // ../../node_modules/.pnpm/path-exists@5.0.0/node_modules/path-exists/index.js
440
- chunkSZ54MX56_cjs.init_cjs_shims();
440
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
441
441
 
442
442
  // ../../node_modules/.pnpm/find-up@7.0.0/node_modules/find-up/index.js
443
443
  var findUpStop = Symbol("findUpStop");
@@ -516,30 +516,30 @@ function findUpSync(name, options = {}) {
516
516
  var _cache, _cwd, _SLASHES, _match, match_fn;
517
517
  var _PackageManager = class _PackageManager {
518
518
  constructor(workspace) {
519
- chunkSZ54MX56_cjs.__privateAdd(this, _match);
520
- chunkSZ54MX56_cjs.__privateAdd(this, _cwd, void 0);
521
- chunkSZ54MX56_cjs.__privateAdd(this, _SLASHES, /* @__PURE__ */ new Set(["/", "\\"]));
519
+ chunkJ5QWFPI4_cjs.__privateAdd(this, _match);
520
+ chunkJ5QWFPI4_cjs.__privateAdd(this, _cwd, void 0);
521
+ chunkJ5QWFPI4_cjs.__privateAdd(this, _SLASHES, /* @__PURE__ */ new Set(["/", "\\"]));
522
522
  if (workspace) {
523
- chunkSZ54MX56_cjs.__privateSet(this, _cwd, workspace);
523
+ chunkJ5QWFPI4_cjs.__privateSet(this, _cwd, workspace);
524
524
  }
525
525
  return this;
526
526
  }
527
527
  set workspace(workspace) {
528
- chunkSZ54MX56_cjs.__privateSet(this, _cwd, workspace);
528
+ chunkJ5QWFPI4_cjs.__privateSet(this, _cwd, workspace);
529
529
  }
530
530
  get workspace() {
531
- return chunkSZ54MX56_cjs.__privateGet(this, _cwd);
531
+ return chunkJ5QWFPI4_cjs.__privateGet(this, _cwd);
532
532
  }
533
533
  normalizeDirectory(directory) {
534
- if (!chunkSZ54MX56_cjs.__privateGet(this, _SLASHES).has(directory[directory.length - 1])) {
534
+ if (!chunkJ5QWFPI4_cjs.__privateGet(this, _SLASHES).has(directory[directory.length - 1])) {
535
535
  return `${directory}/`;
536
536
  }
537
537
  return directory;
538
538
  }
539
539
  getLocation(path3) {
540
540
  let location = path3;
541
- if (chunkSZ54MX56_cjs.__privateGet(this, _cwd)) {
542
- const require2 = mod__default.default.createRequire(this.normalizeDirectory(chunkSZ54MX56_cjs.__privateGet(this, _cwd)));
541
+ if (chunkJ5QWFPI4_cjs.__privateGet(this, _cwd)) {
542
+ const require2 = mod__default.default.createRequire(this.normalizeDirectory(chunkJ5QWFPI4_cjs.__privateGet(this, _cwd)));
543
543
  location = require2.resolve(path3);
544
544
  }
545
545
  return location;
@@ -559,46 +559,46 @@ var _PackageManager = class _PackageManager {
559
559
  }
560
560
  async getPackageJSON() {
561
561
  const pkgPath = await findUp(["package.json"], {
562
- cwd: chunkSZ54MX56_cjs.__privateGet(this, _cwd)
562
+ cwd: chunkJ5QWFPI4_cjs.__privateGet(this, _cwd)
563
563
  });
564
564
  if (!pkgPath) {
565
565
  return void 0;
566
566
  }
567
- const json = await chunk2QWFVPYY_cjs.read(pkgPath);
567
+ const json = await chunkMSMNDHDO_cjs.read(pkgPath);
568
568
  return JSON.parse(json);
569
569
  }
570
570
  getPackageJSONSync() {
571
571
  const pkgPath = findUpSync(["package.json"], {
572
- cwd: chunkSZ54MX56_cjs.__privateGet(this, _cwd)
572
+ cwd: chunkJ5QWFPI4_cjs.__privateGet(this, _cwd)
573
573
  });
574
574
  if (!pkgPath) {
575
575
  return void 0;
576
576
  }
577
- const json = chunk2QWFVPYY_cjs.readSync(pkgPath);
577
+ const json = chunkMSMNDHDO_cjs.readSync(pkgPath);
578
578
  return JSON.parse(json);
579
579
  }
580
580
  static setVersion(dependency, version) {
581
- chunkSZ54MX56_cjs.__privateGet(_PackageManager, _cache)[dependency] = version;
581
+ chunkJ5QWFPI4_cjs.__privateGet(_PackageManager, _cache)[dependency] = version;
582
582
  }
583
583
  async getVersion(dependency) {
584
- if (typeof dependency === "string" && chunkSZ54MX56_cjs.__privateGet(_PackageManager, _cache)[dependency]) {
585
- return chunkSZ54MX56_cjs.__privateGet(_PackageManager, _cache)[dependency];
584
+ if (typeof dependency === "string" && chunkJ5QWFPI4_cjs.__privateGet(_PackageManager, _cache)[dependency]) {
585
+ return chunkJ5QWFPI4_cjs.__privateGet(_PackageManager, _cache)[dependency];
586
586
  }
587
587
  const packageJSON = await this.getPackageJSON();
588
588
  if (!packageJSON) {
589
589
  return void 0;
590
590
  }
591
- return chunkSZ54MX56_cjs.__privateMethod(this, _match, match_fn).call(this, packageJSON, dependency);
591
+ return chunkJ5QWFPI4_cjs.__privateMethod(this, _match, match_fn).call(this, packageJSON, dependency);
592
592
  }
593
593
  getVersionSync(dependency) {
594
- if (typeof dependency === "string" && chunkSZ54MX56_cjs.__privateGet(_PackageManager, _cache)[dependency]) {
595
- return chunkSZ54MX56_cjs.__privateGet(_PackageManager, _cache)[dependency];
594
+ if (typeof dependency === "string" && chunkJ5QWFPI4_cjs.__privateGet(_PackageManager, _cache)[dependency]) {
595
+ return chunkJ5QWFPI4_cjs.__privateGet(_PackageManager, _cache)[dependency];
596
596
  }
597
597
  const packageJSON = this.getPackageJSONSync();
598
598
  if (!packageJSON) {
599
599
  return void 0;
600
600
  }
601
- return chunkSZ54MX56_cjs.__privateMethod(this, _match, match_fn).call(this, packageJSON, dependency);
601
+ return chunkJ5QWFPI4_cjs.__privateMethod(this, _match, match_fn).call(this, packageJSON, dependency);
602
602
  }
603
603
  async isValid(dependency, version) {
604
604
  const packageVersion = await this.getVersion(dependency);
@@ -641,44 +641,44 @@ match_fn = function(packageJSON, dependency) {
641
641
  const matchedDependency = Object.keys(dependencies).find((dep) => dep.match(dependency));
642
642
  return matchedDependency ? dependencies[matchedDependency] : void 0;
643
643
  };
644
- chunkSZ54MX56_cjs.__privateAdd(_PackageManager, _cache, {});
644
+ chunkJ5QWFPI4_cjs.__privateAdd(_PackageManager, _cache, {});
645
645
  var PackageManager = _PackageManager;
646
646
 
647
647
  // src/kubb.ts
648
648
  var kubb_exports = {};
649
- chunkSZ54MX56_cjs.init_cjs_shims();
649
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
650
650
 
651
651
  Object.defineProperty(exports, "FileManager", {
652
652
  enumerable: true,
653
- get: function () { return chunk4HMCTZVL_cjs.FileManager; }
653
+ get: function () { return chunkJVCA27M5_cjs.FileManager; }
654
654
  });
655
655
  Object.defineProperty(exports, "KubbFile", {
656
656
  enumerable: true,
657
- get: function () { return chunk4HMCTZVL_cjs.KubbFile; }
657
+ get: function () { return chunkJVCA27M5_cjs.KubbFile; }
658
658
  });
659
659
  Object.defineProperty(exports, "PluginManager", {
660
660
  enumerable: true,
661
- get: function () { return chunk4HMCTZVL_cjs.PluginManager; }
661
+ get: function () { return chunkJVCA27M5_cjs.PluginManager; }
662
662
  });
663
663
  Object.defineProperty(exports, "PromiseManager", {
664
664
  enumerable: true,
665
- get: function () { return chunk4HMCTZVL_cjs.PromiseManager; }
665
+ get: function () { return chunkJVCA27M5_cjs.PromiseManager; }
666
666
  });
667
667
  Object.defineProperty(exports, "Warning", {
668
668
  enumerable: true,
669
- get: function () { return chunk4HMCTZVL_cjs.Warning; }
669
+ get: function () { return chunkJVCA27M5_cjs.Warning; }
670
670
  });
671
671
  Object.defineProperty(exports, "createPlugin", {
672
672
  enumerable: true,
673
- get: function () { return chunk4HMCTZVL_cjs.createPlugin; }
673
+ get: function () { return chunkJVCA27M5_cjs.createPlugin; }
674
674
  });
675
675
  Object.defineProperty(exports, "name", {
676
676
  enumerable: true,
677
- get: function () { return chunk4HMCTZVL_cjs.pluginName; }
677
+ get: function () { return chunkJVCA27M5_cjs.pluginName; }
678
678
  });
679
679
  Object.defineProperty(exports, "pluginName", {
680
680
  enumerable: true,
681
- get: function () { return chunk4HMCTZVL_cjs.pluginName; }
681
+ get: function () { return chunkJVCA27M5_cjs.pluginName; }
682
682
  });
683
683
  exports.Generator = Generator;
684
684
  exports.Kubb = kubb_exports;
package/dist/index.d.cts CHANGED
@@ -1,8 +1,8 @@
1
1
  import PQueue from 'p-queue';
2
- import { w as write, r as read } from './write-A6VgHkYA.cjs';
2
+ import { w as write, r as read } from './write-CN8f7bYv.cjs';
3
3
  import { TupleToUnion, ObjValueTuple, PossiblePromise, GreaterThan } from '@kubb/types';
4
4
  import { DirectoryTreeOptions } from 'directory-tree';
5
- import { E as EventEmitter, L as Logger, a as LogLevel } from './logger-wryz32Ex.cjs';
5
+ import { E as EventEmitter, L as Logger, a as LogLevel } from './logger-DjcF5DGc.cjs';
6
6
  import 'ora';
7
7
 
8
8
  type BarrelManagerOptions = {
package/dist/index.d.ts CHANGED
@@ -1,8 +1,8 @@
1
1
  import PQueue from 'p-queue';
2
- import { w as write, r as read } from './write-A6VgHkYA.js';
2
+ import { w as write, r as read } from './write-CN8f7bYv.js';
3
3
  import { TupleToUnion, ObjValueTuple, PossiblePromise, GreaterThan } from '@kubb/types';
4
4
  import { DirectoryTreeOptions } from 'directory-tree';
5
- import { E as EventEmitter, L as Logger, a as LogLevel } from './logger-wryz32Ex.js';
5
+ import { E as EventEmitter, L as Logger, a as LogLevel } from './logger-DjcF5DGc.js';
6
6
  import 'ora';
7
7
 
8
8
  type BarrelManagerOptions = {
package/dist/index.js CHANGED
@@ -1,14 +1,14 @@
1
- import { URLPath } from './chunk-R2IZ7YIQ.js';
2
- import { clean } from './chunk-XR7R5ICB.js';
3
- import { FileManager, PluginManager, isPromise } from './chunk-CIHAHMSS.js';
4
- export { FileManager, KubbFile, PluginManager, PromiseManager, Warning, createPlugin, pluginName as name, pluginName } from './chunk-CIHAHMSS.js';
5
- import './chunk-SUPR72XS.js';
6
- import './chunk-6WTZL3YP.js';
7
- import './chunk-UKW32O5T.js';
8
- import { LogLevel, createLogger, p, randomCliColour } from './chunk-65KNHWCO.js';
9
- import { read, readSync } from './chunk-SC6FZSNN.js';
10
- import './chunk-3TKNCRJ4.js';
11
- import { init_esm_shims, __privateAdd, __privateSet, __privateGet, __privateMethod } from './chunk-FTZMI4WB.js';
1
+ import { URLPath } from './chunk-ZFWX24A2.js';
2
+ import { clean } from './chunk-VM6OSFNQ.js';
3
+ import { FileManager, PluginManager, isPromise } from './chunk-MSOTSQG5.js';
4
+ export { FileManager, KubbFile, PluginManager, PromiseManager, Warning, createPlugin, pluginName as name, pluginName } from './chunk-MSOTSQG5.js';
5
+ import './chunk-RC2A4MWB.js';
6
+ import './chunk-F6NVPUP6.js';
7
+ import './chunk-JSSTXTHS.js';
8
+ import { LogLevel, createLogger, p, randomCliColour } from './chunk-MAQLBPOG.js';
9
+ import { read, readSync } from './chunk-R4FBPLRJ.js';
10
+ import './chunk-42FTVCX7.js';
11
+ import { init_esm_shims, __privateAdd, __privateSet, __privateGet, __privateMethod } from './chunk-5X45CG5S.js';
12
12
  import mod from 'module';
13
13
  import os from 'os';
14
14
  import { pathToFileURL } from 'url';
package/dist/logger.cjs CHANGED
@@ -1,26 +1,26 @@
1
1
  'use strict';
2
2
 
3
- var chunkUTRM3BSJ_cjs = require('./chunk-UTRM3BSJ.cjs');
4
- require('./chunk-HM4ZU273.cjs');
5
- require('./chunk-SZ54MX56.cjs');
3
+ var chunkJVC5YZVA_cjs = require('./chunk-JVC5YZVA.cjs');
4
+ require('./chunk-KQZNQA3D.cjs');
5
+ require('./chunk-J5QWFPI4.cjs');
6
6
 
7
7
 
8
8
 
9
9
  Object.defineProperty(exports, "LogLevel", {
10
10
  enumerable: true,
11
- get: function () { return chunkUTRM3BSJ_cjs.LogLevel; }
11
+ get: function () { return chunkJVC5YZVA_cjs.LogLevel; }
12
12
  });
13
13
  Object.defineProperty(exports, "createLogger", {
14
14
  enumerable: true,
15
- get: function () { return chunkUTRM3BSJ_cjs.createLogger; }
15
+ get: function () { return chunkJVC5YZVA_cjs.createLogger; }
16
16
  });
17
17
  Object.defineProperty(exports, "randomCliColour", {
18
18
  enumerable: true,
19
- get: function () { return chunkUTRM3BSJ_cjs.randomCliColour; }
19
+ get: function () { return chunkJVC5YZVA_cjs.randomCliColour; }
20
20
  });
21
21
  Object.defineProperty(exports, "randomColour", {
22
22
  enumerable: true,
23
- get: function () { return chunkUTRM3BSJ_cjs.randomColour; }
23
+ get: function () { return chunkJVC5YZVA_cjs.randomColour; }
24
24
  });
25
25
  //# sourceMappingURL=out.js.map
26
26
  //# sourceMappingURL=logger.cjs.map
package/dist/logger.d.cts CHANGED
@@ -1,2 +1,2 @@
1
- export { a as LogLevel, L as Logger, c as createLogger, b as randomCliColour, r as randomColour } from './logger-wryz32Ex.cjs';
1
+ export { a as LogLevel, L as Logger, c as createLogger, b as randomCliColour, r as randomColour } from './logger-DjcF5DGc.cjs';
2
2
  import 'ora';
package/dist/logger.d.ts CHANGED
@@ -1,2 +1,2 @@
1
- export { a as LogLevel, L as Logger, c as createLogger, b as randomCliColour, r as randomColour } from './logger-wryz32Ex.js';
1
+ export { a as LogLevel, L as Logger, c as createLogger, b as randomCliColour, r as randomColour } from './logger-DjcF5DGc.js';
2
2
  import 'ora';
package/dist/logger.js CHANGED
@@ -1,5 +1,5 @@
1
- export { LogLevel, createLogger, randomCliColour, randomColour } from './chunk-65KNHWCO.js';
2
- import './chunk-3TKNCRJ4.js';
3
- import './chunk-FTZMI4WB.js';
1
+ export { LogLevel, createLogger, randomCliColour, randomColour } from './chunk-MAQLBPOG.js';
2
+ import './chunk-42FTVCX7.js';
3
+ import './chunk-5X45CG5S.js';
4
4
  //# sourceMappingURL=out.js.map
5
5
  //# sourceMappingURL=logger.js.map
package/dist/mocks.cjs CHANGED
@@ -1,20 +1,20 @@
1
1
  'use strict';
2
2
 
3
- require('./chunk-4HMCTZVL.cjs');
4
- require('./chunk-HL4EB6OW.cjs');
5
- require('./chunk-77RJ5DJW.cjs');
6
- var chunkUQCQ5BUS_cjs = require('./chunk-UQCQ5BUS.cjs');
7
- require('./chunk-UTRM3BSJ.cjs');
8
- require('./chunk-2QWFVPYY.cjs');
9
- require('./chunk-HM4ZU273.cjs');
10
- var chunkSZ54MX56_cjs = require('./chunk-SZ54MX56.cjs');
3
+ require('./chunk-JVCA27M5.cjs');
4
+ require('./chunk-Z2DIGHSC.cjs');
5
+ require('./chunk-7XH3IIIO.cjs');
6
+ var chunkUCW7372N_cjs = require('./chunk-UCW7372N.cjs');
7
+ require('./chunk-JVC5YZVA.cjs');
8
+ require('./chunk-MSMNDHDO.cjs');
9
+ require('./chunk-KQZNQA3D.cjs');
10
+ var chunkJ5QWFPI4_cjs = require('./chunk-J5QWFPI4.cjs');
11
11
 
12
12
  // mocks/index.ts
13
- chunkSZ54MX56_cjs.init_cjs_shims();
13
+ chunkJ5QWFPI4_cjs.init_cjs_shims();
14
14
  var mockedPluginManager = {
15
15
  resolveName: ({ name, type }) => {
16
16
  if (type === "type") {
17
- return chunkUQCQ5BUS_cjs.pascalCase(name);
17
+ return chunkUCW7372N_cjs.pascalCase(name);
18
18
  }
19
19
  return name;
20
20
  },
package/dist/mocks.d.cts CHANGED
@@ -1,9 +1,9 @@
1
1
  import { PluginManager } from './index.cjs';
2
2
  import 'p-queue';
3
- import './write-A6VgHkYA.cjs';
3
+ import './write-CN8f7bYv.cjs';
4
4
  import '@kubb/types';
5
5
  import 'directory-tree';
6
- import './logger-wryz32Ex.cjs';
6
+ import './logger-DjcF5DGc.cjs';
7
7
  import 'ora';
8
8
 
9
9
  declare const mockedPluginManager: PluginManager;
package/dist/mocks.d.ts CHANGED
@@ -1,9 +1,9 @@
1
1
  import { PluginManager } from './index.js';
2
2
  import 'p-queue';
3
- import './write-A6VgHkYA.js';
3
+ import './write-CN8f7bYv.js';
4
4
  import '@kubb/types';
5
5
  import 'directory-tree';
6
- import './logger-wryz32Ex.js';
6
+ import './logger-DjcF5DGc.js';
7
7
  import 'ora';
8
8
 
9
9
  declare const mockedPluginManager: PluginManager;