opencommit 3.2.9 → 3.2.11

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 (3) hide show
  1. package/README.md +17 -1
  2. package/out/cli.cjs +2062 -902
  3. package/package.json +2 -1
package/out/cli.cjs CHANGED
@@ -161,6 +161,843 @@ var require_picocolors = __commonJS({
161
161
  }
162
162
  });
163
163
 
164
+ // node_modules/@clack/core/dist/index.mjs
165
+ function q3({ onlyFirst: t2 = false } = {}) {
166
+ const u3 = ["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)", "(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");
167
+ return new RegExp(u3, t2 ? void 0 : "g");
168
+ }
169
+ function S3(t2) {
170
+ if (typeof t2 != "string") throw new TypeError(`Expected a \`string\`, got \`${typeof t2}\``);
171
+ return t2.replace(q3(), "");
172
+ }
173
+ function j2(t2) {
174
+ return t2 && t2.__esModule && Object.prototype.hasOwnProperty.call(t2, "default") ? t2.default : t2;
175
+ }
176
+ function A2(t2, u3 = {}) {
177
+ if (typeof t2 != "string" || t2.length === 0 || (u3 = { ambiguousIsNarrow: true, ...u3 }, t2 = S3(t2), t2.length === 0)) return 0;
178
+ t2 = t2.replace(DD2(), " ");
179
+ const F5 = u3.ambiguousIsNarrow ? 1 : 2;
180
+ let e3 = 0;
181
+ for (const s2 of t2) {
182
+ const C5 = s2.codePointAt(0);
183
+ if (C5 <= 31 || C5 >= 127 && C5 <= 159 || C5 >= 768 && C5 <= 879) continue;
184
+ switch (Q2.eastAsianWidth(s2)) {
185
+ case "F":
186
+ case "W":
187
+ e3 += 2;
188
+ break;
189
+ case "A":
190
+ e3 += F5;
191
+ break;
192
+ default:
193
+ e3 += 1;
194
+ }
195
+ }
196
+ return e3;
197
+ }
198
+ function tD2() {
199
+ const t2 = /* @__PURE__ */ new Map();
200
+ for (const [u3, F5] of Object.entries(r)) {
201
+ for (const [e3, s2] of Object.entries(F5)) r[e3] = { open: `\x1B[${s2[0]}m`, close: `\x1B[${s2[1]}m` }, F5[e3] = r[e3], t2.set(s2[0], s2[1]);
202
+ Object.defineProperty(r, u3, { value: F5, enumerable: false });
203
+ }
204
+ return Object.defineProperty(r, "codes", { value: t2, enumerable: false }), r.color.close = "\x1B[39m", r.bgColor.close = "\x1B[49m", r.color.ansi = T4(), r.color.ansi256 = P2(), r.color.ansi16m = W3(), r.bgColor.ansi = T4(m3), r.bgColor.ansi256 = P2(m3), r.bgColor.ansi16m = W3(m3), Object.defineProperties(r, { rgbToAnsi256: { value: (u3, F5, e3) => u3 === F5 && F5 === e3 ? u3 < 8 ? 16 : u3 > 248 ? 231 : Math.round((u3 - 8) / 247 * 24) + 232 : 16 + 36 * Math.round(u3 / 255 * 5) + 6 * Math.round(F5 / 255 * 5) + Math.round(e3 / 255 * 5), enumerable: false }, hexToRgb: { value: (u3) => {
205
+ const F5 = /[a-f\d]{6}|[a-f\d]{3}/i.exec(u3.toString(16));
206
+ if (!F5) return [0, 0, 0];
207
+ let [e3] = F5;
208
+ e3.length === 3 && (e3 = [...e3].map((C5) => C5 + C5).join(""));
209
+ const s2 = Number.parseInt(e3, 16);
210
+ return [s2 >> 16 & 255, s2 >> 8 & 255, s2 & 255];
211
+ }, enumerable: false }, hexToAnsi256: { value: (u3) => r.rgbToAnsi256(...r.hexToRgb(u3)), enumerable: false }, ansi256ToAnsi: { value: (u3) => {
212
+ if (u3 < 8) return 30 + u3;
213
+ if (u3 < 16) return 90 + (u3 - 8);
214
+ let F5, e3, s2;
215
+ if (u3 >= 232) F5 = ((u3 - 232) * 10 + 8) / 255, e3 = F5, s2 = F5;
216
+ else {
217
+ u3 -= 16;
218
+ const i3 = u3 % 36;
219
+ F5 = Math.floor(u3 / 36) / 5, e3 = Math.floor(i3 / 6) / 5, s2 = i3 % 6 / 5;
220
+ }
221
+ const C5 = Math.max(F5, e3, s2) * 2;
222
+ if (C5 === 0) return 30;
223
+ let D5 = 30 + (Math.round(s2) << 2 | Math.round(e3) << 1 | Math.round(F5));
224
+ return C5 === 2 && (D5 += 60), D5;
225
+ }, enumerable: false }, rgbToAnsi: { value: (u3, F5, e3) => r.ansi256ToAnsi(r.rgbToAnsi256(u3, F5, e3)), enumerable: false }, hexToAnsi: { value: (u3) => r.ansi256ToAnsi(r.hexToAnsi256(u3)), enumerable: false } }), r;
226
+ }
227
+ function R4(t2, u3, F5) {
228
+ return String(t2).normalize().replace(/\r\n/g, `
229
+ `).split(`
230
+ `).map((e3) => ED2(e3, u3, F5)).join(`
231
+ `);
232
+ }
233
+ function aD2(t2, u3) {
234
+ if (t2 === u3) return;
235
+ const F5 = t2.split(`
236
+ `), e3 = u3.split(`
237
+ `), s2 = [];
238
+ for (let C5 = 0; C5 < Math.max(F5.length, e3.length); C5++) F5[C5] !== e3[C5] && s2.push(C5);
239
+ return s2;
240
+ }
241
+ function hD2(t2) {
242
+ return t2 === V4;
243
+ }
244
+ function v3(t2, u3) {
245
+ t2.isTTY && t2.setRawMode(u3);
246
+ }
247
+ function WD({ input: t2 = import_node_process.stdin, output: u3 = import_node_process.stdout, overwrite: F5 = true, hideCursor: e3 = true } = {}) {
248
+ const s2 = f.createInterface({ input: t2, output: u3, prompt: "", tabSize: 1 });
249
+ f.emitKeypressEvents(t2, s2), t2.isTTY && t2.setRawMode(true);
250
+ const C5 = (D5, { name: i3 }) => {
251
+ if (String(D5) === "" && process.exit(0), !F5) return;
252
+ let n2 = i3 === "return" ? 0 : -1, E4 = i3 === "return" ? -1 : 0;
253
+ f.moveCursor(u3, n2, E4, () => {
254
+ f.clearLine(u3, 1, () => {
255
+ t2.once("keypress", C5);
256
+ });
257
+ });
258
+ };
259
+ return e3 && process.stdout.write(import_sisteransi.cursor.hide), t2.once("keypress", C5), () => {
260
+ t2.off("keypress", C5), e3 && process.stdout.write(import_sisteransi.cursor.show), t2.isTTY && !PD && t2.setRawMode(false), s2.terminal = false, s2.close();
261
+ };
262
+ }
263
+ var import_sisteransi, import_node_process, f, import_node_readline, import_node_tty, import_picocolors, M3, J3, Q2, X2, DD2, m3, T4, P2, W3, r, uD2, FD2, eD2, g2, sD2, b4, O3, CD2, I3, w4, N3, L4, iD2, y3, rD2, ED2, oD2, nD2, a, V4, z3, lD2, x3, xD2, BD2, cD2, G4, AD2, pD2, fD2, K3, gD2, vD, dD2, Y2, mD2, bD2, wD2, Z3, yD, $D, kD, H3, _D, SD, jD, MD, TD, PD;
264
+ var init_dist = __esm({
265
+ "node_modules/@clack/core/dist/index.mjs"() {
266
+ import_sisteransi = __toESM(require_src(), 1);
267
+ import_node_process = require("node:process");
268
+ f = __toESM(require("node:readline"), 1);
269
+ import_node_readline = __toESM(require("node:readline"), 1);
270
+ import_node_tty = require("node:tty");
271
+ import_picocolors = __toESM(require_picocolors(), 1);
272
+ M3 = { exports: {} };
273
+ (function(t2) {
274
+ var u3 = {};
275
+ t2.exports = u3, u3.eastAsianWidth = function(e3) {
276
+ var s2 = e3.charCodeAt(0), C5 = e3.length == 2 ? e3.charCodeAt(1) : 0, D5 = s2;
277
+ return 55296 <= s2 && s2 <= 56319 && 56320 <= C5 && C5 <= 57343 && (s2 &= 1023, C5 &= 1023, D5 = s2 << 10 | C5, D5 += 65536), D5 == 12288 || 65281 <= D5 && D5 <= 65376 || 65504 <= D5 && D5 <= 65510 ? "F" : D5 == 8361 || 65377 <= D5 && D5 <= 65470 || 65474 <= D5 && D5 <= 65479 || 65482 <= D5 && D5 <= 65487 || 65490 <= D5 && D5 <= 65495 || 65498 <= D5 && D5 <= 65500 || 65512 <= D5 && D5 <= 65518 ? "H" : 4352 <= D5 && D5 <= 4447 || 4515 <= D5 && D5 <= 4519 || 4602 <= D5 && D5 <= 4607 || 9001 <= D5 && D5 <= 9002 || 11904 <= D5 && D5 <= 11929 || 11931 <= D5 && D5 <= 12019 || 12032 <= D5 && D5 <= 12245 || 12272 <= D5 && D5 <= 12283 || 12289 <= D5 && D5 <= 12350 || 12353 <= D5 && D5 <= 12438 || 12441 <= D5 && D5 <= 12543 || 12549 <= D5 && D5 <= 12589 || 12593 <= D5 && D5 <= 12686 || 12688 <= D5 && D5 <= 12730 || 12736 <= D5 && D5 <= 12771 || 12784 <= D5 && D5 <= 12830 || 12832 <= D5 && D5 <= 12871 || 12880 <= D5 && D5 <= 13054 || 13056 <= D5 && D5 <= 19903 || 19968 <= D5 && D5 <= 42124 || 42128 <= D5 && D5 <= 42182 || 43360 <= D5 && D5 <= 43388 || 44032 <= D5 && D5 <= 55203 || 55216 <= D5 && D5 <= 55238 || 55243 <= D5 && D5 <= 55291 || 63744 <= D5 && D5 <= 64255 || 65040 <= D5 && D5 <= 65049 || 65072 <= D5 && D5 <= 65106 || 65108 <= D5 && D5 <= 65126 || 65128 <= D5 && D5 <= 65131 || 110592 <= D5 && D5 <= 110593 || 127488 <= D5 && D5 <= 127490 || 127504 <= D5 && D5 <= 127546 || 127552 <= D5 && D5 <= 127560 || 127568 <= D5 && D5 <= 127569 || 131072 <= D5 && D5 <= 194367 || 177984 <= D5 && D5 <= 196605 || 196608 <= D5 && D5 <= 262141 ? "W" : 32 <= D5 && D5 <= 126 || 162 <= D5 && D5 <= 163 || 165 <= D5 && D5 <= 166 || D5 == 172 || D5 == 175 || 10214 <= D5 && D5 <= 10221 || 10629 <= D5 && D5 <= 10630 ? "Na" : D5 == 161 || D5 == 164 || 167 <= D5 && D5 <= 168 || D5 == 170 || 173 <= D5 && D5 <= 174 || 176 <= D5 && D5 <= 180 || 182 <= D5 && D5 <= 186 || 188 <= D5 && D5 <= 191 || D5 == 198 || D5 == 208 || 215 <= D5 && D5 <= 216 || 222 <= D5 && D5 <= 225 || D5 == 230 || 232 <= D5 && D5 <= 234 || 236 <= D5 && D5 <= 237 || D5 == 240 || 242 <= D5 && D5 <= 243 || 247 <= D5 && D5 <= 250 || D5 == 252 || D5 == 254 || D5 == 257 || D5 == 273 || D5 == 275 || D5 == 283 || 294 <= D5 && D5 <= 295 || D5 == 299 || 305 <= D5 && D5 <= 307 || D5 == 312 || 319 <= D5 && D5 <= 322 || D5 == 324 || 328 <= D5 && D5 <= 331 || D5 == 333 || 338 <= D5 && D5 <= 339 || 358 <= D5 && D5 <= 359 || D5 == 363 || D5 == 462 || D5 == 464 || D5 == 466 || D5 == 468 || D5 == 470 || D5 == 472 || D5 == 474 || D5 == 476 || D5 == 593 || D5 == 609 || D5 == 708 || D5 == 711 || 713 <= D5 && D5 <= 715 || D5 == 717 || D5 == 720 || 728 <= D5 && D5 <= 731 || D5 == 733 || D5 == 735 || 768 <= D5 && D5 <= 879 || 913 <= D5 && D5 <= 929 || 931 <= D5 && D5 <= 937 || 945 <= D5 && D5 <= 961 || 963 <= D5 && D5 <= 969 || D5 == 1025 || 1040 <= D5 && D5 <= 1103 || D5 == 1105 || D5 == 8208 || 8211 <= D5 && D5 <= 8214 || 8216 <= D5 && D5 <= 8217 || 8220 <= D5 && D5 <= 8221 || 8224 <= D5 && D5 <= 8226 || 8228 <= D5 && D5 <= 8231 || D5 == 8240 || 8242 <= D5 && D5 <= 8243 || D5 == 8245 || D5 == 8251 || D5 == 8254 || D5 == 8308 || D5 == 8319 || 8321 <= D5 && D5 <= 8324 || D5 == 8364 || D5 == 8451 || D5 == 8453 || D5 == 8457 || D5 == 8467 || D5 == 8470 || 8481 <= D5 && D5 <= 8482 || D5 == 8486 || D5 == 8491 || 8531 <= D5 && D5 <= 8532 || 8539 <= D5 && D5 <= 8542 || 8544 <= D5 && D5 <= 8555 || 8560 <= D5 && D5 <= 8569 || D5 == 8585 || 8592 <= D5 && D5 <= 8601 || 8632 <= D5 && D5 <= 8633 || D5 == 8658 || D5 == 8660 || D5 == 8679 || D5 == 8704 || 8706 <= D5 && D5 <= 8707 || 8711 <= D5 && D5 <= 8712 || D5 == 8715 || D5 == 8719 || D5 == 8721 || D5 == 8725 || D5 == 8730 || 8733 <= D5 && D5 <= 8736 || D5 == 8739 || D5 == 8741 || 8743 <= D5 && D5 <= 8748 || D5 == 8750 || 8756 <= D5 && D5 <= 8759 || 8764 <= D5 && D5 <= 8765 || D5 == 8776 || D5 == 8780 || D5 == 8786 || 8800 <= D5 && D5 <= 8801 || 8804 <= D5 && D5 <= 8807 || 8810 <= D5 && D5 <= 8811 || 8814 <= D5 && D5 <= 8815 || 8834 <= D5 && D5 <= 8835 || 8838 <= D5 && D5 <= 8839 || D5 == 8853 || D5 == 8857 || D5 == 8869 || D5 == 8895 || D5 == 8978 || 9312 <= D5 && D5 <= 9449 || 9451 <= D5 && D5 <= 9547 || 9552 <= D5 && D5 <= 9587 || 9600 <= D5 && D5 <= 9615 || 9618 <= D5 && D5 <= 9621 || 9632 <= D5 && D5 <= 9633 || 9635 <= D5 && D5 <= 9641 || 9650 <= D5 && D5 <= 9651 || 9654 <= D5 && D5 <= 9655 || 9660 <= D5 && D5 <= 9661 || 9664 <= D5 && D5 <= 9665 || 9670 <= D5 && D5 <= 9672 || D5 == 9675 || 9678 <= D5 && D5 <= 9681 || 9698 <= D5 && D5 <= 9701 || D5 == 9711 || 9733 <= D5 && D5 <= 9734 || D5 == 9737 || 9742 <= D5 && D5 <= 9743 || 9748 <= D5 && D5 <= 9749 || D5 == 9756 || D5 == 9758 || D5 == 9792 || D5 == 9794 || 9824 <= D5 && D5 <= 9825 || 9827 <= D5 && D5 <= 9829 || 9831 <= D5 && D5 <= 9834 || 9836 <= D5 && D5 <= 9837 || D5 == 9839 || 9886 <= D5 && D5 <= 9887 || 9918 <= D5 && D5 <= 9919 || 9924 <= D5 && D5 <= 9933 || 9935 <= D5 && D5 <= 9953 || D5 == 9955 || 9960 <= D5 && D5 <= 9983 || D5 == 10045 || D5 == 10071 || 10102 <= D5 && D5 <= 10111 || 11093 <= D5 && D5 <= 11097 || 12872 <= D5 && D5 <= 12879 || 57344 <= D5 && D5 <= 63743 || 65024 <= D5 && D5 <= 65039 || D5 == 65533 || 127232 <= D5 && D5 <= 127242 || 127248 <= D5 && D5 <= 127277 || 127280 <= D5 && D5 <= 127337 || 127344 <= D5 && D5 <= 127386 || 917760 <= D5 && D5 <= 917999 || 983040 <= D5 && D5 <= 1048573 || 1048576 <= D5 && D5 <= 1114109 ? "A" : "N";
278
+ }, u3.characterLength = function(e3) {
279
+ var s2 = this.eastAsianWidth(e3);
280
+ return s2 == "F" || s2 == "W" || s2 == "A" ? 2 : 1;
281
+ };
282
+ function F5(e3) {
283
+ return e3.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g) || [];
284
+ }
285
+ u3.length = function(e3) {
286
+ for (var s2 = F5(e3), C5 = 0, D5 = 0; D5 < s2.length; D5++) C5 = C5 + this.characterLength(s2[D5]);
287
+ return C5;
288
+ }, u3.slice = function(e3, s2, C5) {
289
+ textLen = u3.length(e3), s2 = s2 || 0, C5 = C5 || 1, s2 < 0 && (s2 = textLen + s2), C5 < 0 && (C5 = textLen + C5);
290
+ for (var D5 = "", i3 = 0, n2 = F5(e3), E4 = 0; E4 < n2.length; E4++) {
291
+ var h4 = n2[E4], o3 = u3.length(h4);
292
+ if (i3 >= s2 - (o3 == 2 ? 1 : 0)) if (i3 + o3 <= C5) D5 += h4;
293
+ else break;
294
+ i3 += o3;
295
+ }
296
+ return D5;
297
+ };
298
+ })(M3);
299
+ J3 = M3.exports;
300
+ Q2 = j2(J3);
301
+ X2 = function() {
302
+ return /\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67)\uDB40\uDC7F|(?:\uD83E\uDDD1\uD83C\uDFFF\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFC-\uDFFF])|\uD83D\uDC68(?:\uD83C\uDFFB(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|[\u2695\u2696\u2708]\uFE0F|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))?|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])\uFE0F|\u200D(?:(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D[\uDC66\uDC67])|\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC)?|(?:\uD83D\uDC69(?:\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69]))|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC69(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83E\uDDD1(?:\u200D(?:\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDE36\u200D\uD83C\uDF2B|\uD83C\uDFF3\uFE0F\u200D\u26A7|\uD83D\uDC3B\u200D\u2744|(?:(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\uD83C\uDFF4\u200D\u2620|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])\u200D[\u2640\u2642]|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u3030\u303D\u3297\u3299]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]|\uD83D[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])\uFE0F|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDE35\u200D\uD83D\uDCAB|\uD83D\uDE2E\u200D\uD83D\uDCA8|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83E\uDDD1(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83D\uDC69(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF6\uD83C\uDDE6|\uD83C\uDDF4\uD83C\uDDF2|\uD83D\uDC08\u200D\u2B1B|\u2764\uFE0F\u200D(?:\uD83D\uDD25|\uD83E\uDE79)|\uD83D\uDC41\uFE0F|\uD83C\uDFF3\uFE0F|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|[#\*0-9]\uFE0F\u20E3|\u2764\uFE0F|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|\uD83C\uDFF4|(?:[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270C\u270D]|\uD83D[\uDD74\uDD90])(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC08\uDC15\uDC3B\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE2E\uDE35\uDE36\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5]|\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD]|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF]|[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0D\uDD0E\uDD10-\uDD17\uDD1D\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78\uDD7A-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCB\uDDD0\uDDE0-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6]|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26A7\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5-\uDED7\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDD77\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g;
303
+ };
304
+ DD2 = j2(X2);
305
+ m3 = 10;
306
+ T4 = (t2 = 0) => (u3) => `\x1B[${u3 + t2}m`;
307
+ P2 = (t2 = 0) => (u3) => `\x1B[${38 + t2};5;${u3}m`;
308
+ W3 = (t2 = 0) => (u3, F5, e3) => `\x1B[${38 + t2};2;${u3};${F5};${e3}m`;
309
+ r = { modifier: { reset: [0, 0], bold: [1, 22], dim: [2, 22], italic: [3, 23], underline: [4, 24], overline: [53, 55], inverse: [7, 27], hidden: [8, 28], strikethrough: [9, 29] }, color: { black: [30, 39], red: [31, 39], green: [32, 39], yellow: [33, 39], blue: [34, 39], magenta: [35, 39], cyan: [36, 39], white: [37, 39], blackBright: [90, 39], gray: [90, 39], grey: [90, 39], redBright: [91, 39], greenBright: [92, 39], yellowBright: [93, 39], blueBright: [94, 39], magentaBright: [95, 39], cyanBright: [96, 39], whiteBright: [97, 39] }, bgColor: { bgBlack: [40, 49], bgRed: [41, 49], bgGreen: [42, 49], bgYellow: [43, 49], bgBlue: [44, 49], bgMagenta: [45, 49], bgCyan: [46, 49], bgWhite: [47, 49], bgBlackBright: [100, 49], bgGray: [100, 49], bgGrey: [100, 49], bgRedBright: [101, 49], bgGreenBright: [102, 49], bgYellowBright: [103, 49], bgBlueBright: [104, 49], bgMagentaBright: [105, 49], bgCyanBright: [106, 49], bgWhiteBright: [107, 49] } };
310
+ Object.keys(r.modifier);
311
+ uD2 = Object.keys(r.color);
312
+ FD2 = Object.keys(r.bgColor);
313
+ [...uD2, ...FD2];
314
+ eD2 = tD2();
315
+ g2 = /* @__PURE__ */ new Set(["\x1B", "\x9B"]);
316
+ sD2 = 39;
317
+ b4 = "\x07";
318
+ O3 = "[";
319
+ CD2 = "]";
320
+ I3 = "m";
321
+ w4 = `${CD2}8;;`;
322
+ N3 = (t2) => `${g2.values().next().value}${O3}${t2}${I3}`;
323
+ L4 = (t2) => `${g2.values().next().value}${w4}${t2}${b4}`;
324
+ iD2 = (t2) => t2.split(" ").map((u3) => A2(u3));
325
+ y3 = (t2, u3, F5) => {
326
+ const e3 = [...u3];
327
+ let s2 = false, C5 = false, D5 = A2(S3(t2[t2.length - 1]));
328
+ for (const [i3, n2] of e3.entries()) {
329
+ const E4 = A2(n2);
330
+ if (D5 + E4 <= F5 ? t2[t2.length - 1] += n2 : (t2.push(n2), D5 = 0), g2.has(n2) && (s2 = true, C5 = e3.slice(i3 + 1).join("").startsWith(w4)), s2) {
331
+ C5 ? n2 === b4 && (s2 = false, C5 = false) : n2 === I3 && (s2 = false);
332
+ continue;
333
+ }
334
+ D5 += E4, D5 === F5 && i3 < e3.length - 1 && (t2.push(""), D5 = 0);
335
+ }
336
+ !D5 && t2[t2.length - 1].length > 0 && t2.length > 1 && (t2[t2.length - 2] += t2.pop());
337
+ };
338
+ rD2 = (t2) => {
339
+ const u3 = t2.split(" ");
340
+ let F5 = u3.length;
341
+ for (; F5 > 0 && !(A2(u3[F5 - 1]) > 0); ) F5--;
342
+ return F5 === u3.length ? t2 : u3.slice(0, F5).join(" ") + u3.slice(F5).join("");
343
+ };
344
+ ED2 = (t2, u3, F5 = {}) => {
345
+ if (F5.trim !== false && t2.trim() === "") return "";
346
+ let e3 = "", s2, C5;
347
+ const D5 = iD2(t2);
348
+ let i3 = [""];
349
+ for (const [E4, h4] of t2.split(" ").entries()) {
350
+ F5.trim !== false && (i3[i3.length - 1] = i3[i3.length - 1].trimStart());
351
+ let o3 = A2(i3[i3.length - 1]);
352
+ if (E4 !== 0 && (o3 >= u3 && (F5.wordWrap === false || F5.trim === false) && (i3.push(""), o3 = 0), (o3 > 0 || F5.trim === false) && (i3[i3.length - 1] += " ", o3++)), F5.hard && D5[E4] > u3) {
353
+ const B3 = u3 - o3, p4 = 1 + Math.floor((D5[E4] - B3 - 1) / u3);
354
+ Math.floor((D5[E4] - 1) / u3) < p4 && i3.push(""), y3(i3, h4, u3);
355
+ continue;
356
+ }
357
+ if (o3 + D5[E4] > u3 && o3 > 0 && D5[E4] > 0) {
358
+ if (F5.wordWrap === false && o3 < u3) {
359
+ y3(i3, h4, u3);
360
+ continue;
361
+ }
362
+ i3.push("");
363
+ }
364
+ if (o3 + D5[E4] > u3 && F5.wordWrap === false) {
365
+ y3(i3, h4, u3);
366
+ continue;
367
+ }
368
+ i3[i3.length - 1] += h4;
369
+ }
370
+ F5.trim !== false && (i3 = i3.map((E4) => rD2(E4)));
371
+ const n2 = [...i3.join(`
372
+ `)];
373
+ for (const [E4, h4] of n2.entries()) {
374
+ if (e3 += h4, g2.has(h4)) {
375
+ const { groups: B3 } = new RegExp(`(?:\\${O3}(?<code>\\d+)m|\\${w4}(?<uri>.*)${b4})`).exec(n2.slice(E4).join("")) || { groups: {} };
376
+ if (B3.code !== void 0) {
377
+ const p4 = Number.parseFloat(B3.code);
378
+ s2 = p4 === sD2 ? void 0 : p4;
379
+ } else B3.uri !== void 0 && (C5 = B3.uri.length === 0 ? void 0 : B3.uri);
380
+ }
381
+ const o3 = eD2.codes.get(Number(s2));
382
+ n2[E4 + 1] === `
383
+ ` ? (C5 && (e3 += L4("")), s2 && o3 && (e3 += N3(o3))) : h4 === `
384
+ ` && (s2 && o3 && (e3 += N3(s2)), C5 && (e3 += L4(C5)));
385
+ }
386
+ return e3;
387
+ };
388
+ oD2 = Object.defineProperty;
389
+ nD2 = (t2, u3, F5) => u3 in t2 ? oD2(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
390
+ a = (t2, u3, F5) => (nD2(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
391
+ V4 = Symbol("clack:cancel");
392
+ z3 = /* @__PURE__ */ new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"]]);
393
+ lD2 = /* @__PURE__ */ new Set(["up", "down", "left", "right", "space", "enter"]);
394
+ x3 = class {
395
+ constructor({ render: u3, input: F5 = import_node_process.stdin, output: e3 = import_node_process.stdout, ...s2 }, C5 = true) {
396
+ a(this, "input"), a(this, "output"), a(this, "rl"), a(this, "opts"), a(this, "_track", false), a(this, "_render"), a(this, "_cursor", 0), a(this, "state", "initial"), a(this, "value"), a(this, "error", ""), a(this, "subscribers", /* @__PURE__ */ new Map()), a(this, "_prevFrame", ""), this.opts = s2, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = u3.bind(this), this._track = C5, this.input = F5, this.output = e3;
397
+ }
398
+ prompt() {
399
+ const u3 = new import_node_tty.WriteStream(0);
400
+ return u3._write = (F5, e3, s2) => {
401
+ this._track && (this.value = this.rl.line.replace(/\t/g, ""), this._cursor = this.rl.cursor, this.emit("value", this.value)), s2();
402
+ }, this.input.pipe(u3), this.rl = import_node_readline.default.createInterface({ input: this.input, output: u3, tabSize: 2, prompt: "", escapeCodeTimeout: 50 }), import_node_readline.default.emitKeypressEvents(this.input, this.rl), this.rl.prompt(), this.opts.initialValue !== void 0 && this._track && this.rl.write(this.opts.initialValue), this.input.on("keypress", this.onKeypress), v3(this.input, true), this.output.on("resize", this.render), this.render(), new Promise((F5, e3) => {
403
+ this.once("submit", () => {
404
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), v3(this.input, false), F5(this.value);
405
+ }), this.once("cancel", () => {
406
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), v3(this.input, false), F5(V4);
407
+ });
408
+ });
409
+ }
410
+ on(u3, F5) {
411
+ const e3 = this.subscribers.get(u3) ?? [];
412
+ e3.push({ cb: F5 }), this.subscribers.set(u3, e3);
413
+ }
414
+ once(u3, F5) {
415
+ const e3 = this.subscribers.get(u3) ?? [];
416
+ e3.push({ cb: F5, once: true }), this.subscribers.set(u3, e3);
417
+ }
418
+ emit(u3, ...F5) {
419
+ const e3 = this.subscribers.get(u3) ?? [], s2 = [];
420
+ for (const C5 of e3) C5.cb(...F5), C5.once && s2.push(() => e3.splice(e3.indexOf(C5), 1));
421
+ for (const C5 of s2) C5();
422
+ }
423
+ unsubscribe() {
424
+ this.subscribers.clear();
425
+ }
426
+ onKeypress(u3, F5) {
427
+ if (this.state === "error" && (this.state = "active"), F5?.name && !this._track && z3.has(F5.name) && this.emit("cursor", z3.get(F5.name)), F5?.name && lD2.has(F5.name) && this.emit("cursor", F5.name), u3 && (u3.toLowerCase() === "y" || u3.toLowerCase() === "n") && this.emit("confirm", u3.toLowerCase() === "y"), u3 === " " && this.opts.placeholder && (this.value || (this.rl.write(this.opts.placeholder), this.emit("value", this.opts.placeholder))), u3 && this.emit("key", u3.toLowerCase()), F5?.name === "return") {
428
+ if (this.opts.validate) {
429
+ const e3 = this.opts.validate(this.value);
430
+ e3 && (this.error = e3, this.state = "error", this.rl.write(this.value));
431
+ }
432
+ this.state !== "error" && (this.state = "submit");
433
+ }
434
+ u3 === "" && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
435
+ }
436
+ close() {
437
+ this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
438
+ `), v3(this.input, false), this.rl.close(), this.emit(`${this.state}`, this.value), this.unsubscribe();
439
+ }
440
+ restoreCursor() {
441
+ const u3 = R4(this._prevFrame, process.stdout.columns, { hard: true }).split(`
442
+ `).length - 1;
443
+ this.output.write(import_sisteransi.cursor.move(-999, u3 * -1));
444
+ }
445
+ render() {
446
+ const u3 = R4(this._render(this) ?? "", process.stdout.columns, { hard: true });
447
+ if (u3 !== this._prevFrame) {
448
+ if (this.state === "initial") this.output.write(import_sisteransi.cursor.hide);
449
+ else {
450
+ const F5 = aD2(this._prevFrame, u3);
451
+ if (this.restoreCursor(), F5 && F5?.length === 1) {
452
+ const e3 = F5[0];
453
+ this.output.write(import_sisteransi.cursor.move(0, e3)), this.output.write(import_sisteransi.erase.lines(1));
454
+ const s2 = u3.split(`
455
+ `);
456
+ this.output.write(s2[e3]), this._prevFrame = u3, this.output.write(import_sisteransi.cursor.move(0, s2.length - e3 - 1));
457
+ return;
458
+ } else if (F5 && F5?.length > 1) {
459
+ const e3 = F5[0];
460
+ this.output.write(import_sisteransi.cursor.move(0, e3)), this.output.write(import_sisteransi.erase.down());
461
+ const s2 = u3.split(`
462
+ `).slice(e3);
463
+ this.output.write(s2.join(`
464
+ `)), this._prevFrame = u3;
465
+ return;
466
+ }
467
+ this.output.write(import_sisteransi.erase.down());
468
+ }
469
+ this.output.write(u3), this.state === "initial" && (this.state = "active"), this._prevFrame = u3;
470
+ }
471
+ }
472
+ };
473
+ xD2 = class extends x3 {
474
+ get cursor() {
475
+ return this.value ? 0 : 1;
476
+ }
477
+ get _value() {
478
+ return this.cursor === 0;
479
+ }
480
+ constructor(u3) {
481
+ super(u3, false), this.value = !!u3.initialValue, this.on("value", () => {
482
+ this.value = this._value;
483
+ }), this.on("confirm", (F5) => {
484
+ this.output.write(import_sisteransi.cursor.move(0, -1)), this.value = F5, this.state = "submit", this.close();
485
+ }), this.on("cursor", () => {
486
+ this.value = !this.value;
487
+ });
488
+ }
489
+ };
490
+ BD2 = Object.defineProperty;
491
+ cD2 = (t2, u3, F5) => u3 in t2 ? BD2(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
492
+ G4 = (t2, u3, F5) => (cD2(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
493
+ AD2 = class extends x3 {
494
+ constructor(u3) {
495
+ super(u3, false), G4(this, "options"), G4(this, "cursor", 0);
496
+ const { options: F5 } = u3;
497
+ this.options = Object.entries(F5).flatMap(([e3, s2]) => [{ value: e3, group: true, label: e3 }, ...s2.map((C5) => ({ ...C5, group: e3 }))]), this.value = [...u3.initialValues ?? []], this.cursor = Math.max(this.options.findIndex(({ value: e3 }) => e3 === u3.cursorAt), 0), this.on("cursor", (e3) => {
498
+ switch (e3) {
499
+ case "left":
500
+ case "up":
501
+ this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
502
+ break;
503
+ case "down":
504
+ case "right":
505
+ this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
506
+ break;
507
+ case "space":
508
+ this.toggleValue();
509
+ break;
510
+ }
511
+ });
512
+ }
513
+ getGroupItems(u3) {
514
+ return this.options.filter((F5) => F5.group === u3);
515
+ }
516
+ isGroupSelected(u3) {
517
+ return this.getGroupItems(u3).every((F5) => this.value.includes(F5.value));
518
+ }
519
+ toggleValue() {
520
+ const u3 = this.options[this.cursor];
521
+ if (u3.group === true) {
522
+ const F5 = u3.value, e3 = this.getGroupItems(F5);
523
+ this.isGroupSelected(F5) ? this.value = this.value.filter((s2) => e3.findIndex((C5) => C5.value === s2) === -1) : this.value = [...this.value, ...e3.map((s2) => s2.value)], this.value = Array.from(new Set(this.value));
524
+ } else {
525
+ const F5 = this.value.includes(u3.value);
526
+ this.value = F5 ? this.value.filter((e3) => e3 !== u3.value) : [...this.value, u3.value];
527
+ }
528
+ }
529
+ };
530
+ pD2 = Object.defineProperty;
531
+ fD2 = (t2, u3, F5) => u3 in t2 ? pD2(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
532
+ K3 = (t2, u3, F5) => (fD2(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
533
+ gD2 = class extends x3 {
534
+ constructor(u3) {
535
+ super(u3, false), K3(this, "options"), K3(this, "cursor", 0), this.options = u3.options, this.value = [...u3.initialValues ?? []], this.cursor = Math.max(this.options.findIndex(({ value: F5 }) => F5 === u3.cursorAt), 0), this.on("key", (F5) => {
536
+ F5 === "a" && this.toggleAll();
537
+ }), this.on("cursor", (F5) => {
538
+ switch (F5) {
539
+ case "left":
540
+ case "up":
541
+ this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
542
+ break;
543
+ case "down":
544
+ case "right":
545
+ this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
546
+ break;
547
+ case "space":
548
+ this.toggleValue();
549
+ break;
550
+ }
551
+ });
552
+ }
553
+ get _value() {
554
+ return this.options[this.cursor].value;
555
+ }
556
+ toggleAll() {
557
+ const u3 = this.value.length === this.options.length;
558
+ this.value = u3 ? [] : this.options.map((F5) => F5.value);
559
+ }
560
+ toggleValue() {
561
+ const u3 = this.value.includes(this._value);
562
+ this.value = u3 ? this.value.filter((F5) => F5 !== this._value) : [...this.value, this._value];
563
+ }
564
+ };
565
+ vD = Object.defineProperty;
566
+ dD2 = (t2, u3, F5) => u3 in t2 ? vD(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
567
+ Y2 = (t2, u3, F5) => (dD2(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
568
+ mD2 = class extends x3 {
569
+ constructor({ mask: u3, ...F5 }) {
570
+ super(F5), Y2(this, "valueWithCursor", ""), Y2(this, "_mask", "\u2022"), this._mask = u3 ?? "\u2022", this.on("finalize", () => {
571
+ this.valueWithCursor = this.masked;
572
+ }), this.on("value", () => {
573
+ if (this.cursor >= this.value.length) this.valueWithCursor = `${this.masked}${import_picocolors.default.inverse(import_picocolors.default.hidden("_"))}`;
574
+ else {
575
+ const e3 = this.masked.slice(0, this.cursor), s2 = this.masked.slice(this.cursor);
576
+ this.valueWithCursor = `${e3}${import_picocolors.default.inverse(s2[0])}${s2.slice(1)}`;
577
+ }
578
+ });
579
+ }
580
+ get cursor() {
581
+ return this._cursor;
582
+ }
583
+ get masked() {
584
+ return this.value.replaceAll(/./g, this._mask);
585
+ }
586
+ };
587
+ bD2 = Object.defineProperty;
588
+ wD2 = (t2, u3, F5) => u3 in t2 ? bD2(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
589
+ Z3 = (t2, u3, F5) => (wD2(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
590
+ yD = class extends x3 {
591
+ constructor(u3) {
592
+ super(u3, false), Z3(this, "options"), Z3(this, "cursor", 0), this.options = u3.options, this.cursor = this.options.findIndex(({ value: F5 }) => F5 === u3.initialValue), this.cursor === -1 && (this.cursor = 0), this.changeValue(), this.on("cursor", (F5) => {
593
+ switch (F5) {
594
+ case "left":
595
+ case "up":
596
+ this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
597
+ break;
598
+ case "down":
599
+ case "right":
600
+ this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
601
+ break;
602
+ }
603
+ this.changeValue();
604
+ });
605
+ }
606
+ get _value() {
607
+ return this.options[this.cursor];
608
+ }
609
+ changeValue() {
610
+ this.value = this._value.value;
611
+ }
612
+ };
613
+ $D = Object.defineProperty;
614
+ kD = (t2, u3, F5) => u3 in t2 ? $D(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
615
+ H3 = (t2, u3, F5) => (kD(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
616
+ _D = class extends x3 {
617
+ constructor(u3) {
618
+ super(u3, false), H3(this, "options"), H3(this, "cursor", 0), this.options = u3.options;
619
+ const F5 = this.options.map(({ value: [e3] }) => e3?.toLowerCase());
620
+ this.cursor = Math.max(F5.indexOf(u3.initialValue), 0), this.on("key", (e3) => {
621
+ if (!F5.includes(e3)) return;
622
+ const s2 = this.options.find(({ value: [C5] }) => C5?.toLowerCase() === e3);
623
+ s2 && (this.value = s2.value, this.state = "submit", this.emit("submit"));
624
+ });
625
+ }
626
+ };
627
+ SD = Object.defineProperty;
628
+ jD = (t2, u3, F5) => u3 in t2 ? SD(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
629
+ MD = (t2, u3, F5) => (jD(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
630
+ TD = class extends x3 {
631
+ constructor(u3) {
632
+ super(u3), MD(this, "valueWithCursor", ""), this.on("finalize", () => {
633
+ this.value || (this.value = u3.defaultValue), this.valueWithCursor = this.value;
634
+ }), this.on("value", () => {
635
+ if (this.cursor >= this.value.length) this.valueWithCursor = `${this.value}${import_picocolors.default.inverse(import_picocolors.default.hidden("_"))}`;
636
+ else {
637
+ const F5 = this.value.slice(0, this.cursor), e3 = this.value.slice(this.cursor);
638
+ this.valueWithCursor = `${F5}${import_picocolors.default.inverse(e3[0])}${e3.slice(1)}`;
639
+ }
640
+ });
641
+ }
642
+ get cursor() {
643
+ return this._cursor;
644
+ }
645
+ };
646
+ PD = globalThis.process.platform.startsWith("win");
647
+ }
648
+ });
649
+
650
+ // node_modules/@clack/prompts/dist/index.mjs
651
+ var dist_exports = {};
652
+ __export(dist_exports, {
653
+ cancel: () => ne,
654
+ confirm: () => Q3,
655
+ group: () => $e,
656
+ groupMultiselect: () => se,
657
+ intro: () => ae,
658
+ isCancel: () => hD2,
659
+ log: () => g3,
660
+ multiselect: () => re,
661
+ note: () => ie,
662
+ outro: () => ce,
663
+ password: () => Y3,
664
+ select: () => ee,
665
+ selectKey: () => te,
666
+ spinner: () => le,
667
+ text: () => J4
668
+ });
669
+ function N4() {
670
+ return import_node_process2.default.platform !== "win32" ? import_node_process2.default.env.TERM !== "linux" : Boolean(import_node_process2.default.env.CI) || Boolean(import_node_process2.default.env.WT_SESSION) || Boolean(import_node_process2.default.env.TERMINUS_SUBLIME) || import_node_process2.default.env.ConEmuTask === "{cmd::Cmder}" || import_node_process2.default.env.TERM_PROGRAM === "Terminus-Sublime" || import_node_process2.default.env.TERM_PROGRAM === "vscode" || import_node_process2.default.env.TERM === "xterm-256color" || import_node_process2.default.env.TERM === "alacritty" || import_node_process2.default.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
671
+ }
672
+ function ue() {
673
+ const r3 = ["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)", "(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");
674
+ return new RegExp(r3, "g");
675
+ }
676
+ var import_node_process2, import_picocolors2, import_sisteransi2, p2, u, W4, D3, F3, f2, L5, a2, o, w5, S4, _5, y4, A3, q4, R5, G5, H4, K4, U5, Z4, z4, X3, h2, J4, Y3, Q3, ee, te, re, se, b5, ie, ne, ae, ce, g3, C3, le, $e;
677
+ var init_dist2 = __esm({
678
+ "node_modules/@clack/prompts/dist/index.mjs"() {
679
+ init_dist();
680
+ init_dist();
681
+ import_node_process2 = __toESM(require("node:process"), 1);
682
+ import_picocolors2 = __toESM(require_picocolors(), 1);
683
+ import_sisteransi2 = __toESM(require_src(), 1);
684
+ p2 = N4();
685
+ u = (r3, n2) => p2 ? r3 : n2;
686
+ W4 = u("\u25C6", "*");
687
+ D3 = u("\u25A0", "x");
688
+ F3 = u("\u25B2", "x");
689
+ f2 = u("\u25C7", "o");
690
+ L5 = u("\u250C", "T");
691
+ a2 = u("\u2502", "|");
692
+ o = u("\u2514", "\u2014");
693
+ w5 = u("\u25CF", ">");
694
+ S4 = u("\u25CB", " ");
695
+ _5 = u("\u25FB", "[\u2022]");
696
+ y4 = u("\u25FC", "[+]");
697
+ A3 = u("\u25FB", "[ ]");
698
+ q4 = u("\u25AA", "\u2022");
699
+ R5 = u("\u2500", "-");
700
+ G5 = u("\u256E", "+");
701
+ H4 = u("\u251C", "+");
702
+ K4 = u("\u256F", "+");
703
+ U5 = u("\u25CF", "\u2022");
704
+ Z4 = u("\u25C6", "*");
705
+ z4 = u("\u25B2", "!");
706
+ X3 = u("\u25A0", "x");
707
+ h2 = (r3) => {
708
+ switch (r3) {
709
+ case "initial":
710
+ case "active":
711
+ return import_picocolors2.default.cyan(W4);
712
+ case "cancel":
713
+ return import_picocolors2.default.red(D3);
714
+ case "error":
715
+ return import_picocolors2.default.yellow(F3);
716
+ case "submit":
717
+ return import_picocolors2.default.green(f2);
718
+ }
719
+ };
720
+ J4 = (r3) => new TD({ validate: r3.validate, placeholder: r3.placeholder, defaultValue: r3.defaultValue, initialValue: r3.initialValue, render() {
721
+ const n2 = `${import_picocolors2.default.gray(a2)}
722
+ ${h2(this.state)} ${r3.message}
723
+ `, s2 = r3.placeholder ? import_picocolors2.default.inverse(r3.placeholder[0]) + import_picocolors2.default.dim(r3.placeholder.slice(1)) : import_picocolors2.default.inverse(import_picocolors2.default.hidden("_")), t2 = this.value ? this.valueWithCursor : s2;
724
+ switch (this.state) {
725
+ case "error":
726
+ return `${n2.trim()}
727
+ ${import_picocolors2.default.yellow(a2)} ${t2}
728
+ ${import_picocolors2.default.yellow(o)} ${import_picocolors2.default.yellow(this.error)}
729
+ `;
730
+ case "submit":
731
+ return `${n2}${import_picocolors2.default.gray(a2)} ${import_picocolors2.default.dim(this.value || r3.placeholder)}`;
732
+ case "cancel":
733
+ return `${n2}${import_picocolors2.default.gray(a2)} ${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(this.value ?? ""))}${this.value?.trim() ? `
734
+ ` + import_picocolors2.default.gray(a2) : ""}`;
735
+ default:
736
+ return `${n2}${import_picocolors2.default.cyan(a2)} ${t2}
737
+ ${import_picocolors2.default.cyan(o)}
738
+ `;
739
+ }
740
+ } }).prompt();
741
+ Y3 = (r3) => new mD2({ validate: r3.validate, mask: r3.mask ?? q4, render() {
742
+ const n2 = `${import_picocolors2.default.gray(a2)}
743
+ ${h2(this.state)} ${r3.message}
744
+ `, s2 = this.valueWithCursor, t2 = this.masked;
745
+ switch (this.state) {
746
+ case "error":
747
+ return `${n2.trim()}
748
+ ${import_picocolors2.default.yellow(a2)} ${t2}
749
+ ${import_picocolors2.default.yellow(o)} ${import_picocolors2.default.yellow(this.error)}
750
+ `;
751
+ case "submit":
752
+ return `${n2}${import_picocolors2.default.gray(a2)} ${import_picocolors2.default.dim(t2)}`;
753
+ case "cancel":
754
+ return `${n2}${import_picocolors2.default.gray(a2)} ${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(t2 ?? ""))}${t2 ? `
755
+ ` + import_picocolors2.default.gray(a2) : ""}`;
756
+ default:
757
+ return `${n2}${import_picocolors2.default.cyan(a2)} ${s2}
758
+ ${import_picocolors2.default.cyan(o)}
759
+ `;
760
+ }
761
+ } }).prompt();
762
+ Q3 = (r3) => {
763
+ const n2 = r3.active ?? "Yes", s2 = r3.inactive ?? "No";
764
+ return new xD2({ active: n2, inactive: s2, initialValue: r3.initialValue ?? true, render() {
765
+ const t2 = `${import_picocolors2.default.gray(a2)}
766
+ ${h2(this.state)} ${r3.message}
767
+ `, i3 = this.value ? n2 : s2;
768
+ switch (this.state) {
769
+ case "submit":
770
+ return `${t2}${import_picocolors2.default.gray(a2)} ${import_picocolors2.default.dim(i3)}`;
771
+ case "cancel":
772
+ return `${t2}${import_picocolors2.default.gray(a2)} ${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(i3))}
773
+ ${import_picocolors2.default.gray(a2)}`;
774
+ default:
775
+ return `${t2}${import_picocolors2.default.cyan(a2)} ${this.value ? `${import_picocolors2.default.green(w5)} ${n2}` : `${import_picocolors2.default.dim(S4)} ${import_picocolors2.default.dim(n2)}`} ${import_picocolors2.default.dim("/")} ${this.value ? `${import_picocolors2.default.dim(S4)} ${import_picocolors2.default.dim(s2)}` : `${import_picocolors2.default.green(w5)} ${s2}`}
776
+ ${import_picocolors2.default.cyan(o)}
777
+ `;
778
+ }
779
+ } }).prompt();
780
+ };
781
+ ee = (r3) => {
782
+ const n2 = (s2, t2) => {
783
+ const i3 = s2.label ?? String(s2.value);
784
+ return t2 === "active" ? `${import_picocolors2.default.green(w5)} ${i3} ${s2.hint ? import_picocolors2.default.dim(`(${s2.hint})`) : ""}` : t2 === "selected" ? `${import_picocolors2.default.dim(i3)}` : t2 === "cancelled" ? `${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(i3))}` : `${import_picocolors2.default.dim(S4)} ${import_picocolors2.default.dim(i3)}`;
785
+ };
786
+ return new yD({ options: r3.options, initialValue: r3.initialValue, render() {
787
+ const s2 = `${import_picocolors2.default.gray(a2)}
788
+ ${h2(this.state)} ${r3.message}
789
+ `;
790
+ switch (this.state) {
791
+ case "submit":
792
+ return `${s2}${import_picocolors2.default.gray(a2)} ${n2(this.options[this.cursor], "selected")}`;
793
+ case "cancel":
794
+ return `${s2}${import_picocolors2.default.gray(a2)} ${n2(this.options[this.cursor], "cancelled")}
795
+ ${import_picocolors2.default.gray(a2)}`;
796
+ default:
797
+ return `${s2}${import_picocolors2.default.cyan(a2)} ${this.options.map((t2, i3) => n2(t2, i3 === this.cursor ? "active" : "inactive")).join(`
798
+ ${import_picocolors2.default.cyan(a2)} `)}
799
+ ${import_picocolors2.default.cyan(o)}
800
+ `;
801
+ }
802
+ } }).prompt();
803
+ };
804
+ te = (r3) => {
805
+ const n2 = (s2, t2 = "inactive") => {
806
+ const i3 = s2.label ?? String(s2.value);
807
+ return t2 === "selected" ? `${import_picocolors2.default.dim(i3)}` : t2 === "cancelled" ? `${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(i3))}` : t2 === "active" ? `${import_picocolors2.default.bgCyan(import_picocolors2.default.gray(` ${s2.value} `))} ${i3} ${s2.hint ? import_picocolors2.default.dim(`(${s2.hint})`) : ""}` : `${import_picocolors2.default.gray(import_picocolors2.default.bgWhite(import_picocolors2.default.inverse(` ${s2.value} `)))} ${i3} ${s2.hint ? import_picocolors2.default.dim(`(${s2.hint})`) : ""}`;
808
+ };
809
+ return new _D({ options: r3.options, initialValue: r3.initialValue, render() {
810
+ const s2 = `${import_picocolors2.default.gray(a2)}
811
+ ${h2(this.state)} ${r3.message}
812
+ `;
813
+ switch (this.state) {
814
+ case "submit":
815
+ return `${s2}${import_picocolors2.default.gray(a2)} ${n2(this.options.find((t2) => t2.value === this.value), "selected")}`;
816
+ case "cancel":
817
+ return `${s2}${import_picocolors2.default.gray(a2)} ${n2(this.options[0], "cancelled")}
818
+ ${import_picocolors2.default.gray(a2)}`;
819
+ default:
820
+ return `${s2}${import_picocolors2.default.cyan(a2)} ${this.options.map((t2, i3) => n2(t2, i3 === this.cursor ? "active" : "inactive")).join(`
821
+ ${import_picocolors2.default.cyan(a2)} `)}
822
+ ${import_picocolors2.default.cyan(o)}
823
+ `;
824
+ }
825
+ } }).prompt();
826
+ };
827
+ re = (r3) => {
828
+ const n2 = (s2, t2) => {
829
+ const i3 = s2.label ?? String(s2.value);
830
+ return t2 === "active" ? `${import_picocolors2.default.cyan(_5)} ${i3} ${s2.hint ? import_picocolors2.default.dim(`(${s2.hint})`) : ""}` : t2 === "selected" ? `${import_picocolors2.default.green(y4)} ${import_picocolors2.default.dim(i3)}` : t2 === "cancelled" ? `${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(i3))}` : t2 === "active-selected" ? `${import_picocolors2.default.green(y4)} ${i3} ${s2.hint ? import_picocolors2.default.dim(`(${s2.hint})`) : ""}` : t2 === "submitted" ? `${import_picocolors2.default.dim(i3)}` : `${import_picocolors2.default.dim(A3)} ${import_picocolors2.default.dim(i3)}`;
831
+ };
832
+ return new gD2({ options: r3.options, initialValues: r3.initialValues, required: r3.required ?? true, cursorAt: r3.cursorAt, validate(s2) {
833
+ if (this.required && s2.length === 0) return `Please select at least one option.
834
+ ${import_picocolors2.default.reset(import_picocolors2.default.dim(`Press ${import_picocolors2.default.gray(import_picocolors2.default.bgWhite(import_picocolors2.default.inverse(" space ")))} to select, ${import_picocolors2.default.gray(import_picocolors2.default.bgWhite(import_picocolors2.default.inverse(" enter ")))} to submit`))}`;
835
+ }, render() {
836
+ let s2 = `${import_picocolors2.default.gray(a2)}
837
+ ${h2(this.state)} ${r3.message}
838
+ `;
839
+ switch (this.state) {
840
+ case "submit":
841
+ return `${s2}${import_picocolors2.default.gray(a2)} ${this.options.filter(({ value: t2 }) => this.value.includes(t2)).map((t2) => n2(t2, "submitted")).join(import_picocolors2.default.dim(", ")) || import_picocolors2.default.dim("none")}`;
842
+ case "cancel": {
843
+ const t2 = this.options.filter(({ value: i3 }) => this.value.includes(i3)).map((i3) => n2(i3, "cancelled")).join(import_picocolors2.default.dim(", "));
844
+ return `${s2}${import_picocolors2.default.gray(a2)} ${t2.trim() ? `${t2}
845
+ ${import_picocolors2.default.gray(a2)}` : ""}`;
846
+ }
847
+ case "error": {
848
+ const t2 = this.error.split(`
849
+ `).map((i3, c4) => c4 === 0 ? `${import_picocolors2.default.yellow(o)} ${import_picocolors2.default.yellow(i3)}` : ` ${i3}`).join(`
850
+ `);
851
+ return s2 + import_picocolors2.default.yellow(a2) + " " + this.options.map((i3, c4) => {
852
+ const l3 = this.value.includes(i3.value), $6 = c4 === this.cursor;
853
+ return $6 && l3 ? n2(i3, "active-selected") : l3 ? n2(i3, "selected") : n2(i3, $6 ? "active" : "inactive");
854
+ }).join(`
855
+ ${import_picocolors2.default.yellow(a2)} `) + `
856
+ ` + t2 + `
857
+ `;
858
+ }
859
+ default:
860
+ return `${s2}${import_picocolors2.default.cyan(a2)} ${this.options.map((t2, i3) => {
861
+ const c4 = this.value.includes(t2.value), l3 = i3 === this.cursor;
862
+ return l3 && c4 ? n2(t2, "active-selected") : c4 ? n2(t2, "selected") : n2(t2, l3 ? "active" : "inactive");
863
+ }).join(`
864
+ ${import_picocolors2.default.cyan(a2)} `)}
865
+ ${import_picocolors2.default.cyan(o)}
866
+ `;
867
+ }
868
+ } }).prompt();
869
+ };
870
+ se = (r3) => {
871
+ const n2 = (s2, t2, i3 = []) => {
872
+ const c4 = s2.label ?? String(s2.value), l3 = typeof s2.group == "string", $6 = l3 && (i3[i3.indexOf(s2) + 1] ?? { group: true }), v5 = l3 && $6.group === true, m5 = l3 ? `${v5 ? o : a2} ` : "";
873
+ return t2 === "active" ? `${import_picocolors2.default.dim(m5)}${import_picocolors2.default.cyan(_5)} ${c4} ${s2.hint ? import_picocolors2.default.dim(`(${s2.hint})`) : ""}` : t2 === "group-active" ? `${m5}${import_picocolors2.default.cyan(_5)} ${import_picocolors2.default.dim(c4)}` : t2 === "group-active-selected" ? `${m5}${import_picocolors2.default.green(y4)} ${import_picocolors2.default.dim(c4)}` : t2 === "selected" ? `${import_picocolors2.default.dim(m5)}${import_picocolors2.default.green(y4)} ${import_picocolors2.default.dim(c4)}` : t2 === "cancelled" ? `${import_picocolors2.default.strikethrough(import_picocolors2.default.dim(c4))}` : t2 === "active-selected" ? `${import_picocolors2.default.dim(m5)}${import_picocolors2.default.green(y4)} ${c4} ${s2.hint ? import_picocolors2.default.dim(`(${s2.hint})`) : ""}` : t2 === "submitted" ? `${import_picocolors2.default.dim(c4)}` : `${import_picocolors2.default.dim(m5)}${import_picocolors2.default.dim(A3)} ${import_picocolors2.default.dim(c4)}`;
874
+ };
875
+ return new AD2({ options: r3.options, initialValues: r3.initialValues, required: r3.required ?? true, cursorAt: r3.cursorAt, validate(s2) {
876
+ if (this.required && s2.length === 0) return `Please select at least one option.
877
+ ${import_picocolors2.default.reset(import_picocolors2.default.dim(`Press ${import_picocolors2.default.gray(import_picocolors2.default.bgWhite(import_picocolors2.default.inverse(" space ")))} to select, ${import_picocolors2.default.gray(import_picocolors2.default.bgWhite(import_picocolors2.default.inverse(" enter ")))} to submit`))}`;
878
+ }, render() {
879
+ let s2 = `${import_picocolors2.default.gray(a2)}
880
+ ${h2(this.state)} ${r3.message}
881
+ `;
882
+ switch (this.state) {
883
+ case "submit":
884
+ return `${s2}${import_picocolors2.default.gray(a2)} ${this.options.filter(({ value: t2 }) => this.value.includes(t2)).map((t2) => n2(t2, "submitted")).join(import_picocolors2.default.dim(", "))}`;
885
+ case "cancel": {
886
+ const t2 = this.options.filter(({ value: i3 }) => this.value.includes(i3)).map((i3) => n2(i3, "cancelled")).join(import_picocolors2.default.dim(", "));
887
+ return `${s2}${import_picocolors2.default.gray(a2)} ${t2.trim() ? `${t2}
888
+ ${import_picocolors2.default.gray(a2)}` : ""}`;
889
+ }
890
+ case "error": {
891
+ const t2 = this.error.split(`
892
+ `).map((i3, c4) => c4 === 0 ? `${import_picocolors2.default.yellow(o)} ${import_picocolors2.default.yellow(i3)}` : ` ${i3}`).join(`
893
+ `);
894
+ return `${s2}${import_picocolors2.default.yellow(a2)} ${this.options.map((i3, c4, l3) => {
895
+ const $6 = this.value.includes(i3.value) || i3.group === true && this.isGroupSelected(`${i3.value}`), v5 = c4 === this.cursor;
896
+ return !v5 && typeof i3.group == "string" && this.options[this.cursor].value === i3.group ? n2(i3, $6 ? "group-active-selected" : "group-active", l3) : v5 && $6 ? n2(i3, "active-selected", l3) : $6 ? n2(i3, "selected", l3) : n2(i3, v5 ? "active" : "inactive", l3);
897
+ }).join(`
898
+ ${import_picocolors2.default.yellow(a2)} `)}
899
+ ${t2}
900
+ `;
901
+ }
902
+ default:
903
+ return `${s2}${import_picocolors2.default.cyan(a2)} ${this.options.map((t2, i3, c4) => {
904
+ const l3 = this.value.includes(t2.value) || t2.group === true && this.isGroupSelected(`${t2.value}`), $6 = i3 === this.cursor;
905
+ return !$6 && typeof t2.group == "string" && this.options[this.cursor].value === t2.group ? n2(t2, l3 ? "group-active-selected" : "group-active", c4) : $6 && l3 ? n2(t2, "active-selected", c4) : l3 ? n2(t2, "selected", c4) : n2(t2, $6 ? "active" : "inactive", c4);
906
+ }).join(`
907
+ ${import_picocolors2.default.cyan(a2)} `)}
908
+ ${import_picocolors2.default.cyan(o)}
909
+ `;
910
+ }
911
+ } }).prompt();
912
+ };
913
+ b5 = (r3) => r3.replace(ue(), "");
914
+ ie = (r3 = "", n2 = "") => {
915
+ const s2 = `
916
+ ${r3}
917
+ `.split(`
918
+ `), t2 = Math.max(s2.reduce((c4, l3) => (l3 = b5(l3), l3.length > c4 ? l3.length : c4), 0), b5(n2).length) + 2, i3 = s2.map((c4) => `${import_picocolors2.default.gray(a2)} ${import_picocolors2.default.dim(c4)}${" ".repeat(t2 - b5(c4).length)}${import_picocolors2.default.gray(a2)}`).join(`
919
+ `);
920
+ process.stdout.write(`${import_picocolors2.default.gray(a2)}
921
+ ${import_picocolors2.default.green(f2)} ${import_picocolors2.default.reset(n2)} ${import_picocolors2.default.gray(R5.repeat(Math.max(t2 - n2.length - 1, 1)) + G5)}
922
+ ${i3}
923
+ ${import_picocolors2.default.gray(H4 + R5.repeat(t2 + 2) + K4)}
924
+ `);
925
+ };
926
+ ne = (r3 = "") => {
927
+ process.stdout.write(`${import_picocolors2.default.gray(o)} ${import_picocolors2.default.red(r3)}
928
+
929
+ `);
930
+ };
931
+ ae = (r3 = "") => {
932
+ process.stdout.write(`${import_picocolors2.default.gray(L5)} ${r3}
933
+ `);
934
+ };
935
+ ce = (r3 = "") => {
936
+ process.stdout.write(`${import_picocolors2.default.gray(a2)}
937
+ ${import_picocolors2.default.gray(o)} ${r3}
938
+
939
+ `);
940
+ };
941
+ g3 = { message: (r3 = "", { symbol: n2 = import_picocolors2.default.gray(a2) } = {}) => {
942
+ const s2 = [`${import_picocolors2.default.gray(a2)}`];
943
+ if (r3) {
944
+ const [t2, ...i3] = r3.split(`
945
+ `);
946
+ s2.push(`${n2} ${t2}`, ...i3.map((c4) => `${import_picocolors2.default.gray(a2)} ${c4}`));
947
+ }
948
+ process.stdout.write(`${s2.join(`
949
+ `)}
950
+ `);
951
+ }, info: (r3) => {
952
+ g3.message(r3, { symbol: import_picocolors2.default.blue(U5) });
953
+ }, success: (r3) => {
954
+ g3.message(r3, { symbol: import_picocolors2.default.green(Z4) });
955
+ }, step: (r3) => {
956
+ g3.message(r3, { symbol: import_picocolors2.default.green(f2) });
957
+ }, warn: (r3) => {
958
+ g3.message(r3, { symbol: import_picocolors2.default.yellow(z4) });
959
+ }, warning: (r3) => {
960
+ g3.warn(r3);
961
+ }, error: (r3) => {
962
+ g3.message(r3, { symbol: import_picocolors2.default.red(X3) });
963
+ } };
964
+ C3 = p2 ? ["\u25D2", "\u25D0", "\u25D3", "\u25D1"] : ["\u2022", "o", "O", "0"];
965
+ le = () => {
966
+ let r3, n2;
967
+ const s2 = p2 ? 80 : 120;
968
+ return { start(t2 = "") {
969
+ t2 = t2.replace(/\.?\.?\.$/, ""), r3 = WD(), process.stdout.write(`${import_picocolors2.default.gray(a2)}
970
+ ${import_picocolors2.default.magenta("\u25CB")} ${t2}
971
+ `);
972
+ let i3 = 0, c4 = 0;
973
+ n2 = setInterval(() => {
974
+ let l3 = C3[i3];
975
+ process.stdout.write(import_sisteransi2.cursor.move(-999, -1)), process.stdout.write(`${import_picocolors2.default.magenta(l3)} ${t2}${Math.floor(c4) >= 1 ? ".".repeat(Math.floor(c4)).slice(0, 3) : ""}
976
+ `), i3 = i3 === C3.length - 1 ? 0 : i3 + 1, c4 = c4 === C3.length ? 0 : c4 + 0.125;
977
+ }, s2);
978
+ }, stop(t2 = "") {
979
+ process.stdout.write(import_sisteransi2.cursor.move(-999, -2)), process.stdout.write(import_sisteransi2.erase.down(2)), clearInterval(n2), process.stdout.write(`${import_picocolors2.default.gray(a2)}
980
+ ${import_picocolors2.default.green(f2)} ${t2}
981
+ `), r3();
982
+ } };
983
+ };
984
+ $e = async (r3, n2) => {
985
+ const s2 = {}, t2 = Object.keys(r3);
986
+ for (const i3 of t2) {
987
+ const c4 = r3[i3], l3 = await c4({ results: s2 })?.catch(($6) => {
988
+ throw $6;
989
+ });
990
+ if (typeof n2?.onCancel == "function" && hD2(l3)) {
991
+ s2[i3] = "canceled", n2.onCancel({ results: s2 });
992
+ continue;
993
+ }
994
+ s2[i3] = l3;
995
+ }
996
+ return s2;
997
+ };
998
+ }
999
+ });
1000
+
164
1001
  // node_modules/isexe/windows.js
165
1002
  var require_windows = __commonJS({
166
1003
  "node_modules/isexe/windows.js"(exports2, module2) {
@@ -225,10 +1062,10 @@ var require_mode = __commonJS({
225
1062
  var myUid = options.uid !== void 0 ? options.uid : process.getuid && process.getuid();
226
1063
  var myGid = options.gid !== void 0 ? options.gid : process.getgid && process.getgid();
227
1064
  var u3 = parseInt("100", 8);
228
- var g4 = parseInt("010", 8);
1065
+ var g5 = parseInt("010", 8);
229
1066
  var o3 = parseInt("001", 8);
230
- var ug = u3 | g4;
231
- var ret = mod & o3 || mod & g4 && gid === myGid || mod & u3 && uid === myUid || mod & ug && myUid === 0;
1067
+ var ug = u3 | g5;
1068
+ var ret = mod & o3 || mod & g5 && gid === myGid || mod & u3 && uid === myUid || mod & ug && myUid === 0;
232
1069
  return ret;
233
1070
  }
234
1071
  }
@@ -1477,20 +2314,20 @@ var require_ini = __commonJS({
1477
2314
  let esc = false;
1478
2315
  let unesc = "";
1479
2316
  for (let i3 = 0, l3 = val.length; i3 < l3; i3++) {
1480
- const c3 = val.charAt(i3);
2317
+ const c4 = val.charAt(i3);
1481
2318
  if (esc) {
1482
- if ("\\;#".indexOf(c3) !== -1) {
1483
- unesc += c3;
2319
+ if ("\\;#".indexOf(c4) !== -1) {
2320
+ unesc += c4;
1484
2321
  } else {
1485
- unesc += "\\" + c3;
2322
+ unesc += "\\" + c4;
1486
2323
  }
1487
2324
  esc = false;
1488
- } else if (";#".indexOf(c3) !== -1) {
2325
+ } else if (";#".indexOf(c4) !== -1) {
1489
2326
  break;
1490
- } else if (c3 === "\\") {
2327
+ } else if (c4 === "\\") {
1491
2328
  esc = true;
1492
2329
  } else {
1493
- unesc += c3;
2330
+ unesc += c4;
1494
2331
  }
1495
2332
  }
1496
2333
  if (esc) {
@@ -1697,9 +2534,9 @@ var require_lib = __commonJS({
1697
2534
  };
1698
2535
  exports2.ByteString = (value, options = {}) => {
1699
2536
  const x5 = exports2.DOMString(value, options);
1700
- let c3;
1701
- for (let i3 = 0; (c3 = x5.codePointAt(i3)) !== void 0; ++i3) {
1702
- if (c3 > 255) {
2537
+ let c4;
2538
+ for (let i3 = 0; (c4 = x5.codePointAt(i3)) !== void 0; ++i3) {
2539
+ if (c4 > 255) {
1703
2540
  throw makeException(TypeError, "is not a valid ByteString", options);
1704
2541
  }
1705
2542
  }
@@ -1710,17 +2547,17 @@ var require_lib = __commonJS({
1710
2547
  const n2 = S6.length;
1711
2548
  const U7 = [];
1712
2549
  for (let i3 = 0; i3 < n2; ++i3) {
1713
- const c3 = S6.charCodeAt(i3);
1714
- if (c3 < 55296 || c3 > 57343) {
1715
- U7.push(String.fromCodePoint(c3));
1716
- } else if (56320 <= c3 && c3 <= 57343) {
2550
+ const c4 = S6.charCodeAt(i3);
2551
+ if (c4 < 55296 || c4 > 57343) {
2552
+ U7.push(String.fromCodePoint(c4));
2553
+ } else if (56320 <= c4 && c4 <= 57343) {
1717
2554
  U7.push(String.fromCodePoint(65533));
1718
2555
  } else if (i3 === n2 - 1) {
1719
2556
  U7.push(String.fromCodePoint(65533));
1720
2557
  } else {
1721
2558
  const d7 = S6.charCodeAt(i3 + 1);
1722
2559
  if (56320 <= d7 && d7 <= 57343) {
1723
- const a4 = c3 & 1023;
2560
+ const a4 = c4 & 1023;
1724
2561
  const b7 = d7 & 1023;
1725
2562
  U7.push(String.fromCodePoint((2 << 15) + (2 << 9) * a4 + b7));
1726
2563
  ++i3;
@@ -2597,17 +3434,17 @@ var require_tr46 = __commonJS({
2597
3434
  var require_infra = __commonJS({
2598
3435
  "node_modules/whatwg-url/lib/infra.js"(exports2, module2) {
2599
3436
  "use strict";
2600
- function isASCIIDigit(c3) {
2601
- return c3 >= 48 && c3 <= 57;
3437
+ function isASCIIDigit(c4) {
3438
+ return c4 >= 48 && c4 <= 57;
2602
3439
  }
2603
- function isASCIIAlpha(c3) {
2604
- return c3 >= 65 && c3 <= 90 || c3 >= 97 && c3 <= 122;
3440
+ function isASCIIAlpha(c4) {
3441
+ return c4 >= 65 && c4 <= 90 || c4 >= 97 && c4 <= 122;
2605
3442
  }
2606
- function isASCIIAlphanumeric(c3) {
2607
- return isASCIIAlpha(c3) || isASCIIDigit(c3);
3443
+ function isASCIIAlphanumeric(c4) {
3444
+ return isASCIIAlpha(c4) || isASCIIDigit(c4);
2608
3445
  }
2609
- function isASCIIHex(c3) {
2610
- return isASCIIDigit(c3) || c3 >= 65 && c3 <= 70 || c3 >= 97 && c3 <= 102;
3446
+ function isASCIIHex(c4) {
3447
+ return isASCIIDigit(c4) || c4 >= 65 && c4 <= 70 || c4 >= 97 && c4 <= 102;
2611
3448
  }
2612
3449
  module2.exports = {
2613
3450
  isASCIIDigit,
@@ -2646,8 +3483,8 @@ var require_percent_encoding = __commonJS({
2646
3483
  function p4(char) {
2647
3484
  return char.codePointAt(0);
2648
3485
  }
2649
- function percentEncode(c3) {
2650
- let hex = c3.toString(16).toUpperCase();
3486
+ function percentEncode(c4) {
3487
+ let hex = c4.toString(16).toUpperCase();
2651
3488
  if (hex.length === 1) {
2652
3489
  hex = `0${hex}`;
2653
3490
  }
@@ -2674,35 +3511,35 @@ var require_percent_encoding = __commonJS({
2674
3511
  const bytes = utf8Encode(input);
2675
3512
  return percentDecodeBytes(bytes);
2676
3513
  }
2677
- function isC0ControlPercentEncode(c3) {
2678
- return c3 <= 31 || c3 > 126;
3514
+ function isC0ControlPercentEncode(c4) {
3515
+ return c4 <= 31 || c4 > 126;
2679
3516
  }
2680
3517
  var extraFragmentPercentEncodeSet = /* @__PURE__ */ new Set([p4(" "), p4('"'), p4("<"), p4(">"), p4("`")]);
2681
- function isFragmentPercentEncode(c3) {
2682
- return isC0ControlPercentEncode(c3) || extraFragmentPercentEncodeSet.has(c3);
3518
+ function isFragmentPercentEncode(c4) {
3519
+ return isC0ControlPercentEncode(c4) || extraFragmentPercentEncodeSet.has(c4);
2683
3520
  }
2684
3521
  var extraQueryPercentEncodeSet = /* @__PURE__ */ new Set([p4(" "), p4('"'), p4("#"), p4("<"), p4(">")]);
2685
- function isQueryPercentEncode(c3) {
2686
- return isC0ControlPercentEncode(c3) || extraQueryPercentEncodeSet.has(c3);
3522
+ function isQueryPercentEncode(c4) {
3523
+ return isC0ControlPercentEncode(c4) || extraQueryPercentEncodeSet.has(c4);
2687
3524
  }
2688
- function isSpecialQueryPercentEncode(c3) {
2689
- return isQueryPercentEncode(c3) || c3 === p4("'");
3525
+ function isSpecialQueryPercentEncode(c4) {
3526
+ return isQueryPercentEncode(c4) || c4 === p4("'");
2690
3527
  }
2691
3528
  var extraPathPercentEncodeSet = /* @__PURE__ */ new Set([p4("?"), p4("`"), p4("{"), p4("}"), p4("^")]);
2692
- function isPathPercentEncode(c3) {
2693
- return isQueryPercentEncode(c3) || extraPathPercentEncodeSet.has(c3);
3529
+ function isPathPercentEncode(c4) {
3530
+ return isQueryPercentEncode(c4) || extraPathPercentEncodeSet.has(c4);
2694
3531
  }
2695
3532
  var extraUserinfoPercentEncodeSet = /* @__PURE__ */ new Set([p4("/"), p4(":"), p4(";"), p4("="), p4("@"), p4("["), p4("\\"), p4("]"), p4("|")]);
2696
- function isUserinfoPercentEncode(c3) {
2697
- return isPathPercentEncode(c3) || extraUserinfoPercentEncodeSet.has(c3);
3533
+ function isUserinfoPercentEncode(c4) {
3534
+ return isPathPercentEncode(c4) || extraUserinfoPercentEncodeSet.has(c4);
2698
3535
  }
2699
3536
  var extraComponentPercentEncodeSet = /* @__PURE__ */ new Set([p4("$"), p4("%"), p4("&"), p4("+"), p4(",")]);
2700
- function isComponentPercentEncode(c3) {
2701
- return isUserinfoPercentEncode(c3) || extraComponentPercentEncodeSet.has(c3);
3537
+ function isComponentPercentEncode(c4) {
3538
+ return isUserinfoPercentEncode(c4) || extraComponentPercentEncodeSet.has(c4);
2702
3539
  }
2703
3540
  var extraURLEncodedPercentEncodeSet = /* @__PURE__ */ new Set([p4("!"), p4("'"), p4("("), p4(")"), p4("~")]);
2704
- function isURLEncodedPercentEncode(c3) {
2705
- return isComponentPercentEncode(c3) || extraURLEncodedPercentEncodeSet.has(c3);
3541
+ function isURLEncodedPercentEncode(c4) {
3542
+ return isComponentPercentEncode(c4) || extraURLEncodedPercentEncodeSet.has(c4);
2706
3543
  }
2707
3544
  function utf8PercentEncodeCodePointInternal(codePoint, percentEncodePredicate) {
2708
3545
  const bytes = utf8Encode(codePoint);
@@ -2780,8 +3617,8 @@ var require_url_state_machine = __commonJS({
2780
3617
  return [...str2].length;
2781
3618
  }
2782
3619
  function at2(input, idx) {
2783
- const c3 = input[idx];
2784
- return isNaN(c3) ? void 0 : String.fromCodePoint(c3);
3620
+ const c4 = input[idx];
3621
+ return isNaN(c4) ? void 0 : String.fromCodePoint(c4);
2785
3622
  }
2786
3623
  function isSingleDot(buffer) {
2787
3624
  return buffer === "." || buffer.toLowerCase() === "%2e";
@@ -2895,7 +3732,7 @@ var require_url_state_machine = __commonJS({
2895
3732
  let pieceIndex = 0;
2896
3733
  let compress = null;
2897
3734
  let pointer = 0;
2898
- input = Array.from(input, (c3) => c3.codePointAt(0));
3735
+ input = Array.from(input, (c4) => c4.codePointAt(0));
2899
3736
  if (input[pointer] === p4(":")) {
2900
3737
  if (input[pointer + 1] !== p4(":")) {
2901
3738
  return failure;
@@ -3194,11 +4031,11 @@ var require_url_state_machine = __commonJS({
3194
4031
  this.atFlag = false;
3195
4032
  this.arrFlag = false;
3196
4033
  this.passwordTokenSeenFlag = false;
3197
- this.input = Array.from(this.input, (c3) => c3.codePointAt(0));
4034
+ this.input = Array.from(this.input, (c4) => c4.codePointAt(0));
3198
4035
  for (; this.pointer <= this.input.length; ++this.pointer) {
3199
- const c3 = this.input[this.pointer];
3200
- const cStr = isNaN(c3) ? void 0 : String.fromCodePoint(c3);
3201
- const ret = this[`parse ${this.state}`](c3, cStr);
4036
+ const c4 = this.input[this.pointer];
4037
+ const cStr = isNaN(c4) ? void 0 : String.fromCodePoint(c4);
4038
+ const ret = this[`parse ${this.state}`](c4, cStr);
3202
4039
  if (!ret) {
3203
4040
  break;
3204
4041
  } else if (ret === failure) {
@@ -3207,8 +4044,8 @@ var require_url_state_machine = __commonJS({
3207
4044
  }
3208
4045
  }
3209
4046
  }
3210
- URLStateMachine.prototype["parse scheme start"] = function parseSchemeStart(c3, cStr) {
3211
- if (infra.isASCIIAlpha(c3)) {
4047
+ URLStateMachine.prototype["parse scheme start"] = function parseSchemeStart(c4, cStr) {
4048
+ if (infra.isASCIIAlpha(c4)) {
3212
4049
  this.buffer += cStr.toLowerCase();
3213
4050
  this.state = "scheme";
3214
4051
  } else if (!this.stateOverride) {
@@ -3220,10 +4057,10 @@ var require_url_state_machine = __commonJS({
3220
4057
  }
3221
4058
  return true;
3222
4059
  };
3223
- URLStateMachine.prototype["parse scheme"] = function parseScheme(c3, cStr) {
3224
- if (infra.isASCIIAlphanumeric(c3) || c3 === p4("+") || c3 === p4("-") || c3 === p4(".")) {
4060
+ URLStateMachine.prototype["parse scheme"] = function parseScheme(c4, cStr) {
4061
+ if (infra.isASCIIAlphanumeric(c4) || c4 === p4("+") || c4 === p4("-") || c4 === p4(".")) {
3225
4062
  this.buffer += cStr.toLowerCase();
3226
- } else if (c3 === p4(":")) {
4063
+ } else if (c4 === p4(":")) {
3227
4064
  if (this.stateOverride) {
3228
4065
  if (isSpecial(this.url) && !isSpecialScheme(this.buffer)) {
3229
4066
  return false;
@@ -3272,10 +4109,10 @@ var require_url_state_machine = __commonJS({
3272
4109
  }
3273
4110
  return true;
3274
4111
  };
3275
- URLStateMachine.prototype["parse no scheme"] = function parseNoScheme(c3) {
3276
- if (this.base === null || hasAnOpaquePath(this.base) && c3 !== p4("#")) {
4112
+ URLStateMachine.prototype["parse no scheme"] = function parseNoScheme(c4) {
4113
+ if (this.base === null || hasAnOpaquePath(this.base) && c4 !== p4("#")) {
3277
4114
  return failure;
3278
- } else if (hasAnOpaquePath(this.base) && c3 === p4("#")) {
4115
+ } else if (hasAnOpaquePath(this.base) && c4 === p4("#")) {
3279
4116
  this.url.scheme = this.base.scheme;
3280
4117
  this.url.path = this.base.path;
3281
4118
  this.url.query = this.base.query;
@@ -3290,8 +4127,8 @@ var require_url_state_machine = __commonJS({
3290
4127
  }
3291
4128
  return true;
3292
4129
  };
3293
- URLStateMachine.prototype["parse special relative or authority"] = function parseSpecialRelativeOrAuthority(c3) {
3294
- if (c3 === p4("/") && this.input[this.pointer + 1] === p4("/")) {
4130
+ URLStateMachine.prototype["parse special relative or authority"] = function parseSpecialRelativeOrAuthority(c4) {
4131
+ if (c4 === p4("/") && this.input[this.pointer + 1] === p4("/")) {
3295
4132
  this.state = "special authority ignore slashes";
3296
4133
  ++this.pointer;
3297
4134
  } else {
@@ -3301,8 +4138,8 @@ var require_url_state_machine = __commonJS({
3301
4138
  }
3302
4139
  return true;
3303
4140
  };
3304
- URLStateMachine.prototype["parse path or authority"] = function parsePathOrAuthority(c3) {
3305
- if (c3 === p4("/")) {
4141
+ URLStateMachine.prototype["parse path or authority"] = function parsePathOrAuthority(c4) {
4142
+ if (c4 === p4("/")) {
3306
4143
  this.state = "authority";
3307
4144
  } else {
3308
4145
  this.state = "path";
@@ -3310,11 +4147,11 @@ var require_url_state_machine = __commonJS({
3310
4147
  }
3311
4148
  return true;
3312
4149
  };
3313
- URLStateMachine.prototype["parse relative"] = function parseRelative(c3) {
4150
+ URLStateMachine.prototype["parse relative"] = function parseRelative(c4) {
3314
4151
  this.url.scheme = this.base.scheme;
3315
- if (c3 === p4("/")) {
4152
+ if (c4 === p4("/")) {
3316
4153
  this.state = "relative slash";
3317
- } else if (isSpecial(this.url) && c3 === p4("\\")) {
4154
+ } else if (isSpecial(this.url) && c4 === p4("\\")) {
3318
4155
  this.parseError = true;
3319
4156
  this.state = "relative slash";
3320
4157
  } else {
@@ -3324,13 +4161,13 @@ var require_url_state_machine = __commonJS({
3324
4161
  this.url.port = this.base.port;
3325
4162
  this.url.path = this.base.path.slice();
3326
4163
  this.url.query = this.base.query;
3327
- if (c3 === p4("?")) {
4164
+ if (c4 === p4("?")) {
3328
4165
  this.url.query = "";
3329
4166
  this.state = "query";
3330
- } else if (c3 === p4("#")) {
4167
+ } else if (c4 === p4("#")) {
3331
4168
  this.url.fragment = "";
3332
4169
  this.state = "fragment";
3333
- } else if (!isNaN(c3)) {
4170
+ } else if (!isNaN(c4)) {
3334
4171
  this.url.query = null;
3335
4172
  this.url.path.pop();
3336
4173
  this.state = "path";
@@ -3339,13 +4176,13 @@ var require_url_state_machine = __commonJS({
3339
4176
  }
3340
4177
  return true;
3341
4178
  };
3342
- URLStateMachine.prototype["parse relative slash"] = function parseRelativeSlash(c3) {
3343
- if (isSpecial(this.url) && (c3 === p4("/") || c3 === p4("\\"))) {
3344
- if (c3 === p4("\\")) {
4179
+ URLStateMachine.prototype["parse relative slash"] = function parseRelativeSlash(c4) {
4180
+ if (isSpecial(this.url) && (c4 === p4("/") || c4 === p4("\\"))) {
4181
+ if (c4 === p4("\\")) {
3345
4182
  this.parseError = true;
3346
4183
  }
3347
4184
  this.state = "special authority ignore slashes";
3348
- } else if (c3 === p4("/")) {
4185
+ } else if (c4 === p4("/")) {
3349
4186
  this.state = "authority";
3350
4187
  } else {
3351
4188
  this.url.username = this.base.username;
@@ -3357,8 +4194,8 @@ var require_url_state_machine = __commonJS({
3357
4194
  }
3358
4195
  return true;
3359
4196
  };
3360
- URLStateMachine.prototype["parse special authority slashes"] = function parseSpecialAuthoritySlashes(c3) {
3361
- if (c3 === p4("/") && this.input[this.pointer + 1] === p4("/")) {
4197
+ URLStateMachine.prototype["parse special authority slashes"] = function parseSpecialAuthoritySlashes(c4) {
4198
+ if (c4 === p4("/") && this.input[this.pointer + 1] === p4("/")) {
3362
4199
  this.state = "special authority ignore slashes";
3363
4200
  ++this.pointer;
3364
4201
  } else {
@@ -3368,8 +4205,8 @@ var require_url_state_machine = __commonJS({
3368
4205
  }
3369
4206
  return true;
3370
4207
  };
3371
- URLStateMachine.prototype["parse special authority ignore slashes"] = function parseSpecialAuthorityIgnoreSlashes(c3) {
3372
- if (c3 !== p4("/") && c3 !== p4("\\")) {
4208
+ URLStateMachine.prototype["parse special authority ignore slashes"] = function parseSpecialAuthorityIgnoreSlashes(c4) {
4209
+ if (c4 !== p4("/") && c4 !== p4("\\")) {
3373
4210
  this.state = "authority";
3374
4211
  --this.pointer;
3375
4212
  } else {
@@ -3377,8 +4214,8 @@ var require_url_state_machine = __commonJS({
3377
4214
  }
3378
4215
  return true;
3379
4216
  };
3380
- URLStateMachine.prototype["parse authority"] = function parseAuthority(c3, cStr) {
3381
- if (c3 === p4("@")) {
4217
+ URLStateMachine.prototype["parse authority"] = function parseAuthority(c4, cStr) {
4218
+ if (c4 === p4("@")) {
3382
4219
  this.parseError = true;
3383
4220
  if (this.atFlag) {
3384
4221
  this.buffer = `%40${this.buffer}`;
@@ -3399,7 +4236,7 @@ var require_url_state_machine = __commonJS({
3399
4236
  }
3400
4237
  }
3401
4238
  this.buffer = "";
3402
- } else if (isNaN(c3) || c3 === p4("/") || c3 === p4("?") || c3 === p4("#") || isSpecial(this.url) && c3 === p4("\\")) {
4239
+ } else if (isNaN(c4) || c4 === p4("/") || c4 === p4("?") || c4 === p4("#") || isSpecial(this.url) && c4 === p4("\\")) {
3403
4240
  if (this.atFlag && this.buffer === "") {
3404
4241
  this.parseError = true;
3405
4242
  return failure;
@@ -3412,11 +4249,11 @@ var require_url_state_machine = __commonJS({
3412
4249
  }
3413
4250
  return true;
3414
4251
  };
3415
- URLStateMachine.prototype["parse hostname"] = URLStateMachine.prototype["parse host"] = function parseHostName(c3, cStr) {
4252
+ URLStateMachine.prototype["parse hostname"] = URLStateMachine.prototype["parse host"] = function parseHostName(c4, cStr) {
3416
4253
  if (this.stateOverride && this.url.scheme === "file") {
3417
4254
  --this.pointer;
3418
4255
  this.state = "file host";
3419
- } else if (c3 === p4(":") && !this.arrFlag) {
4256
+ } else if (c4 === p4(":") && !this.arrFlag) {
3420
4257
  if (this.buffer === "") {
3421
4258
  this.parseError = true;
3422
4259
  return failure;
@@ -3431,7 +4268,7 @@ var require_url_state_machine = __commonJS({
3431
4268
  this.url.host = host;
3432
4269
  this.buffer = "";
3433
4270
  this.state = "port";
3434
- } else if (isNaN(c3) || c3 === p4("/") || c3 === p4("?") || c3 === p4("#") || isSpecial(this.url) && c3 === p4("\\")) {
4271
+ } else if (isNaN(c4) || c4 === p4("/") || c4 === p4("?") || c4 === p4("#") || isSpecial(this.url) && c4 === p4("\\")) {
3435
4272
  --this.pointer;
3436
4273
  if (isSpecial(this.url) && this.buffer === "") {
3437
4274
  this.parseError = true;
@@ -3451,19 +4288,19 @@ var require_url_state_machine = __commonJS({
3451
4288
  return false;
3452
4289
  }
3453
4290
  } else {
3454
- if (c3 === p4("[")) {
4291
+ if (c4 === p4("[")) {
3455
4292
  this.arrFlag = true;
3456
- } else if (c3 === p4("]")) {
4293
+ } else if (c4 === p4("]")) {
3457
4294
  this.arrFlag = false;
3458
4295
  }
3459
4296
  this.buffer += cStr;
3460
4297
  }
3461
4298
  return true;
3462
4299
  };
3463
- URLStateMachine.prototype["parse port"] = function parsePort(c3, cStr) {
3464
- if (infra.isASCIIDigit(c3)) {
4300
+ URLStateMachine.prototype["parse port"] = function parsePort(c4, cStr) {
4301
+ if (infra.isASCIIDigit(c4)) {
3465
4302
  this.buffer += cStr;
3466
- } else if (isNaN(c3) || c3 === p4("/") || c3 === p4("?") || c3 === p4("#") || isSpecial(this.url) && c3 === p4("\\") || this.stateOverride) {
4303
+ } else if (isNaN(c4) || c4 === p4("/") || c4 === p4("?") || c4 === p4("#") || isSpecial(this.url) && c4 === p4("\\") || this.stateOverride) {
3467
4304
  if (this.buffer !== "") {
3468
4305
  const port = parseInt(this.buffer);
3469
4306
  if (port > 2 ** 16 - 1) {
@@ -3489,11 +4326,11 @@ var require_url_state_machine = __commonJS({
3489
4326
  const length = input.length - pointer;
3490
4327
  return length >= 2 && isWindowsDriveLetterCodePoints(input[pointer], input[pointer + 1]) && (length === 2 || fileOtherwiseCodePoints.has(input[pointer + 2]));
3491
4328
  }
3492
- URLStateMachine.prototype["parse file"] = function parseFile(c3) {
4329
+ URLStateMachine.prototype["parse file"] = function parseFile(c4) {
3493
4330
  this.url.scheme = "file";
3494
4331
  this.url.host = "";
3495
- if (c3 === p4("/") || c3 === p4("\\")) {
3496
- if (c3 === p4("\\")) {
4332
+ if (c4 === p4("/") || c4 === p4("\\")) {
4333
+ if (c4 === p4("\\")) {
3497
4334
  this.parseError = true;
3498
4335
  }
3499
4336
  this.state = "file slash";
@@ -3501,13 +4338,13 @@ var require_url_state_machine = __commonJS({
3501
4338
  this.url.host = this.base.host;
3502
4339
  this.url.path = this.base.path.slice();
3503
4340
  this.url.query = this.base.query;
3504
- if (c3 === p4("?")) {
4341
+ if (c4 === p4("?")) {
3505
4342
  this.url.query = "";
3506
4343
  this.state = "query";
3507
- } else if (c3 === p4("#")) {
4344
+ } else if (c4 === p4("#")) {
3508
4345
  this.url.fragment = "";
3509
4346
  this.state = "fragment";
3510
- } else if (!isNaN(c3)) {
4347
+ } else if (!isNaN(c4)) {
3511
4348
  this.url.query = null;
3512
4349
  if (!startsWithWindowsDriveLetter(this.input, this.pointer)) {
3513
4350
  shortenPath(this.url);
@@ -3524,9 +4361,9 @@ var require_url_state_machine = __commonJS({
3524
4361
  }
3525
4362
  return true;
3526
4363
  };
3527
- URLStateMachine.prototype["parse file slash"] = function parseFileSlash(c3) {
3528
- if (c3 === p4("/") || c3 === p4("\\")) {
3529
- if (c3 === p4("\\")) {
4364
+ URLStateMachine.prototype["parse file slash"] = function parseFileSlash(c4) {
4365
+ if (c4 === p4("/") || c4 === p4("\\")) {
4366
+ if (c4 === p4("\\")) {
3530
4367
  this.parseError = true;
3531
4368
  }
3532
4369
  this.state = "file host";
@@ -3542,8 +4379,8 @@ var require_url_state_machine = __commonJS({
3542
4379
  }
3543
4380
  return true;
3544
4381
  };
3545
- URLStateMachine.prototype["parse file host"] = function parseFileHost(c3, cStr) {
3546
- if (isNaN(c3) || c3 === p4("/") || c3 === p4("\\") || c3 === p4("?") || c3 === p4("#")) {
4382
+ URLStateMachine.prototype["parse file host"] = function parseFileHost(c4, cStr) {
4383
+ if (isNaN(c4) || c4 === p4("/") || c4 === p4("\\") || c4 === p4("?") || c4 === p4("#")) {
3547
4384
  --this.pointer;
3548
4385
  if (!this.stateOverride && isWindowsDriveLetterString(this.buffer)) {
3549
4386
  this.parseError = true;
@@ -3574,24 +4411,24 @@ var require_url_state_machine = __commonJS({
3574
4411
  }
3575
4412
  return true;
3576
4413
  };
3577
- URLStateMachine.prototype["parse path start"] = function parsePathStart(c3) {
4414
+ URLStateMachine.prototype["parse path start"] = function parsePathStart(c4) {
3578
4415
  if (isSpecial(this.url)) {
3579
- if (c3 === p4("\\")) {
4416
+ if (c4 === p4("\\")) {
3580
4417
  this.parseError = true;
3581
4418
  }
3582
4419
  this.state = "path";
3583
- if (c3 !== p4("/") && c3 !== p4("\\")) {
4420
+ if (c4 !== p4("/") && c4 !== p4("\\")) {
3584
4421
  --this.pointer;
3585
4422
  }
3586
- } else if (!this.stateOverride && c3 === p4("?")) {
4423
+ } else if (!this.stateOverride && c4 === p4("?")) {
3587
4424
  this.url.query = "";
3588
4425
  this.state = "query";
3589
- } else if (!this.stateOverride && c3 === p4("#")) {
4426
+ } else if (!this.stateOverride && c4 === p4("#")) {
3590
4427
  this.url.fragment = "";
3591
4428
  this.state = "fragment";
3592
- } else if (c3 !== void 0) {
4429
+ } else if (c4 !== void 0) {
3593
4430
  this.state = "path";
3594
- if (c3 !== p4("/")) {
4431
+ if (c4 !== p4("/")) {
3595
4432
  --this.pointer;
3596
4433
  }
3597
4434
  } else if (this.stateOverride && this.url.host === null) {
@@ -3599,17 +4436,17 @@ var require_url_state_machine = __commonJS({
3599
4436
  }
3600
4437
  return true;
3601
4438
  };
3602
- URLStateMachine.prototype["parse path"] = function parsePath(c3) {
3603
- if (isNaN(c3) || c3 === p4("/") || isSpecial(this.url) && c3 === p4("\\") || !this.stateOverride && (c3 === p4("?") || c3 === p4("#"))) {
3604
- if (isSpecial(this.url) && c3 === p4("\\")) {
4439
+ URLStateMachine.prototype["parse path"] = function parsePath(c4) {
4440
+ if (isNaN(c4) || c4 === p4("/") || isSpecial(this.url) && c4 === p4("\\") || !this.stateOverride && (c4 === p4("?") || c4 === p4("#"))) {
4441
+ if (isSpecial(this.url) && c4 === p4("\\")) {
3605
4442
  this.parseError = true;
3606
4443
  }
3607
4444
  if (isDoubleDot(this.buffer)) {
3608
4445
  shortenPath(this.url);
3609
- if (c3 !== p4("/") && !(isSpecial(this.url) && c3 === p4("\\"))) {
4446
+ if (c4 !== p4("/") && !(isSpecial(this.url) && c4 === p4("\\"))) {
3610
4447
  this.url.path.push("");
3611
4448
  }
3612
- } else if (isSingleDot(this.buffer) && c3 !== p4("/") && !(isSpecial(this.url) && c3 === p4("\\"))) {
4449
+ } else if (isSingleDot(this.buffer) && c4 !== p4("/") && !(isSpecial(this.url) && c4 === p4("\\"))) {
3613
4450
  this.url.path.push("");
3614
4451
  } else if (!isSingleDot(this.buffer)) {
3615
4452
  if (this.url.scheme === "file" && this.url.path.length === 0 && isWindowsDriveLetterString(this.buffer)) {
@@ -3618,30 +4455,30 @@ var require_url_state_machine = __commonJS({
3618
4455
  this.url.path.push(this.buffer);
3619
4456
  }
3620
4457
  this.buffer = "";
3621
- if (c3 === p4("?")) {
4458
+ if (c4 === p4("?")) {
3622
4459
  this.url.query = "";
3623
4460
  this.state = "query";
3624
4461
  }
3625
- if (c3 === p4("#")) {
4462
+ if (c4 === p4("#")) {
3626
4463
  this.url.fragment = "";
3627
4464
  this.state = "fragment";
3628
4465
  }
3629
4466
  } else {
3630
- if (c3 === p4("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) {
4467
+ if (c4 === p4("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) {
3631
4468
  this.parseError = true;
3632
4469
  }
3633
- this.buffer += utf8PercentEncodeCodePoint(c3, isPathPercentEncode);
4470
+ this.buffer += utf8PercentEncodeCodePoint(c4, isPathPercentEncode);
3634
4471
  }
3635
4472
  return true;
3636
4473
  };
3637
- URLStateMachine.prototype["parse opaque path"] = function parseOpaquePath(c3) {
3638
- if (c3 === p4("?")) {
4474
+ URLStateMachine.prototype["parse opaque path"] = function parseOpaquePath(c4) {
4475
+ if (c4 === p4("?")) {
3639
4476
  this.url.query = "";
3640
4477
  this.state = "query";
3641
- } else if (c3 === p4("#")) {
4478
+ } else if (c4 === p4("#")) {
3642
4479
  this.url.fragment = "";
3643
4480
  this.state = "fragment";
3644
- } else if (c3 === p4(" ")) {
4481
+ } else if (c4 === p4(" ")) {
3645
4482
  const remaining = this.input[this.pointer + 1];
3646
4483
  if (remaining === p4("?") || remaining === p4("#")) {
3647
4484
  this.url.path += "%20";
@@ -3649,44 +4486,44 @@ var require_url_state_machine = __commonJS({
3649
4486
  this.url.path += " ";
3650
4487
  }
3651
4488
  } else {
3652
- if (!isNaN(c3) && c3 !== p4("%")) {
4489
+ if (!isNaN(c4) && c4 !== p4("%")) {
3653
4490
  this.parseError = true;
3654
4491
  }
3655
- if (c3 === p4("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) {
4492
+ if (c4 === p4("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) {
3656
4493
  this.parseError = true;
3657
4494
  }
3658
- if (!isNaN(c3)) {
3659
- this.url.path += utf8PercentEncodeCodePoint(c3, isC0ControlPercentEncode);
4495
+ if (!isNaN(c4)) {
4496
+ this.url.path += utf8PercentEncodeCodePoint(c4, isC0ControlPercentEncode);
3660
4497
  }
3661
4498
  }
3662
4499
  return true;
3663
4500
  };
3664
- URLStateMachine.prototype["parse query"] = function parseQuery(c3, cStr) {
4501
+ URLStateMachine.prototype["parse query"] = function parseQuery(c4, cStr) {
3665
4502
  if (!isSpecial(this.url) || this.url.scheme === "ws" || this.url.scheme === "wss") {
3666
4503
  this.encodingOverride = "utf-8";
3667
4504
  }
3668
- if (!this.stateOverride && c3 === p4("#") || isNaN(c3)) {
4505
+ if (!this.stateOverride && c4 === p4("#") || isNaN(c4)) {
3669
4506
  const queryPercentEncodePredicate = isSpecial(this.url) ? isSpecialQueryPercentEncode : isQueryPercentEncode;
3670
4507
  this.url.query += utf8PercentEncodeString(this.buffer, queryPercentEncodePredicate);
3671
4508
  this.buffer = "";
3672
- if (c3 === p4("#")) {
4509
+ if (c4 === p4("#")) {
3673
4510
  this.url.fragment = "";
3674
4511
  this.state = "fragment";
3675
4512
  }
3676
- } else if (!isNaN(c3)) {
3677
- if (c3 === p4("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) {
4513
+ } else if (!isNaN(c4)) {
4514
+ if (c4 === p4("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) {
3678
4515
  this.parseError = true;
3679
4516
  }
3680
4517
  this.buffer += cStr;
3681
4518
  }
3682
4519
  return true;
3683
4520
  };
3684
- URLStateMachine.prototype["parse fragment"] = function parseFragment(c3) {
3685
- if (!isNaN(c3)) {
3686
- if (c3 === p4("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) {
4521
+ URLStateMachine.prototype["parse fragment"] = function parseFragment(c4) {
4522
+ if (!isNaN(c4)) {
4523
+ if (c4 === p4("%") && (!infra.isASCIIHex(this.input[this.pointer + 1]) || !infra.isASCIIHex(this.input[this.pointer + 2]))) {
3687
4524
  this.parseError = true;
3688
4525
  }
3689
- this.url.fragment += utf8PercentEncodeCodePoint(c3, isFragmentPercentEncode);
4526
+ this.url.fragment += utf8PercentEncodeCodePoint(c4, isFragmentPercentEncode);
3690
4527
  }
3691
4528
  return true;
3692
4529
  };
@@ -6366,7 +7203,7 @@ function n(e3, t2) {
6366
7203
  function u2(e3) {
6367
7204
  return new a3(e3);
6368
7205
  }
6369
- function c2(e3) {
7206
+ function c3(e3) {
6370
7207
  return l2(e3);
6371
7208
  }
6372
7209
  function d6(e3) {
@@ -6390,13 +7227,13 @@ function p3(e3, t2, r3) {
6390
7227
  function m4(e3) {
6391
7228
  f3(e3, void 0, o2);
6392
7229
  }
6393
- function g3(e3, t2, r3) {
7230
+ function g4(e3, t2, r3) {
6394
7231
  if ("function" != typeof e3) throw new TypeError("Argument is not a function");
6395
7232
  return Function.prototype.apply.call(e3, t2, r3);
6396
7233
  }
6397
7234
  function w6(e3, t2, r3) {
6398
7235
  try {
6399
- return c2(g3(e3, t2, r3));
7236
+ return c3(g4(e3, t2, r3));
6400
7237
  } catch (e4) {
6401
7238
  return d6(e4);
6402
7239
  }
@@ -6450,7 +7287,7 @@ function $5(e3, t2, r3) {
6450
7287
  function M4(e3, t2, r3) {
6451
7288
  if (void 0 === e3) throw new TypeError(`${t2} is required in '${r3}'.`);
6452
7289
  }
6453
- function Y2(e3) {
7290
+ function Y4(e3) {
6454
7291
  return Number(e3);
6455
7292
  }
6456
7293
  function Q4(e3) {
@@ -6465,7 +7302,7 @@ function N5(e3, t2) {
6465
7302
  }(o3), o3 < 0 || o3 > r3) throw new TypeError(`${t2} is outside the accepted range of 0 to ${r3}, inclusive`);
6466
7303
  return z5(o3) && 0 !== o3 ? o3 : 0;
6467
7304
  }
6468
- function H4(e3) {
7305
+ function H5(e3) {
6469
7306
  if (!r2(e3)) return false;
6470
7307
  if ("function" != typeof e3.getReader) return false;
6471
7308
  try {
@@ -6489,14 +7326,14 @@ function V5(e3, t2) {
6489
7326
  function U6(e3, t2) {
6490
7327
  e3._reader._readRequests.push(t2);
6491
7328
  }
6492
- function G5(e3, t2, r3) {
7329
+ function G6(e3, t2, r3) {
6493
7330
  const o3 = e3._reader._readRequests.shift();
6494
7331
  r3 ? o3._closeSteps() : o3._chunkSteps(t2);
6495
7332
  }
6496
7333
  function X4(e3) {
6497
7334
  return e3._reader._readRequests.length;
6498
7335
  }
6499
- function J4(e3) {
7336
+ function J5(e3) {
6500
7337
  const t2 = e3._reader;
6501
7338
  return void 0 !== t2 && !!K5(t2);
6502
7339
  }
@@ -6516,12 +7353,12 @@ function oe(e3) {
6516
7353
  if (!r2(e3)) return false;
6517
7354
  if (!Object.prototype.hasOwnProperty.call(e3, "_asyncIteratorImpl")) return false;
6518
7355
  try {
6519
- return e3._asyncIteratorImpl instanceof te;
7356
+ return e3._asyncIteratorImpl instanceof te2;
6520
7357
  } catch (e4) {
6521
7358
  return false;
6522
7359
  }
6523
7360
  }
6524
- function ne(e3) {
7361
+ function ne2(e3) {
6525
7362
  return new TypeError(`ReadableStreamAsyncIterator.${e3} can only be used on a ReadableSteamAsyncIterator`);
6526
7363
  }
6527
7364
  function ie2(e3, t2, r3, o3, n2) {
@@ -6535,7 +7372,7 @@ function le2(e3) {
6535
7372
  }(e3.buffer, e3.byteOffset, e3.byteOffset + e3.byteLength);
6536
7373
  return new Uint8Array(t2);
6537
7374
  }
6538
- function se(e3) {
7375
+ function se2(e3) {
6539
7376
  const t2 = e3._queue.shift();
6540
7377
  return e3._queueTotalSize -= t2.size, e3._queueTotalSize < 0 && (e3._queueTotalSize = 0), t2.value;
6541
7378
  }
@@ -6559,7 +7396,7 @@ function be(e3) {
6559
7396
  if ("readable" !== t3._state) return false;
6560
7397
  if (e4._closeRequested) return false;
6561
7398
  if (!e4._started) return false;
6562
- if (J4(t3) && X4(t3) > 0) return true;
7399
+ if (J5(t3) && X4(t3) > 0) return true;
6563
7400
  if (Le(t3) && ze(t3) > 0) return true;
6564
7401
  if (ke(e4) > 0) return true;
6565
7402
  return false;
@@ -6576,7 +7413,7 @@ function _e(e3, t2) {
6576
7413
  let r3 = false;
6577
7414
  "closed" === e3._state && (r3 = true);
6578
7415
  const o3 = pe(t2);
6579
- "default" === t2.readerType ? G5(e3, o3, r3) : function(e4, t3, r4) {
7416
+ "default" === t2.readerType ? G6(e3, o3, r3) : function(e4, t3, r4) {
6580
7417
  const o4 = e4._reader._readIntoRequests.shift();
6581
7418
  r4 ? o4._closeSteps(t3) : o4._chunkSteps(t3);
6582
7419
  }(e3, o3, r3);
@@ -6670,11 +7507,11 @@ function Oe(e3, t2, r3) {
6670
7507
  const o3 = Object.create(ReadableByteStreamController.prototype);
6671
7508
  let n2, a4, i3;
6672
7509
  n2 = void 0 !== t2.start ? () => t2.start(o3) : () => {
6673
- }, a4 = void 0 !== t2.pull ? () => t2.pull(o3) : () => c2(void 0), i3 = void 0 !== t2.cancel ? (e4) => t2.cancel(e4) : () => c2(void 0);
7510
+ }, a4 = void 0 !== t2.pull ? () => t2.pull(o3) : () => c3(void 0), i3 = void 0 !== t2.cancel ? (e4) => t2.cancel(e4) : () => c3(void 0);
6674
7511
  const l3 = t2.autoAllocateChunkSize;
6675
7512
  if (0 === l3) throw new TypeError("autoAllocateChunkSize must be greater than 0");
6676
7513
  !function(e4, t3, r4, o4, n3, a5, i4) {
6677
- t3._controlledReadableByteStream = e4, t3._pullAgain = false, t3._pulling = false, t3._byobRequest = null, t3._queue = t3._queueTotalSize = void 0, ce2(t3), t3._closeRequested = false, t3._started = false, t3._strategyHWM = a5, t3._pullAlgorithm = o4, t3._cancelAlgorithm = n3, t3._autoAllocateChunkSize = i4, t3._pendingPullIntos = new S5(), e4._readableStreamController = t3, b6(c2(r4()), () => (t3._started = true, be(t3), null), (e5) => (Pe(t3, e5), null));
7514
+ t3._controlledReadableByteStream = e4, t3._pullAgain = false, t3._pulling = false, t3._byobRequest = null, t3._queue = t3._queueTotalSize = void 0, ce2(t3), t3._closeRequested = false, t3._started = false, t3._strategyHWM = a5, t3._pullAlgorithm = o4, t3._cancelAlgorithm = n3, t3._autoAllocateChunkSize = i4, t3._pendingPullIntos = new S5(), e4._readableStreamController = t3, b6(c3(r4()), () => (t3._started = true, be(t3), null), (e5) => (Pe(t3, e5), null));
6678
7515
  }(e3, o3, n2, a4, i3, r3, l3);
6679
7516
  }
6680
7517
  function Be(e3) {
@@ -6705,7 +7542,7 @@ function Ie(e3, t2) {
6705
7542
  function De(e3) {
6706
7543
  return new TypeError(`ReadableStreamBYOBReader.prototype.${e3} can only be used on a ReadableStreamBYOBReader`);
6707
7544
  }
6708
- function $e(e3, t2) {
7545
+ function $e2(e3, t2) {
6709
7546
  const { highWaterMark: r3 } = e3;
6710
7547
  if (void 0 === r3) return t2;
6711
7548
  if (ae2(r3) || r3 < 0) throw new RangeError("Invalid highWaterMark");
@@ -6718,10 +7555,10 @@ function Me(e3) {
6718
7555
  function Ye(e3, t2) {
6719
7556
  F4(e3, t2);
6720
7557
  const r3 = null == e3 ? void 0 : e3.highWaterMark, o3 = null == e3 ? void 0 : e3.size;
6721
- return { highWaterMark: void 0 === r3 ? void 0 : Y2(r3), size: void 0 === o3 ? void 0 : Qe(o3, `${t2} has member 'size' that`) };
7558
+ return { highWaterMark: void 0 === r3 ? void 0 : Y4(r3), size: void 0 === o3 ? void 0 : Qe(o3, `${t2} has member 'size' that`) };
6722
7559
  }
6723
7560
  function Qe(e3, t2) {
6724
- return I4(e3, t2), (t3) => Y2(e3(t3));
7561
+ return I4(e3, t2), (t3) => Y4(e3(t3));
6725
7562
  }
6726
7563
  function Ne(e3, t2, r3) {
6727
7564
  return I4(e3, r3), (r4) => w6(e3, t2, [r4]);
@@ -6730,7 +7567,7 @@ function He(e3, t2, r3) {
6730
7567
  return I4(e3, r3), () => w6(e3, t2, []);
6731
7568
  }
6732
7569
  function xe(e3, t2, r3) {
6733
- return I4(e3, r3), (r4) => g3(e3, t2, [r4]);
7570
+ return I4(e3, r3), (r4) => g4(e3, t2, [r4]);
6734
7571
  }
6735
7572
  function Ve(e3, t2, r3) {
6736
7573
  return I4(e3, r3), (r4, o3) => w6(e3, t2, [r4, o3]);
@@ -6743,10 +7580,10 @@ function Xe(e3) {
6743
7580
  }
6744
7581
  function Je(e3, t2) {
6745
7582
  var r3;
6746
- if ("closed" === e3._state || "errored" === e3._state) return c2(void 0);
7583
+ if ("closed" === e3._state || "errored" === e3._state) return c3(void 0);
6747
7584
  e3._writableStreamController._abortReason = t2, null === (r3 = e3._writableStreamController._abortController) || void 0 === r3 || r3.abort(t2);
6748
7585
  const o3 = e3._state;
6749
- if ("closed" === o3 || "errored" === o3) return c2(void 0);
7586
+ if ("closed" === o3 || "errored" === o3) return c3(void 0);
6750
7587
  if (void 0 !== e3._pendingAbortRequest) return e3._pendingAbortRequest._promise;
6751
7588
  let n2 = false;
6752
7589
  "erroring" === o3 && (n2 = true, t2 = void 0);
@@ -6829,7 +7666,7 @@ function dt(e3) {
6829
7666
  const t3 = e4._controlledWritableStream;
6830
7667
  (function(e5) {
6831
7668
  e5._inFlightCloseRequest = e5._closeRequest, e5._closeRequest = void 0;
6832
- })(t3), se(e4);
7669
+ })(t3), se2(e4);
6833
7670
  const r4 = e4._closeAlgorithm();
6834
7671
  ut(e4), b6(r4, () => (function(e5) {
6835
7672
  e5._inFlightCloseRequest._resolve(void 0), e5._inFlightCloseRequest = void 0, "erroring" === e5._state && (e5._storedError = void 0, void 0 !== e5._pendingAbortRequest && (e5._pendingAbortRequest._resolve(), e5._pendingAbortRequest = void 0)), e5._state = "closed";
@@ -6848,7 +7685,7 @@ function dt(e3) {
6848
7685
  e5._inFlightWriteRequest._resolve(void 0), e5._inFlightWriteRequest = void 0;
6849
7686
  }(r4);
6850
7687
  const t4 = r4._state;
6851
- if (se(e4), !rt(r4) && "writable" === t4) {
7688
+ if (se2(e4), !rt(r4) && "writable" === t4) {
6852
7689
  const t5 = bt(e4);
6853
7690
  nt(r4, t5);
6854
7691
  }
@@ -6914,9 +7751,9 @@ function Et(e3) {
6914
7751
  function kt(e3, t2, r3, o3, n2, a4) {
6915
7752
  const i3 = e3.getReader(), l3 = t2.getWriter();
6916
7753
  Vt(e3) && (e3._disturbed = true);
6917
- let s2, _7, g4, w7 = false, S6 = false, v5 = "readable", R7 = "writable", T6 = false, q6 = false;
7754
+ let s2, _7, g5, w7 = false, S6 = false, v5 = "readable", R7 = "writable", T6 = false, q6 = false;
6918
7755
  const C5 = u2((e4) => {
6919
- g4 = e4;
7756
+ g5 = e4;
6920
7757
  });
6921
7758
  let E4 = Promise.resolve(void 0);
6922
7759
  return u2((P4, W6) => {
@@ -6926,7 +7763,7 @@ function kt(e3, t2, r3, o3, n2, a4) {
6926
7763
  const e4 = u2((e5, t3) => {
6927
7764
  !function r4(o4) {
6928
7765
  o4 ? e5() : f3(function() {
6929
- if (w7) return c2(true);
7766
+ if (w7) return c3(true);
6930
7767
  return f3(l3.ready, () => f3(i3.read(), (e6) => !!e6.done || (E4 = l3.write(e6.value), m4(E4), false)));
6931
7768
  }(), r4, t3);
6932
7769
  }(false);
@@ -6934,7 +7771,7 @@ function kt(e3, t2, r3, o3, n2, a4) {
6934
7771
  m4(e4);
6935
7772
  }
6936
7773
  function B3() {
6937
- return v5 = "closed", r3 ? L7() : z6(() => (Ge(t2) && (T6 = rt(t2), R7 = t2._state), T6 || "closed" === R7 ? c2(void 0) : "erroring" === R7 || "errored" === R7 ? d6(_7) : (T6 = true, l3.close())), false, void 0), null;
7774
+ return v5 = "closed", r3 ? L7() : z6(() => (Ge(t2) && (T6 = rt(t2), R7 = t2._state), T6 || "closed" === R7 ? c3(void 0) : "erroring" === R7 || "errored" === R7 ? d6(_7) : (T6 = true, l3.close())), false, void 0), null;
6938
7775
  }
6939
7776
  function A5(e4) {
6940
7777
  return w7 || (v5 = "errored", s2 = e4, o3 ? L7(true, e4) : z6(() => l3.abort(e4), true, e4)), null;
@@ -6944,8 +7781,8 @@ function kt(e3, t2, r3, o3, n2, a4) {
6944
7781
  }
6945
7782
  if (void 0 !== a4 && (k7 = () => {
6946
7783
  const e4 = void 0 !== a4.reason ? a4.reason : new Wt("Aborted", "AbortError"), t3 = [];
6947
- o3 || t3.push(() => "writable" === R7 ? l3.abort(e4) : c2(void 0)), n2 || t3.push(() => "readable" === v5 ? i3.cancel(e4) : c2(void 0)), z6(() => Promise.all(t3.map((e5) => e5())), true, e4);
6948
- }, a4.aborted ? k7() : a4.addEventListener("abort", k7)), Vt(e3) && (v5 = e3._state, s2 = e3._storedError), Ge(t2) && (R7 = t2._state, _7 = t2._storedError, T6 = rt(t2)), Vt(e3) && Ge(t2) && (q6 = true, g4()), "errored" === v5) A5(s2);
7784
+ o3 || t3.push(() => "writable" === R7 ? l3.abort(e4) : c3(void 0)), n2 || t3.push(() => "readable" === v5 ? i3.cancel(e4) : c3(void 0)), z6(() => Promise.all(t3.map((e5) => e5())), true, e4);
7785
+ }, a4.aborted ? k7() : a4.addEventListener("abort", k7)), Vt(e3) && (v5 = e3._state, s2 = e3._storedError), Ge(t2) && (R7 = t2._state, _7 = t2._storedError, T6 = rt(t2)), Vt(e3) && Ge(t2) && (q6 = true, g5()), "errored" === v5) A5(s2);
6949
7786
  else if ("erroring" === R7 || "errored" === R7) j4(_7);
6950
7787
  else if ("closed" === v5) B3();
6951
7788
  else if (T6 || "closed" === R7) {
@@ -6956,7 +7793,7 @@ function kt(e3, t2, r3, o3, n2, a4) {
6956
7793
  function o4() {
6957
7794
  return "writable" !== R7 || T6 ? n3() : h3(function() {
6958
7795
  let e5;
6959
- return c2(function t4() {
7796
+ return c3(function t4() {
6960
7797
  if (e5 !== E4) return e5 = E4, p3(E4, t4, t4);
6961
7798
  }());
6962
7799
  }(), n3), null;
@@ -6975,7 +7812,7 @@ function kt(e3, t2, r3, o3, n2, a4) {
6975
7812
  w7 || (b6(i3.closed, B3, A5), b6(l3.closed, function() {
6976
7813
  return S6 || (R7 = "closed"), null;
6977
7814
  }, j4)), q6 ? O5() : y5(() => {
6978
- q6 = true, g4(), O5();
7815
+ q6 = true, g5(), O5();
6979
7816
  });
6980
7817
  });
6981
7818
  }
@@ -6994,31 +7831,31 @@ function Ot(e3, t2) {
6994
7831
  function y6(e5) {
6995
7832
  _6(e5.closed, (t4) => (e5 !== i3 || (o3.error(t4), n2.error(t4), h4 && p4 || a4(void 0)), null));
6996
7833
  }
6997
- function g4() {
7834
+ function g5() {
6998
7835
  l3 && (i3.releaseLock(), i3 = e4.getReader(), y6(i3), l3 = false), b6(i3.read(), (e5) => {
6999
7836
  var t4, r4;
7000
7837
  if (d7 = false, f4 = false, e5.done) return h4 || o3.close(), p4 || n2.close(), null === (t4 = o3.byobRequest) || void 0 === t4 || t4.respond(0), null === (r4 = n2.byobRequest) || void 0 === r4 || r4.respond(0), h4 && p4 || a4(void 0), null;
7001
7838
  const l4 = e5.value, u3 = l4;
7002
- let c3 = l4;
7839
+ let c4 = l4;
7003
7840
  if (!h4 && !p4) try {
7004
- c3 = le2(l4);
7841
+ c4 = le2(l4);
7005
7842
  } catch (e6) {
7006
7843
  return o3.error(e6), n2.error(e6), a4(i3.cancel(e6)), null;
7007
7844
  }
7008
- return h4 || o3.enqueue(u3), p4 || n2.enqueue(c3), s2 = false, d7 ? S6() : f4 && v5(), null;
7845
+ return h4 || o3.enqueue(u3), p4 || n2.enqueue(c4), s2 = false, d7 ? S6() : f4 && v5(), null;
7009
7846
  }, () => (s2 = false, null));
7010
7847
  }
7011
7848
  function w7(t4, r4) {
7012
7849
  l3 || (i3.releaseLock(), i3 = e4.getReader({ mode: "byob" }), y6(i3), l3 = true);
7013
- const u3 = r4 ? n2 : o3, c3 = r4 ? o3 : n2;
7850
+ const u3 = r4 ? n2 : o3, c4 = r4 ? o3 : n2;
7014
7851
  b6(i3.read(t4), (e5) => {
7015
7852
  var t5;
7016
7853
  d7 = false, f4 = false;
7017
7854
  const o4 = r4 ? p4 : h4, n3 = r4 ? h4 : p4;
7018
7855
  if (e5.done) {
7019
- o4 || u3.close(), n3 || c3.close();
7856
+ o4 || u3.close(), n3 || c4.close();
7020
7857
  const r5 = e5.value;
7021
- return void 0 !== r5 && (o4 || u3.byobRequest.respondWithNewView(r5), n3 || null === (t5 = c3.byobRequest) || void 0 === t5 || t5.respond(0)), o4 && n3 || a4(void 0), null;
7858
+ return void 0 !== r5 && (o4 || u3.byobRequest.respondWithNewView(r5), n3 || null === (t5 = c4.byobRequest) || void 0 === t5 || t5.respond(0)), o4 && n3 || a4(void 0), null;
7022
7859
  }
7023
7860
  const l4 = e5.value;
7024
7861
  if (n3) o4 || u3.byobRequest.respondWithNewView(l4);
@@ -7027,24 +7864,24 @@ function Ot(e3, t2) {
7027
7864
  try {
7028
7865
  e6 = le2(l4);
7029
7866
  } catch (e7) {
7030
- return u3.error(e7), c3.error(e7), a4(i3.cancel(e7)), null;
7867
+ return u3.error(e7), c4.error(e7), a4(i3.cancel(e7)), null;
7031
7868
  }
7032
- o4 || u3.byobRequest.respondWithNewView(l4), c3.enqueue(e6);
7869
+ o4 || u3.byobRequest.respondWithNewView(l4), c4.enqueue(e6);
7033
7870
  }
7034
7871
  return s2 = false, d7 ? S6() : f4 && v5(), null;
7035
7872
  }, () => (s2 = false, null));
7036
7873
  }
7037
7874
  function S6() {
7038
- if (s2) return d7 = true, c2(void 0);
7875
+ if (s2) return d7 = true, c3(void 0);
7039
7876
  s2 = true;
7040
7877
  const e5 = o3.byobRequest;
7041
- return null === e5 ? g4() : w7(e5.view, false), c2(void 0);
7878
+ return null === e5 ? g5() : w7(e5.view, false), c3(void 0);
7042
7879
  }
7043
7880
  function v5() {
7044
- if (s2) return f4 = true, c2(void 0);
7881
+ if (s2) return f4 = true, c3(void 0);
7045
7882
  s2 = true;
7046
7883
  const e5 = n2.byobRequest;
7047
- return null === e5 ? g4() : w7(e5.view, true), c2(void 0);
7884
+ return null === e5 ? g5() : w7(e5.view, true), c3(void 0);
7048
7885
  }
7049
7886
  function R7(e5) {
7050
7887
  if (h4 = true, t3 = e5, p4) {
@@ -7073,11 +7910,11 @@ function Ot(e3, t2) {
7073
7910
  l3 = e5;
7074
7911
  });
7075
7912
  function m5() {
7076
- return s2 ? (d7 = true, c2(void 0)) : (s2 = true, b6(r3.read(), (e5) => {
7913
+ return s2 ? (d7 = true, c3(void 0)) : (s2 = true, b6(r3.read(), (e5) => {
7077
7914
  if (d7 = false, e5.done) return f4 || a4.close(), h4 || i3.close(), f4 && h4 || l3(void 0), null;
7078
7915
  const t4 = e5.value, r4 = t4, o4 = t4;
7079
7916
  return f4 || a4.enqueue(r4), h4 || i3.enqueue(o4), s2 = false, d7 && m5(), null;
7080
- }, () => (s2 = false, null)), c2(void 0));
7917
+ }, () => (s2 = false, null)), c3(void 0));
7081
7918
  }
7082
7919
  function y6(e5) {
7083
7920
  if (f4 = true, o3 = e5, h4) {
@@ -7086,7 +7923,7 @@ function Ot(e3, t2) {
7086
7923
  }
7087
7924
  return p4;
7088
7925
  }
7089
- function g4(e5) {
7926
+ function g5(e5) {
7090
7927
  if (h4 = true, n2 = e5, f4) {
7091
7928
  const e6 = [o3, n2], t4 = r3.cancel(e6);
7092
7929
  l3(t4);
@@ -7097,7 +7934,7 @@ function Ot(e3, t2) {
7097
7934
  a4 = e5;
7098
7935
  }, pull: m5, cancel: y6 }), S6 = new ReadableStream3({ start(e5) {
7099
7936
  i3 = e5;
7100
- }, pull: m5, cancel: g4 });
7937
+ }, pull: m5, cancel: g5 });
7101
7938
  return _6(r3.closed, (e5) => (a4.error(e5), i3.error(e5), f4 && h4 || l3(void 0), null)), [w7, S6];
7102
7939
  }(e3);
7103
7940
  }
@@ -7136,8 +7973,8 @@ function It(e3, t2, r3, o3) {
7136
7973
  const n2 = Object.create(ReadableStreamDefaultController.prototype);
7137
7974
  let a4, i3, l3;
7138
7975
  a4 = void 0 !== t2.start ? () => t2.start(n2) : () => {
7139
- }, i3 = void 0 !== t2.pull ? () => t2.pull(n2) : () => c2(void 0), l3 = void 0 !== t2.cancel ? (e4) => t2.cancel(e4) : () => c2(void 0), function(e4, t3, r4, o4, n3, a5, i4) {
7140
- t3._controlledReadableStream = e4, t3._queue = void 0, t3._queueTotalSize = void 0, ce2(t3), t3._started = false, t3._closeRequested = false, t3._pullAgain = false, t3._pulling = false, t3._strategySizeAlgorithm = i4, t3._strategyHWM = a5, t3._pullAlgorithm = o4, t3._cancelAlgorithm = n3, e4._readableStreamController = t3, b6(c2(r4()), () => (t3._started = true, At(t3), null), (e5) => (zt(t3, e5), null));
7976
+ }, i3 = void 0 !== t2.pull ? () => t2.pull(n2) : () => c3(void 0), l3 = void 0 !== t2.cancel ? (e4) => t2.cancel(e4) : () => c3(void 0), function(e4, t3, r4, o4, n3, a5, i4) {
7977
+ t3._controlledReadableStream = e4, t3._queue = void 0, t3._queueTotalSize = void 0, ce2(t3), t3._started = false, t3._closeRequested = false, t3._pullAgain = false, t3._pulling = false, t3._strategySizeAlgorithm = i4, t3._strategyHWM = a5, t3._pullAlgorithm = o4, t3._cancelAlgorithm = n3, e4._readableStreamController = t3, b6(c3(r4()), () => (t3._started = true, At(t3), null), (e5) => (zt(t3, e5), null));
7141
7978
  }(e3, n2, a4, i3, l3, r3, o3);
7142
7979
  }
7143
7980
  function Dt(e3) {
@@ -7150,7 +7987,7 @@ function Mt(e3, t2, r3) {
7150
7987
  return I4(e3, r3), (r4) => w6(e3, t2, [r4]);
7151
7988
  }
7152
7989
  function Yt(e3, t2, r3) {
7153
- return I4(e3, r3), (r4) => g3(e3, t2, [r4]);
7990
+ return I4(e3, r3), (r4) => g4(e3, t2, [r4]);
7154
7991
  }
7155
7992
  function Qt(e3, t2) {
7156
7993
  if ("bytes" !== (e3 = `${e3}`)) throw new TypeError(`${t2} '${e3}' is not a valid enumeration value for ReadableStreamType`);
@@ -7178,7 +8015,7 @@ function xt(e3, t2) {
7178
8015
  F4(e3, t2);
7179
8016
  const r3 = null == e3 ? void 0 : e3.readable;
7180
8017
  M4(r3, "readable", "ReadableWritablePair"), function(e4, t3) {
7181
- if (!H4(e4)) throw new TypeError(`${t3} is not a ReadableStream.`);
8018
+ if (!H5(e4)) throw new TypeError(`${t3} is not a ReadableStream.`);
7182
8019
  }(r3, `${t2} has member 'readable' that`);
7183
8020
  const o3 = null == e3 ? void 0 : e3.writable;
7184
8021
  return M4(o3, "writable", "ReadableWritablePair"), function(e4, t3) {
@@ -7192,7 +8029,7 @@ function Ut(e3) {
7192
8029
  return void 0 !== e3._reader;
7193
8030
  }
7194
8031
  function Gt(e3, r3) {
7195
- if (e3._disturbed = true, "closed" === e3._state) return c2(void 0);
8032
+ if (e3._disturbed = true, "closed" === e3._state) return c3(void 0);
7196
8033
  if ("errored" === e3._state) return d6(e3._storedError);
7197
8034
  Xt(e3);
7198
8035
  const o3 = e3._reader;
@@ -7225,7 +8062,7 @@ function Kt(e3) {
7225
8062
  function Zt(e3, t2) {
7226
8063
  F4(e3, t2);
7227
8064
  const r3 = null == e3 ? void 0 : e3.highWaterMark;
7228
- return M4(r3, "highWaterMark", "QueuingStrategyInit"), { highWaterMark: Y2(r3) };
8065
+ return M4(r3, "highWaterMark", "QueuingStrategyInit"), { highWaterMark: Y4(r3) };
7229
8066
  }
7230
8067
  function tr(e3) {
7231
8068
  return new TypeError(`ByteLengthQueuingStrategy.prototype.${e3} can only be used on a ByteLengthQueuingStrategy`);
@@ -7243,7 +8080,7 @@ function ir(e3, t2, r3) {
7243
8080
  return I4(e3, r3), (r4) => w6(e3, t2, [r4]);
7244
8081
  }
7245
8082
  function lr(e3, t2, r3) {
7246
- return I4(e3, r3), (r4) => g3(e3, t2, [r4]);
8083
+ return I4(e3, r3), (r4) => g4(e3, t2, [r4]);
7247
8084
  }
7248
8085
  function sr(e3, t2, r3) {
7249
8086
  return I4(e3, r3), (r4, o3) => w6(e3, t2, [r4, o3]);
@@ -7333,7 +8170,7 @@ function qr(e3) {
7333
8170
  function Cr(e3) {
7334
8171
  "erroring" === e3._writableState && qr(e3);
7335
8172
  }
7336
- var e2, o2, a3, i2, l2, s, y5, S5, v4, R6, T5, q5, C4, z5, L6, ReadableStreamDefaultReader, te, re2, ae2, ReadableStreamBYOBRequest, ReadableByteStreamController, ReadableStreamBYOBReader, Ue, WritableStream, WritableStreamDefaultWriter, lt, WritableStreamDefaultController, Pt, Wt, ReadableStreamDefaultController, ReadableStream3, er, ByteLengthQueuingStrategy, or, CountQueuingStrategy, TransformStream2, TransformStreamDefaultController;
8173
+ var e2, o2, a3, i2, l2, s, y5, S5, v4, R6, T5, q5, C4, z5, L6, ReadableStreamDefaultReader, te2, re2, ae2, ReadableStreamBYOBRequest, ReadableByteStreamController, ReadableStreamBYOBReader, Ue, WritableStream, WritableStreamDefaultWriter, lt, WritableStreamDefaultController, Pt, Wt, ReadableStreamDefaultController, ReadableStream3, er, ByteLengthQueuingStrategy, or, CountQueuingStrategy, TransformStream2, TransformStreamDefaultController;
7337
8174
  var init_ponyfill = __esm({
7338
8175
  "node_modules/formdata-node/node_modules/web-streams-polyfill/dist/ponyfill.mjs"() {
7339
8176
  e2 = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? Symbol : (e3) => `Symbol(${e3})`;
@@ -7345,7 +8182,7 @@ var init_ponyfill = __esm({
7345
8182
  y5 = (e3) => {
7346
8183
  if ("function" == typeof queueMicrotask) y5 = queueMicrotask;
7347
8184
  else {
7348
- const e4 = c2(void 0);
8185
+ const e4 = c3(void 0);
7349
8186
  y5 = (t2) => f3(e4, t2);
7350
8187
  }
7351
8188
  return y5(e3);
@@ -7423,7 +8260,7 @@ var init_ponyfill = __esm({
7423
8260
  }
7424
8261
  };
7425
8262
  Object.defineProperties(ReadableStreamDefaultReader.prototype, { cancel: { enumerable: true }, read: { enumerable: true }, releaseLock: { enumerable: true }, closed: { enumerable: true } }), n(ReadableStreamDefaultReader.prototype.cancel, "cancel"), n(ReadableStreamDefaultReader.prototype.read, "read"), n(ReadableStreamDefaultReader.prototype.releaseLock, "releaseLock"), "symbol" == typeof e2.toStringTag && Object.defineProperty(ReadableStreamDefaultReader.prototype, e2.toStringTag, { value: "ReadableStreamDefaultReader", configurable: true });
7426
- te = class {
8263
+ te2 = class {
7427
8264
  constructor(e3, t2) {
7428
8265
  this._ongoingPromise = void 0, this._isFinished = false, this._reader = e3, this._preventCancel = t2;
7429
8266
  }
@@ -7455,13 +8292,13 @@ var init_ponyfill = __esm({
7455
8292
  const r3 = t2.cancel(e3);
7456
8293
  return t2.releaseLock(), p3(r3, () => ({ value: e3, done: true }));
7457
8294
  }
7458
- return t2.releaseLock(), c2({ value: e3, done: true });
8295
+ return t2.releaseLock(), c3({ value: e3, done: true });
7459
8296
  }
7460
8297
  };
7461
8298
  re2 = { next() {
7462
- return oe(this) ? this._asyncIteratorImpl.next() : d6(ne("next"));
8299
+ return oe(this) ? this._asyncIteratorImpl.next() : d6(ne2("next"));
7463
8300
  }, return(e3) {
7464
- return oe(this) ? this._asyncIteratorImpl.return(e3) : d6(ne("return"));
8301
+ return oe(this) ? this._asyncIteratorImpl.return(e3) : d6(ne2("return"));
7465
8302
  } };
7466
8303
  "symbol" == typeof e2.asyncIterator && Object.defineProperty(re2, e2.asyncIterator, { value() {
7467
8304
  return this;
@@ -7563,7 +8400,7 @@ var init_ponyfill = __esm({
7563
8400
  const t4 = e4._pendingPullIntos.peek();
7564
8401
  t4.buffer, 0, Re(e4), t4.buffer = t4.buffer, "none" === t4.readerType && ge(e4, t4);
7565
8402
  }
7566
- if (J4(r3)) if (function(e5) {
8403
+ if (J5(r3)) if (function(e5) {
7567
8404
  const t4 = e5._controlledReadableByteStream._reader;
7568
8405
  for (; t4._readRequests.length > 0; ) {
7569
8406
  if (0 === e5._queueTotalSize) return;
@@ -7572,7 +8409,7 @@ var init_ponyfill = __esm({
7572
8409
  }(e4), 0 === X4(r3)) me(e4, i3, n2, a4);
7573
8410
  else {
7574
8411
  e4._pendingPullIntos.length > 0 && Ce(e4);
7575
- G5(r3, new Uint8Array(i3, n2, a4), false);
8412
+ G6(r3, new Uint8Array(i3, n2, a4), false);
7576
8413
  }
7577
8414
  else Le(r3) ? (me(e4, i3, n2, a4), Te(e4)) : me(e4, i3, n2, a4);
7578
8415
  be(e4);
@@ -7688,9 +8525,9 @@ var init_ponyfill = __esm({
7688
8525
  let a5, i3, l3, s2;
7689
8526
  a5 = void 0 !== t3.start ? () => t3.start(n3) : () => {
7690
8527
  };
7691
- i3 = void 0 !== t3.write ? (e5) => t3.write(e5, n3) : () => c2(void 0);
7692
- l3 = void 0 !== t3.close ? () => t3.close() : () => c2(void 0);
7693
- s2 = void 0 !== t3.abort ? (e5) => t3.abort(e5) : () => c2(void 0);
8528
+ i3 = void 0 !== t3.write ? (e5) => t3.write(e5, n3) : () => c3(void 0);
8529
+ l3 = void 0 !== t3.close ? () => t3.close() : () => c3(void 0);
8530
+ s2 = void 0 !== t3.abort ? (e5) => t3.abort(e5) : () => c3(void 0);
7694
8531
  !function(e5, t4, r5, o5, n4, a6, i4, l4) {
7695
8532
  t4._controlledWritableStream = e5, e5._writableStreamController = t4, t4._queue = void 0, t4._queueTotalSize = void 0, ce2(t4), t4._abortReason = void 0, t4._abortController = function() {
7696
8533
  if (Ue) return new AbortController();
@@ -7698,9 +8535,9 @@ var init_ponyfill = __esm({
7698
8535
  const s3 = bt(t4);
7699
8536
  nt(e5, s3);
7700
8537
  const u3 = r5();
7701
- b6(c2(u3), () => (t4._started = true, dt(t4), null), (r6) => (t4._started = true, Ze(e5, r6), null));
8538
+ b6(c3(u3), () => (t4._started = true, dt(t4), null), (r6) => (t4._started = true, Ze(e5, r6), null));
7702
8539
  }(e4, n3, a5, i3, l3, s2, r4, o4);
7703
- }(this, o3, $e(r3, 1), a4);
8540
+ }(this, o3, $e2(r3, 1), a4);
7704
8541
  }
7705
8542
  get locked() {
7706
8543
  if (!Ge(this)) throw _t("locked");
@@ -7871,7 +8708,7 @@ var init_ponyfill = __esm({
7871
8708
  return function(e4, t2) {
7872
8709
  if (!Ft(e4)) return;
7873
8710
  const r3 = e4._controlledReadableStream;
7874
- if (Ut(r3) && X4(r3) > 0) G5(r3, t2, false);
8711
+ if (Ut(r3) && X4(r3) > 0) G6(r3, t2, false);
7875
8712
  else {
7876
8713
  let r4;
7877
8714
  try {
@@ -7900,7 +8737,7 @@ var init_ponyfill = __esm({
7900
8737
  [q5](e3) {
7901
8738
  const t2 = this._controlledReadableStream;
7902
8739
  if (this._queue.length > 0) {
7903
- const r3 = se(this);
8740
+ const r3 = se2(this);
7904
8741
  this._closeRequested && 0 === this._queue.length ? (jt(this), Xt(t2)) : At(this), e3._chunkSteps(r3);
7905
8742
  } else U6(t2, e3), At(this);
7906
8743
  }
@@ -7919,10 +8756,10 @@ var init_ponyfill = __esm({
7919
8756
  var n2;
7920
8757
  if ((n2 = this)._state = "readable", n2._reader = void 0, n2._storedError = void 0, n2._disturbed = false, "bytes" === o3.type) {
7921
8758
  if (void 0 !== r3.size) throw new RangeError("The strategy for a byte stream cannot have a size function");
7922
- Oe(this, o3, $e(r3, 0));
8759
+ Oe(this, o3, $e2(r3, 0));
7923
8760
  } else {
7924
8761
  const e4 = Me(r3);
7925
- It(this, o3, $e(r3, 1), e4);
8762
+ It(this, o3, $e2(r3, 1), e4);
7926
8763
  }
7927
8764
  }
7928
8765
  get locked() {
@@ -7943,7 +8780,7 @@ var init_ponyfill = __esm({
7943
8780
  }(this);
7944
8781
  }
7945
8782
  pipeThrough(e3, t2 = {}) {
7946
- if (!H4(this)) throw Kt("pipeThrough");
8783
+ if (!H5(this)) throw Kt("pipeThrough");
7947
8784
  $5(e3, 1, "pipeThrough");
7948
8785
  const r3 = xt(e3, "First parameter"), o3 = Ht(t2, "Second parameter");
7949
8786
  if (this.locked) throw new TypeError("ReadableStream.prototype.pipeThrough cannot be used on a locked ReadableStream");
@@ -7951,7 +8788,7 @@ var init_ponyfill = __esm({
7951
8788
  return m4(kt(this, r3.writable, o3.preventClose, o3.preventAbort, o3.preventCancel, o3.signal)), r3.readable;
7952
8789
  }
7953
8790
  pipeTo(e3, t2 = {}) {
7954
- if (!H4(this)) return d6(Kt("pipeTo"));
8791
+ if (!H5(this)) return d6(Kt("pipeTo"));
7955
8792
  if (void 0 === e3) return d6("Parameter 1 is required in 'pipeTo'.");
7956
8793
  if (!x4(e3)) return d6(new TypeError("ReadableStream.prototype.pipeTo's first argument must be a WritableStream"));
7957
8794
  let r3;
@@ -7963,14 +8800,14 @@ var init_ponyfill = __esm({
7963
8800
  return this.locked ? d6(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked ReadableStream")) : e3.locked ? d6(new TypeError("ReadableStream.prototype.pipeTo cannot be used on a locked WritableStream")) : kt(this, e3, r3.preventClose, r3.preventAbort, r3.preventCancel, r3.signal);
7964
8801
  }
7965
8802
  tee() {
7966
- if (!H4(this)) throw Kt("tee");
8803
+ if (!H5(this)) throw Kt("tee");
7967
8804
  if (this.locked) throw new TypeError("Cannot tee a stream that already has a reader");
7968
8805
  return Ot(this);
7969
8806
  }
7970
8807
  values(e3) {
7971
- if (!H4(this)) throw Kt("values");
8808
+ if (!H5(this)) throw Kt("values");
7972
8809
  return function(e4, t2) {
7973
- const r3 = e4.getReader(), o3 = new te(r3, t2), n2 = Object.create(re2);
8810
+ const r3 = e4.getReader(), o3 = new te2(r3, t2), n2 = Object.create(re2);
7974
8811
  return n2._asyncIteratorImpl = o3, n2;
7975
8812
  }(this, function(e4, t2) {
7976
8813
  F4(e4, t2);
@@ -8022,7 +8859,7 @@ var init_ponyfill = __esm({
8022
8859
  }(e3, "First parameter");
8023
8860
  if (void 0 !== a4.readableType) throw new RangeError("Invalid readableType specified");
8024
8861
  if (void 0 !== a4.writableType) throw new RangeError("Invalid writableType specified");
8025
- const i3 = $e(n2, 0), l3 = Me(n2), s2 = $e(o3, 1), f4 = Me(o3);
8862
+ const i3 = $e2(n2, 0), l3 = Me(n2), s2 = $e2(o3, 1), f4 = Me(o3);
8026
8863
  let b7;
8027
8864
  !function(e4, t3, r4, o4, n3, a5) {
8028
8865
  function i4() {
@@ -8042,7 +8879,7 @@ var init_ponyfill = __esm({
8042
8879
  }
8043
8880
  function s3(t4) {
8044
8881
  return function(e5, t5) {
8045
- return cr(e5, t5), c2(void 0);
8882
+ return cr(e5, t5), c3(void 0);
8046
8883
  }(e4, t4);
8047
8884
  }
8048
8885
  function u3() {
@@ -8062,7 +8899,7 @@ var init_ponyfill = __esm({
8062
8899
  }(e4);
8063
8900
  }
8064
8901
  function f5(t4) {
8065
- return dr(e4, t4), c2(void 0);
8902
+ return dr(e4, t4), c3(void 0);
8066
8903
  }
8067
8904
  e4._writableState = "writable", e4._writableStoredError = void 0, e4._writableHasInFlightOperation = false, e4._writableStarted = false, e4._writable = function(e5, t4, r5, o5, n4, a6, i5) {
8068
8905
  return new WritableStream({ start(r6) {
@@ -8110,12 +8947,12 @@ var init_ponyfill = __esm({
8110
8947
  let o4, n3;
8111
8948
  o4 = void 0 !== t3.transform ? (e5) => t3.transform(e5, r4) : (e5) => {
8112
8949
  try {
8113
- return _r(r4, e5), c2(void 0);
8950
+ return _r(r4, e5), c3(void 0);
8114
8951
  } catch (e6) {
8115
8952
  return d6(e6);
8116
8953
  }
8117
8954
  };
8118
- n3 = void 0 !== t3.flush ? () => t3.flush(r4) : () => c2(void 0);
8955
+ n3 = void 0 !== t3.flush ? () => t3.flush(r4) : () => c3(void 0);
8119
8956
  !function(e5, t4, r5, o5) {
8120
8957
  t4._controlledTransformStream = e5, e5._transformStreamController = t4, t4._transformAlgorithm = r5, t4._flushAlgorithm = o5;
8121
8958
  }(e4, r4, o4, n3);
@@ -23779,8 +24616,8 @@ var require_browser = __commonJS({
23779
24616
  if (!this.useColors) {
23780
24617
  return;
23781
24618
  }
23782
- const c3 = "color: " + this.color;
23783
- args.splice(1, 0, c3, "color: inherit");
24619
+ const c4 = "color: " + this.color;
24620
+ args.splice(1, 0, c4, "color: inherit");
23784
24621
  let index = 0;
23785
24622
  let lastC = 0;
23786
24623
  args[0].replace(/%[a-zA-Z%]/g, (match) => {
@@ -23792,7 +24629,7 @@ var require_browser = __commonJS({
23792
24629
  lastC = index;
23793
24630
  }
23794
24631
  });
23795
- args.splice(lastC, 0, c3);
24632
+ args.splice(lastC, 0, c4);
23796
24633
  }
23797
24634
  exports2.log = console.debug || console.log || (() => {
23798
24635
  });
@@ -24076,8 +24913,8 @@ var require_node = __commonJS({
24076
24913
  function formatArgs(args) {
24077
24914
  const { namespace: name, useColors: useColors2 } = this;
24078
24915
  if (useColors2) {
24079
- const c3 = this.color;
24080
- const colorCode = "\x1B[3" + (c3 < 8 ? c3 : "8;5;" + c3);
24916
+ const c4 = this.color;
24917
+ const colorCode = "\x1B[3" + (c4 < 8 ? c4 : "8;5;" + c4);
24081
24918
  const prefix = ` ${colorCode};1m${name} \x1B[0m`;
24082
24919
  args[0] = prefix + args[0].split("\n").join("\n" + prefix);
24083
24920
  args.push(colorCode + "m+" + module2.exports.humanize(this.diff) + "\x1B[0m");
@@ -26820,8 +27657,8 @@ var require_object_inspect = __commonJS({
26820
27657
  var s2 = $replace.call($replace.call(str2, /(['\\])/g, "\\$1"), /[\x00-\x1f]/g, lowbyte);
26821
27658
  return wrapQuotes(s2, "single", opts);
26822
27659
  }
26823
- function lowbyte(c3) {
26824
- var n2 = c3.charCodeAt(0);
27660
+ function lowbyte(c4) {
27661
+ var n2 = c4.charCodeAt(0);
26825
27662
  var x5 = {
26826
27663
  8: "b",
26827
27664
  9: "t",
@@ -27182,26 +28019,26 @@ var require_utils2 = __commonJS({
27182
28019
  var segment = string.length >= limit ? string.slice(j4, j4 + limit) : string;
27183
28020
  var arr = [];
27184
28021
  for (var i3 = 0; i3 < segment.length; ++i3) {
27185
- var c3 = segment.charCodeAt(i3);
27186
- if (c3 === 45 || c3 === 46 || c3 === 95 || c3 === 126 || c3 >= 48 && c3 <= 57 || c3 >= 65 && c3 <= 90 || c3 >= 97 && c3 <= 122 || format === formats.RFC1738 && (c3 === 40 || c3 === 41)) {
28022
+ var c4 = segment.charCodeAt(i3);
28023
+ if (c4 === 45 || c4 === 46 || c4 === 95 || c4 === 126 || c4 >= 48 && c4 <= 57 || c4 >= 65 && c4 <= 90 || c4 >= 97 && c4 <= 122 || format === formats.RFC1738 && (c4 === 40 || c4 === 41)) {
27187
28024
  arr[arr.length] = segment.charAt(i3);
27188
28025
  continue;
27189
28026
  }
27190
- if (c3 < 128) {
27191
- arr[arr.length] = hexTable[c3];
28027
+ if (c4 < 128) {
28028
+ arr[arr.length] = hexTable[c4];
27192
28029
  continue;
27193
28030
  }
27194
- if (c3 < 2048) {
27195
- arr[arr.length] = hexTable[192 | c3 >> 6] + hexTable[128 | c3 & 63];
28031
+ if (c4 < 2048) {
28032
+ arr[arr.length] = hexTable[192 | c4 >> 6] + hexTable[128 | c4 & 63];
27196
28033
  continue;
27197
28034
  }
27198
- if (c3 < 55296 || c3 >= 57344) {
27199
- arr[arr.length] = hexTable[224 | c3 >> 12] + hexTable[128 | c3 >> 6 & 63] + hexTable[128 | c3 & 63];
28035
+ if (c4 < 55296 || c4 >= 57344) {
28036
+ arr[arr.length] = hexTable[224 | c4 >> 12] + hexTable[128 | c4 >> 6 & 63] + hexTable[128 | c4 & 63];
27200
28037
  continue;
27201
28038
  }
27202
28039
  i3 += 1;
27203
- c3 = 65536 + ((c3 & 1023) << 10 | segment.charCodeAt(i3) & 1023);
27204
- arr[arr.length] = hexTable[240 | c3 >> 18] + hexTable[128 | c3 >> 12 & 63] + hexTable[128 | c3 >> 6 & 63] + hexTable[128 | c3 & 63];
28040
+ c4 = 65536 + ((c4 & 1023) << 10 | segment.charCodeAt(i3) & 1023);
28041
+ arr[arr.length] = hexTable[240 | c4 >> 18] + hexTable[128 | c4 >> 12 & 63] + hexTable[128 | c4 >> 6 & 63] + hexTable[128 | c4 & 63];
27205
28042
  }
27206
28043
  out += arr.join("");
27207
28044
  }
@@ -32184,7 +33021,7 @@ var require_base64 = __commonJS({
32184
33021
  return btoa(String.fromCodePoint(...u8arr));
32185
33022
  }
32186
33023
  function bytesFromBase64(encoded) {
32187
- return Uint8Array.from(atob(encoded), (c3) => c3.charCodeAt(0));
33024
+ return Uint8Array.from(atob(encoded), (c4) => c4.charCodeAt(0));
32188
33025
  }
32189
33026
  function stringToBytes(str2) {
32190
33027
  return new TextEncoder().encode(str2);
@@ -47084,11 +47921,11 @@ var $ = (t2, { onFlag: n2, onArgument: r3 }) => {
47084
47921
  const a4 = N(i3);
47085
47922
  if (a4) {
47086
47923
  if (o3(), !n2) continue;
47087
- const [l3, f4, g4] = a4;
47088
- if (g4) for (let c3 = 0; c3 < l3.length; c3 += 1) {
47924
+ const [l3, f4, g5] = a4;
47925
+ if (g5) for (let c4 = 0; c4 < l3.length; c4 += 1) {
47089
47926
  o3();
47090
- const u3 = c3 === l3.length - 1;
47091
- e3 = n2(l3[c3], u3 ? f4 : void 0, [s2, c3 + 1, u3]);
47927
+ const u3 = c4 === l3.length - 1;
47928
+ e3 = n2(l3[c4], u3 ? f4 : void 0, [s2, c4 + 1, u3]);
47092
47929
  }
47093
47930
  else e3 = n2(l3, f4, [s2]);
47094
47931
  } else o3(i3, [s2]) && r3?.([i3], [s2]);
@@ -47111,11 +47948,11 @@ var E = (t2, n2) => {
47111
47948
  var U = (t2, n2 = process.argv.slice(2), { ignore: r3 } = {}) => {
47112
47949
  const e3 = [], o3 = K(t2), s2 = {}, i3 = [];
47113
47950
  return i3[F] = [], $(n2, { onFlag(a4, l3, f4) {
47114
- const g4 = w(o3, a4);
47115
- if (!r3?.(g4 ? V : k, a4, l3)) {
47116
- if (g4) {
47117
- const [c3, u3] = o3[a4], y6 = d(u3, l3), p4 = (P4, A5) => {
47118
- e3.push(f4), A5 && e3.push(A5), c3.push(m(u3, P4 || ""));
47951
+ const g5 = w(o3, a4);
47952
+ if (!r3?.(g5 ? V : k, a4, l3)) {
47953
+ if (g5) {
47954
+ const [c4, u3] = o3[a4], y6 = d(u3, l3), p4 = (P4, A5) => {
47955
+ e3.push(f4), A5 && e3.push(A5), c4.push(m(u3, P4 || ""));
47119
47956
  };
47120
47957
  return y6 === void 0 ? p4 : p4(y6);
47121
47958
  }
@@ -47621,19 +48458,19 @@ function x2(t2, e3, r3, n2) {
47621
48458
  console.log(e3.version);
47622
48459
  };
47623
48460
  if (i3 && l3.flags.version === true) return f4(), process.exit(0);
47624
- const p4 = new M2(), O5 = o3 && s2?.render ? s2.render : (c3) => p4.render(c3), u3 = (c3) => {
47625
- const m5 = U3({ ...e3, ...c3 ? { help: c3 } : {}, flags: a4 });
48461
+ const p4 = new M2(), O5 = o3 && s2?.render ? s2.render : (c4) => p4.render(c4), u3 = (c4) => {
48462
+ const m5 = U3({ ...e3, ...c4 ? { help: c4 } : {}, flags: a4 });
47626
48463
  console.log(O5(m5, p4));
47627
48464
  };
47628
48465
  if (o3 && l3.flags.help === true) return u3(), process.exit(0);
47629
48466
  if (e3.parameters) {
47630
- let { parameters: c3 } = e3, m5 = l3._;
47631
- const g4 = c3.indexOf("--"), v5 = c3.slice(g4 + 1), h4 = /* @__PURE__ */ Object.create(null);
47632
- if (g4 > -1 && v5.length > 0) {
47633
- c3 = c3.slice(0, g4);
48467
+ let { parameters: c4 } = e3, m5 = l3._;
48468
+ const g5 = c4.indexOf("--"), v5 = c4.slice(g5 + 1), h4 = /* @__PURE__ */ Object.create(null);
48469
+ if (g5 > -1 && v5.length > 0) {
48470
+ c4 = c4.slice(0, g5);
47634
48471
  const E4 = l3._["--"];
47635
- m5 = m5.slice(0, -E4.length || void 0), b3(h4, w3(c3), m5, u3), b3(h4, w3(v5), E4, u3);
47636
- } else b3(h4, w3(c3), m5, u3);
48472
+ m5 = m5.slice(0, -E4.length || void 0), b3(h4, w3(c4), m5, u3), b3(h4, w3(v5), E4, u3);
48473
+ } else b3(h4, w3(c4), m5, u3);
47637
48474
  Object.assign(l3._, h4);
47638
48475
  }
47639
48476
  const $6 = { ...l3, showVersion: f4, showHelp: u3 };
@@ -47672,7 +48509,7 @@ function G3(t2, e3) {
47672
48509
  // package.json
47673
48510
  var package_default = {
47674
48511
  name: "opencommit",
47675
- version: "3.2.9",
48512
+ version: "3.2.11",
47676
48513
  description: "Auto-generate impressive commits in 1 second. Killing lame commits with AI \u{1F92F}\u{1F52B}",
47677
48514
  keywords: [
47678
48515
  "git",
@@ -47723,6 +48560,7 @@ var package_default = {
47723
48560
  "deploy:patch": "npm version patch && npm run deploy:build",
47724
48561
  lint: "eslint src --ext ts && tsc --noEmit",
47725
48562
  format: "prettier --write src",
48563
+ "format:check": "prettier --check src",
47726
48564
  test: "node --no-warnings --experimental-vm-modules $( [ -f ./node_modules/.bin/jest ] && echo ./node_modules/.bin/jest || which jest ) test/unit",
47727
48565
  "test:all": "npm run test:unit:docker && npm run test:e2e:docker",
47728
48566
  "test:docker-build": "docker build -t oco-test -f test/Dockerfile .",
@@ -47782,566 +48620,8 @@ var package_default = {
47782
48620
  }
47783
48621
  };
47784
48622
 
47785
- // node_modules/@clack/core/dist/index.mjs
47786
- var import_sisteransi = __toESM(require_src(), 1);
47787
- var import_node_process = require("node:process");
47788
- var f = __toESM(require("node:readline"), 1);
47789
- var import_node_readline = __toESM(require("node:readline"), 1);
47790
- var import_node_tty = require("node:tty");
47791
- function q3({ onlyFirst: t2 = false } = {}) {
47792
- const u3 = ["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)", "(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-ntqry=><~]))"].join("|");
47793
- return new RegExp(u3, t2 ? void 0 : "g");
47794
- }
47795
- function S3(t2) {
47796
- if (typeof t2 != "string") throw new TypeError(`Expected a \`string\`, got \`${typeof t2}\``);
47797
- return t2.replace(q3(), "");
47798
- }
47799
- function j2(t2) {
47800
- return t2 && t2.__esModule && Object.prototype.hasOwnProperty.call(t2, "default") ? t2.default : t2;
47801
- }
47802
- var M3 = { exports: {} };
47803
- (function(t2) {
47804
- var u3 = {};
47805
- t2.exports = u3, u3.eastAsianWidth = function(e3) {
47806
- var s2 = e3.charCodeAt(0), C5 = e3.length == 2 ? e3.charCodeAt(1) : 0, D5 = s2;
47807
- return 55296 <= s2 && s2 <= 56319 && 56320 <= C5 && C5 <= 57343 && (s2 &= 1023, C5 &= 1023, D5 = s2 << 10 | C5, D5 += 65536), D5 == 12288 || 65281 <= D5 && D5 <= 65376 || 65504 <= D5 && D5 <= 65510 ? "F" : D5 == 8361 || 65377 <= D5 && D5 <= 65470 || 65474 <= D5 && D5 <= 65479 || 65482 <= D5 && D5 <= 65487 || 65490 <= D5 && D5 <= 65495 || 65498 <= D5 && D5 <= 65500 || 65512 <= D5 && D5 <= 65518 ? "H" : 4352 <= D5 && D5 <= 4447 || 4515 <= D5 && D5 <= 4519 || 4602 <= D5 && D5 <= 4607 || 9001 <= D5 && D5 <= 9002 || 11904 <= D5 && D5 <= 11929 || 11931 <= D5 && D5 <= 12019 || 12032 <= D5 && D5 <= 12245 || 12272 <= D5 && D5 <= 12283 || 12289 <= D5 && D5 <= 12350 || 12353 <= D5 && D5 <= 12438 || 12441 <= D5 && D5 <= 12543 || 12549 <= D5 && D5 <= 12589 || 12593 <= D5 && D5 <= 12686 || 12688 <= D5 && D5 <= 12730 || 12736 <= D5 && D5 <= 12771 || 12784 <= D5 && D5 <= 12830 || 12832 <= D5 && D5 <= 12871 || 12880 <= D5 && D5 <= 13054 || 13056 <= D5 && D5 <= 19903 || 19968 <= D5 && D5 <= 42124 || 42128 <= D5 && D5 <= 42182 || 43360 <= D5 && D5 <= 43388 || 44032 <= D5 && D5 <= 55203 || 55216 <= D5 && D5 <= 55238 || 55243 <= D5 && D5 <= 55291 || 63744 <= D5 && D5 <= 64255 || 65040 <= D5 && D5 <= 65049 || 65072 <= D5 && D5 <= 65106 || 65108 <= D5 && D5 <= 65126 || 65128 <= D5 && D5 <= 65131 || 110592 <= D5 && D5 <= 110593 || 127488 <= D5 && D5 <= 127490 || 127504 <= D5 && D5 <= 127546 || 127552 <= D5 && D5 <= 127560 || 127568 <= D5 && D5 <= 127569 || 131072 <= D5 && D5 <= 194367 || 177984 <= D5 && D5 <= 196605 || 196608 <= D5 && D5 <= 262141 ? "W" : 32 <= D5 && D5 <= 126 || 162 <= D5 && D5 <= 163 || 165 <= D5 && D5 <= 166 || D5 == 172 || D5 == 175 || 10214 <= D5 && D5 <= 10221 || 10629 <= D5 && D5 <= 10630 ? "Na" : D5 == 161 || D5 == 164 || 167 <= D5 && D5 <= 168 || D5 == 170 || 173 <= D5 && D5 <= 174 || 176 <= D5 && D5 <= 180 || 182 <= D5 && D5 <= 186 || 188 <= D5 && D5 <= 191 || D5 == 198 || D5 == 208 || 215 <= D5 && D5 <= 216 || 222 <= D5 && D5 <= 225 || D5 == 230 || 232 <= D5 && D5 <= 234 || 236 <= D5 && D5 <= 237 || D5 == 240 || 242 <= D5 && D5 <= 243 || 247 <= D5 && D5 <= 250 || D5 == 252 || D5 == 254 || D5 == 257 || D5 == 273 || D5 == 275 || D5 == 283 || 294 <= D5 && D5 <= 295 || D5 == 299 || 305 <= D5 && D5 <= 307 || D5 == 312 || 319 <= D5 && D5 <= 322 || D5 == 324 || 328 <= D5 && D5 <= 331 || D5 == 333 || 338 <= D5 && D5 <= 339 || 358 <= D5 && D5 <= 359 || D5 == 363 || D5 == 462 || D5 == 464 || D5 == 466 || D5 == 468 || D5 == 470 || D5 == 472 || D5 == 474 || D5 == 476 || D5 == 593 || D5 == 609 || D5 == 708 || D5 == 711 || 713 <= D5 && D5 <= 715 || D5 == 717 || D5 == 720 || 728 <= D5 && D5 <= 731 || D5 == 733 || D5 == 735 || 768 <= D5 && D5 <= 879 || 913 <= D5 && D5 <= 929 || 931 <= D5 && D5 <= 937 || 945 <= D5 && D5 <= 961 || 963 <= D5 && D5 <= 969 || D5 == 1025 || 1040 <= D5 && D5 <= 1103 || D5 == 1105 || D5 == 8208 || 8211 <= D5 && D5 <= 8214 || 8216 <= D5 && D5 <= 8217 || 8220 <= D5 && D5 <= 8221 || 8224 <= D5 && D5 <= 8226 || 8228 <= D5 && D5 <= 8231 || D5 == 8240 || 8242 <= D5 && D5 <= 8243 || D5 == 8245 || D5 == 8251 || D5 == 8254 || D5 == 8308 || D5 == 8319 || 8321 <= D5 && D5 <= 8324 || D5 == 8364 || D5 == 8451 || D5 == 8453 || D5 == 8457 || D5 == 8467 || D5 == 8470 || 8481 <= D5 && D5 <= 8482 || D5 == 8486 || D5 == 8491 || 8531 <= D5 && D5 <= 8532 || 8539 <= D5 && D5 <= 8542 || 8544 <= D5 && D5 <= 8555 || 8560 <= D5 && D5 <= 8569 || D5 == 8585 || 8592 <= D5 && D5 <= 8601 || 8632 <= D5 && D5 <= 8633 || D5 == 8658 || D5 == 8660 || D5 == 8679 || D5 == 8704 || 8706 <= D5 && D5 <= 8707 || 8711 <= D5 && D5 <= 8712 || D5 == 8715 || D5 == 8719 || D5 == 8721 || D5 == 8725 || D5 == 8730 || 8733 <= D5 && D5 <= 8736 || D5 == 8739 || D5 == 8741 || 8743 <= D5 && D5 <= 8748 || D5 == 8750 || 8756 <= D5 && D5 <= 8759 || 8764 <= D5 && D5 <= 8765 || D5 == 8776 || D5 == 8780 || D5 == 8786 || 8800 <= D5 && D5 <= 8801 || 8804 <= D5 && D5 <= 8807 || 8810 <= D5 && D5 <= 8811 || 8814 <= D5 && D5 <= 8815 || 8834 <= D5 && D5 <= 8835 || 8838 <= D5 && D5 <= 8839 || D5 == 8853 || D5 == 8857 || D5 == 8869 || D5 == 8895 || D5 == 8978 || 9312 <= D5 && D5 <= 9449 || 9451 <= D5 && D5 <= 9547 || 9552 <= D5 && D5 <= 9587 || 9600 <= D5 && D5 <= 9615 || 9618 <= D5 && D5 <= 9621 || 9632 <= D5 && D5 <= 9633 || 9635 <= D5 && D5 <= 9641 || 9650 <= D5 && D5 <= 9651 || 9654 <= D5 && D5 <= 9655 || 9660 <= D5 && D5 <= 9661 || 9664 <= D5 && D5 <= 9665 || 9670 <= D5 && D5 <= 9672 || D5 == 9675 || 9678 <= D5 && D5 <= 9681 || 9698 <= D5 && D5 <= 9701 || D5 == 9711 || 9733 <= D5 && D5 <= 9734 || D5 == 9737 || 9742 <= D5 && D5 <= 9743 || 9748 <= D5 && D5 <= 9749 || D5 == 9756 || D5 == 9758 || D5 == 9792 || D5 == 9794 || 9824 <= D5 && D5 <= 9825 || 9827 <= D5 && D5 <= 9829 || 9831 <= D5 && D5 <= 9834 || 9836 <= D5 && D5 <= 9837 || D5 == 9839 || 9886 <= D5 && D5 <= 9887 || 9918 <= D5 && D5 <= 9919 || 9924 <= D5 && D5 <= 9933 || 9935 <= D5 && D5 <= 9953 || D5 == 9955 || 9960 <= D5 && D5 <= 9983 || D5 == 10045 || D5 == 10071 || 10102 <= D5 && D5 <= 10111 || 11093 <= D5 && D5 <= 11097 || 12872 <= D5 && D5 <= 12879 || 57344 <= D5 && D5 <= 63743 || 65024 <= D5 && D5 <= 65039 || D5 == 65533 || 127232 <= D5 && D5 <= 127242 || 127248 <= D5 && D5 <= 127277 || 127280 <= D5 && D5 <= 127337 || 127344 <= D5 && D5 <= 127386 || 917760 <= D5 && D5 <= 917999 || 983040 <= D5 && D5 <= 1048573 || 1048576 <= D5 && D5 <= 1114109 ? "A" : "N";
47808
- }, u3.characterLength = function(e3) {
47809
- var s2 = this.eastAsianWidth(e3);
47810
- return s2 == "F" || s2 == "W" || s2 == "A" ? 2 : 1;
47811
- };
47812
- function F5(e3) {
47813
- return e3.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g) || [];
47814
- }
47815
- u3.length = function(e3) {
47816
- for (var s2 = F5(e3), C5 = 0, D5 = 0; D5 < s2.length; D5++) C5 = C5 + this.characterLength(s2[D5]);
47817
- return C5;
47818
- }, u3.slice = function(e3, s2, C5) {
47819
- textLen = u3.length(e3), s2 = s2 || 0, C5 = C5 || 1, s2 < 0 && (s2 = textLen + s2), C5 < 0 && (C5 = textLen + C5);
47820
- for (var D5 = "", i3 = 0, n2 = F5(e3), E4 = 0; E4 < n2.length; E4++) {
47821
- var h4 = n2[E4], o3 = u3.length(h4);
47822
- if (i3 >= s2 - (o3 == 2 ? 1 : 0)) if (i3 + o3 <= C5) D5 += h4;
47823
- else break;
47824
- i3 += o3;
47825
- }
47826
- return D5;
47827
- };
47828
- })(M3);
47829
- var J3 = M3.exports;
47830
- var Q2 = j2(J3);
47831
- var X2 = function() {
47832
- return /\uD83C\uDFF4\uDB40\uDC67\uDB40\uDC62(?:\uDB40\uDC77\uDB40\uDC6C\uDB40\uDC73|\uDB40\uDC73\uDB40\uDC63\uDB40\uDC74|\uDB40\uDC65\uDB40\uDC6E\uDB40\uDC67)\uDB40\uDC7F|(?:\uD83E\uDDD1\uD83C\uDFFF\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFF\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFE])|(?:\uD83E\uDDD1\uD83C\uDFFE\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFE\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFD\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFD\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFC\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFC\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|(?:\uD83E\uDDD1\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1|\uD83D\uDC69\uD83C\uDFFB\u200D\uD83E\uDD1D\u200D(?:\uD83D[\uDC68\uDC69]))(?:\uD83C[\uDFFC-\uDFFF])|\uD83D\uDC68(?:\uD83C\uDFFB(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFC-\uDFFF])|[\u2695\u2696\u2708]\uFE0F|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))?|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFF]))|\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D)?\uD83D\uDC68|(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFE])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83E\uDD1D\u200D\uD83D\uDC68(?:\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])\uFE0F|\u200D(?:(?:\uD83D[\uDC68\uDC69])\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D[\uDC66\uDC67])|\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC)?|(?:\uD83D\uDC69(?:\uD83C\uDFFB\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|(?:\uD83C[\uDFFC-\uDFFF])\u200D\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69]))|\uD83E\uDDD1(?:\uD83C[\uDFFB-\uDFFF])\u200D\uD83E\uDD1D\u200D\uD83E\uDDD1)(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67]))|\uD83D\uDC69(?:\u200D(?:\u2764\uFE0F\u200D(?:\uD83D\uDC8B\u200D(?:\uD83D[\uDC68\uDC69])|\uD83D[\uDC68\uDC69])|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83E\uDDD1(?:\u200D(?:\uD83E\uDD1D\u200D\uD83E\uDDD1|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFF\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFE\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFD\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFC\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD])|\uD83C\uDFFB\u200D(?:\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E[\uDDAF-\uDDB3\uDDBC\uDDBD]))|\uD83D\uDC69\u200D\uD83D\uDC66\u200D\uD83D\uDC66|\uD83D\uDC69\u200D\uD83D\uDC69\u200D(?:\uD83D[\uDC66\uDC67])|\uD83D\uDC69\u200D\uD83D\uDC67\u200D(?:\uD83D[\uDC66\uDC67])|(?:\uD83D\uDC41\uFE0F\u200D\uD83D\uDDE8|\uD83E\uDDD1(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDC69(?:\uD83C\uDFFF\u200D[\u2695\u2696\u2708]|\uD83C\uDFFE\u200D[\u2695\u2696\u2708]|\uD83C\uDFFD\u200D[\u2695\u2696\u2708]|\uD83C\uDFFC\u200D[\u2695\u2696\u2708]|\uD83C\uDFFB\u200D[\u2695\u2696\u2708]|\u200D[\u2695\u2696\u2708])|\uD83D\uDE36\u200D\uD83C\uDF2B|\uD83C\uDFF3\uFE0F\u200D\u26A7|\uD83D\uDC3B\u200D\u2744|(?:(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF])\u200D[\u2640\u2642]|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])\u200D[\u2640\u2642]|\uD83C\uDFF4\u200D\u2620|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])\u200D[\u2640\u2642]|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u2600-\u2604\u260E\u2611\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26B0\u26B1\u26C8\u26CF\u26D1\u26D3\u26E9\u26F0\u26F1\u26F4\u26F7\u26F8\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u3030\u303D\u3297\u3299]|\uD83C[\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]|\uD83D[\uDC3F\uDCFD\uDD49\uDD4A\uDD6F\uDD70\uDD73\uDD76-\uDD79\uDD87\uDD8A-\uDD8D\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA\uDECB\uDECD-\uDECF\uDEE0-\uDEE5\uDEE9\uDEF0\uDEF3])\uFE0F|\uD83C\uDFF3\uFE0F\u200D\uD83C\uDF08|\uD83D\uDC69\u200D\uD83D\uDC67|\uD83D\uDC69\u200D\uD83D\uDC66|\uD83D\uDE35\u200D\uD83D\uDCAB|\uD83D\uDE2E\u200D\uD83D\uDCA8|\uD83D\uDC15\u200D\uD83E\uDDBA|\uD83E\uDDD1(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83D\uDC69(?:\uD83C\uDFFF|\uD83C\uDFFE|\uD83C\uDFFD|\uD83C\uDFFC|\uD83C\uDFFB)?|\uD83C\uDDFD\uD83C\uDDF0|\uD83C\uDDF6\uD83C\uDDE6|\uD83C\uDDF4\uD83C\uDDF2|\uD83D\uDC08\u200D\u2B1B|\u2764\uFE0F\u200D(?:\uD83D\uDD25|\uD83E\uDE79)|\uD83D\uDC41\uFE0F|\uD83C\uDFF3\uFE0F|\uD83C\uDDFF(?:\uD83C[\uDDE6\uDDF2\uDDFC])|\uD83C\uDDFE(?:\uD83C[\uDDEA\uDDF9])|\uD83C\uDDFC(?:\uD83C[\uDDEB\uDDF8])|\uD83C\uDDFB(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA])|\uD83C\uDDFA(?:\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF])|\uD83C\uDDF9(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF])|\uD83C\uDDF8(?:\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF])|\uD83C\uDDF7(?:\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC])|\uD83C\uDDF5(?:\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE])|\uD83C\uDDF3(?:\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF])|\uD83C\uDDF2(?:\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF])|\uD83C\uDDF1(?:\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE])|\uD83C\uDDF0(?:\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF])|\uD83C\uDDEF(?:\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5])|\uD83C\uDDEE(?:\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9])|\uD83C\uDDED(?:\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA])|\uD83C\uDDEC(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE])|\uD83C\uDDEB(?:\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7])|\uD83C\uDDEA(?:\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA])|\uD83C\uDDE9(?:\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF])|\uD83C\uDDE8(?:\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF5\uDDF7\uDDFA-\uDDFF])|\uD83C\uDDE7(?:\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF])|\uD83C\uDDE6(?:\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF])|[#\*0-9]\uFE0F\u20E3|\u2764\uFE0F|(?:\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD])(?:\uD83C[\uDFFB-\uDFFF])|(?:\u26F9|\uD83C[\uDFCB\uDFCC]|\uD83D\uDD75)(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|\uD83C\uDFF4|(?:[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5])(?:\uD83C[\uDFFB-\uDFFF])|(?:[\u261D\u270C\u270D]|\uD83D[\uDD74\uDD90])(?:\uFE0F|\uD83C[\uDFFB-\uDFFF])|[\u270A\u270B]|\uD83C[\uDF85\uDFC2\uDFC7]|\uD83D[\uDC08\uDC15\uDC3B\uDC42\uDC43\uDC46-\uDC50\uDC66\uDC67\uDC6B-\uDC6D\uDC72\uDC74-\uDC76\uDC78\uDC7C\uDC83\uDC85\uDC8F\uDC91\uDCAA\uDD7A\uDD95\uDD96\uDE2E\uDE35\uDE36\uDE4C\uDE4F\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1C\uDD1E\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5]|\uD83C[\uDFC3\uDFC4\uDFCA]|\uD83D[\uDC6E\uDC70\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4-\uDEB6]|\uD83E[\uDD26\uDD35\uDD37-\uDD39\uDD3D\uDD3E\uDDB8\uDDB9\uDDCD-\uDDCF\uDDD4\uDDD6-\uDDDD]|\uD83D\uDC6F|\uD83E[\uDD3C\uDDDE\uDDDF]|[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC3A\uDC3C-\uDC3E\uDC40\uDC44\uDC45\uDC51-\uDC65\uDC6A\uDC79-\uDC7B\uDC7D-\uDC80\uDC84\uDC88-\uDC8E\uDC90\uDC92-\uDCA9\uDCAB-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDDA4\uDDFB-\uDE2D\uDE2F-\uDE34\uDE37-\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0D\uDD0E\uDD10-\uDD17\uDD1D\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78\uDD7A-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCB\uDDD0\uDDE0-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6]|(?:[\u231A\u231B\u23E9-\u23EC\u23F0\u23F3\u25FD\u25FE\u2614\u2615\u2648-\u2653\u267F\u2693\u26A1\u26AA\u26AB\u26BD\u26BE\u26C4\u26C5\u26CE\u26D4\u26EA\u26F2\u26F3\u26F5\u26FA\u26FD\u2705\u270A\u270B\u2728\u274C\u274E\u2753-\u2755\u2757\u2795-\u2797\u27B0\u27BF\u2B1B\u2B1C\u2B50\u2B55]|\uD83C[\uDC04\uDCCF\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF7C\uDF7E-\uDF93\uDFA0-\uDFCA\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF4\uDFF8-\uDFFF]|\uD83D[\uDC00-\uDC3E\uDC40\uDC42-\uDCFC\uDCFF-\uDD3D\uDD4B-\uDD4E\uDD50-\uDD67\uDD7A\uDD95\uDD96\uDDA4\uDDFB-\uDE4F\uDE80-\uDEC5\uDECC\uDED0-\uDED2\uDED5-\uDED7\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])|(?:[#\*0-9\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23E9-\u23F3\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB-\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u261D\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692-\u2697\u2699\u269B\u269C\u26A0\u26A1\u26A7\u26AA\u26AB\u26B0\u26B1\u26BD\u26BE\u26C4\u26C5\u26C8\u26CE\u26CF\u26D1\u26D3\u26D4\u26E9\u26EA\u26F0-\u26F5\u26F7-\u26FA\u26FD\u2702\u2705\u2708-\u270D\u270F\u2712\u2714\u2716\u271D\u2721\u2728\u2733\u2734\u2744\u2747\u274C\u274E\u2753-\u2755\u2757\u2763\u2764\u2795-\u2797\u27A1\u27B0\u27BF\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B50\u2B55\u3030\u303D\u3297\u3299]|\uD83C[\uDC04\uDCCF\uDD70\uDD71\uDD7E\uDD7F\uDD8E\uDD91-\uDD9A\uDDE6-\uDDFF\uDE01\uDE02\uDE1A\uDE2F\uDE32-\uDE3A\uDE50\uDE51\uDF00-\uDF21\uDF24-\uDF93\uDF96\uDF97\uDF99-\uDF9B\uDF9E-\uDFF0\uDFF3-\uDFF5\uDFF7-\uDFFF]|\uD83D[\uDC00-\uDCFD\uDCFF-\uDD3D\uDD49-\uDD4E\uDD50-\uDD67\uDD6F\uDD70\uDD73-\uDD7A\uDD87\uDD8A-\uDD8D\uDD90\uDD95\uDD96\uDDA4\uDDA5\uDDA8\uDDB1\uDDB2\uDDBC\uDDC2-\uDDC4\uDDD1-\uDDD3\uDDDC-\uDDDE\uDDE1\uDDE3\uDDE8\uDDEF\uDDF3\uDDFA-\uDE4F\uDE80-\uDEC5\uDECB-\uDED2\uDED5-\uDED7\uDEE0-\uDEE5\uDEE9\uDEEB\uDEEC\uDEF0\uDEF3-\uDEFC\uDFE0-\uDFEB]|\uD83E[\uDD0C-\uDD3A\uDD3C-\uDD45\uDD47-\uDD78\uDD7A-\uDDCB\uDDCD-\uDDFF\uDE70-\uDE74\uDE78-\uDE7A\uDE80-\uDE86\uDE90-\uDEA8\uDEB0-\uDEB6\uDEC0-\uDEC2\uDED0-\uDED6])\uFE0F|(?:[\u261D\u26F9\u270A-\u270D]|\uD83C[\uDF85\uDFC2-\uDFC4\uDFC7\uDFCA-\uDFCC]|\uD83D[\uDC42\uDC43\uDC46-\uDC50\uDC66-\uDC78\uDC7C\uDC81-\uDC83\uDC85-\uDC87\uDC8F\uDC91\uDCAA\uDD74\uDD75\uDD7A\uDD90\uDD95\uDD96\uDE45-\uDE47\uDE4B-\uDE4F\uDEA3\uDEB4-\uDEB6\uDEC0\uDECC]|\uD83E[\uDD0C\uDD0F\uDD18-\uDD1F\uDD26\uDD30-\uDD39\uDD3C-\uDD3E\uDD77\uDDB5\uDDB6\uDDB8\uDDB9\uDDBB\uDDCD-\uDDCF\uDDD1-\uDDDD])/g;
47833
- };
47834
- var DD2 = j2(X2);
47835
- function A2(t2, u3 = {}) {
47836
- if (typeof t2 != "string" || t2.length === 0 || (u3 = { ambiguousIsNarrow: true, ...u3 }, t2 = S3(t2), t2.length === 0)) return 0;
47837
- t2 = t2.replace(DD2(), " ");
47838
- const F5 = u3.ambiguousIsNarrow ? 1 : 2;
47839
- let e3 = 0;
47840
- for (const s2 of t2) {
47841
- const C5 = s2.codePointAt(0);
47842
- if (C5 <= 31 || C5 >= 127 && C5 <= 159 || C5 >= 768 && C5 <= 879) continue;
47843
- switch (Q2.eastAsianWidth(s2)) {
47844
- case "F":
47845
- case "W":
47846
- e3 += 2;
47847
- break;
47848
- case "A":
47849
- e3 += F5;
47850
- break;
47851
- default:
47852
- e3 += 1;
47853
- }
47854
- }
47855
- return e3;
47856
- }
47857
- var m3 = 10;
47858
- var T4 = (t2 = 0) => (u3) => `\x1B[${u3 + t2}m`;
47859
- var P2 = (t2 = 0) => (u3) => `\x1B[${38 + t2};5;${u3}m`;
47860
- var W3 = (t2 = 0) => (u3, F5, e3) => `\x1B[${38 + t2};2;${u3};${F5};${e3}m`;
47861
- var r = { modifier: { reset: [0, 0], bold: [1, 22], dim: [2, 22], italic: [3, 23], underline: [4, 24], overline: [53, 55], inverse: [7, 27], hidden: [8, 28], strikethrough: [9, 29] }, color: { black: [30, 39], red: [31, 39], green: [32, 39], yellow: [33, 39], blue: [34, 39], magenta: [35, 39], cyan: [36, 39], white: [37, 39], blackBright: [90, 39], gray: [90, 39], grey: [90, 39], redBright: [91, 39], greenBright: [92, 39], yellowBright: [93, 39], blueBright: [94, 39], magentaBright: [95, 39], cyanBright: [96, 39], whiteBright: [97, 39] }, bgColor: { bgBlack: [40, 49], bgRed: [41, 49], bgGreen: [42, 49], bgYellow: [43, 49], bgBlue: [44, 49], bgMagenta: [45, 49], bgCyan: [46, 49], bgWhite: [47, 49], bgBlackBright: [100, 49], bgGray: [100, 49], bgGrey: [100, 49], bgRedBright: [101, 49], bgGreenBright: [102, 49], bgYellowBright: [103, 49], bgBlueBright: [104, 49], bgMagentaBright: [105, 49], bgCyanBright: [106, 49], bgWhiteBright: [107, 49] } };
47862
- Object.keys(r.modifier);
47863
- var uD2 = Object.keys(r.color);
47864
- var FD2 = Object.keys(r.bgColor);
47865
- [...uD2, ...FD2];
47866
- function tD2() {
47867
- const t2 = /* @__PURE__ */ new Map();
47868
- for (const [u3, F5] of Object.entries(r)) {
47869
- for (const [e3, s2] of Object.entries(F5)) r[e3] = { open: `\x1B[${s2[0]}m`, close: `\x1B[${s2[1]}m` }, F5[e3] = r[e3], t2.set(s2[0], s2[1]);
47870
- Object.defineProperty(r, u3, { value: F5, enumerable: false });
47871
- }
47872
- return Object.defineProperty(r, "codes", { value: t2, enumerable: false }), r.color.close = "\x1B[39m", r.bgColor.close = "\x1B[49m", r.color.ansi = T4(), r.color.ansi256 = P2(), r.color.ansi16m = W3(), r.bgColor.ansi = T4(m3), r.bgColor.ansi256 = P2(m3), r.bgColor.ansi16m = W3(m3), Object.defineProperties(r, { rgbToAnsi256: { value: (u3, F5, e3) => u3 === F5 && F5 === e3 ? u3 < 8 ? 16 : u3 > 248 ? 231 : Math.round((u3 - 8) / 247 * 24) + 232 : 16 + 36 * Math.round(u3 / 255 * 5) + 6 * Math.round(F5 / 255 * 5) + Math.round(e3 / 255 * 5), enumerable: false }, hexToRgb: { value: (u3) => {
47873
- const F5 = /[a-f\d]{6}|[a-f\d]{3}/i.exec(u3.toString(16));
47874
- if (!F5) return [0, 0, 0];
47875
- let [e3] = F5;
47876
- e3.length === 3 && (e3 = [...e3].map((C5) => C5 + C5).join(""));
47877
- const s2 = Number.parseInt(e3, 16);
47878
- return [s2 >> 16 & 255, s2 >> 8 & 255, s2 & 255];
47879
- }, enumerable: false }, hexToAnsi256: { value: (u3) => r.rgbToAnsi256(...r.hexToRgb(u3)), enumerable: false }, ansi256ToAnsi: { value: (u3) => {
47880
- if (u3 < 8) return 30 + u3;
47881
- if (u3 < 16) return 90 + (u3 - 8);
47882
- let F5, e3, s2;
47883
- if (u3 >= 232) F5 = ((u3 - 232) * 10 + 8) / 255, e3 = F5, s2 = F5;
47884
- else {
47885
- u3 -= 16;
47886
- const i3 = u3 % 36;
47887
- F5 = Math.floor(u3 / 36) / 5, e3 = Math.floor(i3 / 6) / 5, s2 = i3 % 6 / 5;
47888
- }
47889
- const C5 = Math.max(F5, e3, s2) * 2;
47890
- if (C5 === 0) return 30;
47891
- let D5 = 30 + (Math.round(s2) << 2 | Math.round(e3) << 1 | Math.round(F5));
47892
- return C5 === 2 && (D5 += 60), D5;
47893
- }, enumerable: false }, rgbToAnsi: { value: (u3, F5, e3) => r.ansi256ToAnsi(r.rgbToAnsi256(u3, F5, e3)), enumerable: false }, hexToAnsi: { value: (u3) => r.ansi256ToAnsi(r.hexToAnsi256(u3)), enumerable: false } }), r;
47894
- }
47895
- var eD2 = tD2();
47896
- var g2 = /* @__PURE__ */ new Set(["\x1B", "\x9B"]);
47897
- var sD2 = 39;
47898
- var b4 = "\x07";
47899
- var O3 = "[";
47900
- var CD2 = "]";
47901
- var I3 = "m";
47902
- var w4 = `${CD2}8;;`;
47903
- var N3 = (t2) => `${g2.values().next().value}${O3}${t2}${I3}`;
47904
- var L4 = (t2) => `${g2.values().next().value}${w4}${t2}${b4}`;
47905
- var iD2 = (t2) => t2.split(" ").map((u3) => A2(u3));
47906
- var y3 = (t2, u3, F5) => {
47907
- const e3 = [...u3];
47908
- let s2 = false, C5 = false, D5 = A2(S3(t2[t2.length - 1]));
47909
- for (const [i3, n2] of e3.entries()) {
47910
- const E4 = A2(n2);
47911
- if (D5 + E4 <= F5 ? t2[t2.length - 1] += n2 : (t2.push(n2), D5 = 0), g2.has(n2) && (s2 = true, C5 = e3.slice(i3 + 1).join("").startsWith(w4)), s2) {
47912
- C5 ? n2 === b4 && (s2 = false, C5 = false) : n2 === I3 && (s2 = false);
47913
- continue;
47914
- }
47915
- D5 += E4, D5 === F5 && i3 < e3.length - 1 && (t2.push(""), D5 = 0);
47916
- }
47917
- !D5 && t2[t2.length - 1].length > 0 && t2.length > 1 && (t2[t2.length - 2] += t2.pop());
47918
- };
47919
- var rD2 = (t2) => {
47920
- const u3 = t2.split(" ");
47921
- let F5 = u3.length;
47922
- for (; F5 > 0 && !(A2(u3[F5 - 1]) > 0); ) F5--;
47923
- return F5 === u3.length ? t2 : u3.slice(0, F5).join(" ") + u3.slice(F5).join("");
47924
- };
47925
- var ED2 = (t2, u3, F5 = {}) => {
47926
- if (F5.trim !== false && t2.trim() === "") return "";
47927
- let e3 = "", s2, C5;
47928
- const D5 = iD2(t2);
47929
- let i3 = [""];
47930
- for (const [E4, h4] of t2.split(" ").entries()) {
47931
- F5.trim !== false && (i3[i3.length - 1] = i3[i3.length - 1].trimStart());
47932
- let o3 = A2(i3[i3.length - 1]);
47933
- if (E4 !== 0 && (o3 >= u3 && (F5.wordWrap === false || F5.trim === false) && (i3.push(""), o3 = 0), (o3 > 0 || F5.trim === false) && (i3[i3.length - 1] += " ", o3++)), F5.hard && D5[E4] > u3) {
47934
- const B3 = u3 - o3, p4 = 1 + Math.floor((D5[E4] - B3 - 1) / u3);
47935
- Math.floor((D5[E4] - 1) / u3) < p4 && i3.push(""), y3(i3, h4, u3);
47936
- continue;
47937
- }
47938
- if (o3 + D5[E4] > u3 && o3 > 0 && D5[E4] > 0) {
47939
- if (F5.wordWrap === false && o3 < u3) {
47940
- y3(i3, h4, u3);
47941
- continue;
47942
- }
47943
- i3.push("");
47944
- }
47945
- if (o3 + D5[E4] > u3 && F5.wordWrap === false) {
47946
- y3(i3, h4, u3);
47947
- continue;
47948
- }
47949
- i3[i3.length - 1] += h4;
47950
- }
47951
- F5.trim !== false && (i3 = i3.map((E4) => rD2(E4)));
47952
- const n2 = [...i3.join(`
47953
- `)];
47954
- for (const [E4, h4] of n2.entries()) {
47955
- if (e3 += h4, g2.has(h4)) {
47956
- const { groups: B3 } = new RegExp(`(?:\\${O3}(?<code>\\d+)m|\\${w4}(?<uri>.*)${b4})`).exec(n2.slice(E4).join("")) || { groups: {} };
47957
- if (B3.code !== void 0) {
47958
- const p4 = Number.parseFloat(B3.code);
47959
- s2 = p4 === sD2 ? void 0 : p4;
47960
- } else B3.uri !== void 0 && (C5 = B3.uri.length === 0 ? void 0 : B3.uri);
47961
- }
47962
- const o3 = eD2.codes.get(Number(s2));
47963
- n2[E4 + 1] === `
47964
- ` ? (C5 && (e3 += L4("")), s2 && o3 && (e3 += N3(o3))) : h4 === `
47965
- ` && (s2 && o3 && (e3 += N3(s2)), C5 && (e3 += L4(C5)));
47966
- }
47967
- return e3;
47968
- };
47969
- function R4(t2, u3, F5) {
47970
- return String(t2).normalize().replace(/\r\n/g, `
47971
- `).split(`
47972
- `).map((e3) => ED2(e3, u3, F5)).join(`
47973
- `);
47974
- }
47975
- var oD2 = Object.defineProperty;
47976
- var nD2 = (t2, u3, F5) => u3 in t2 ? oD2(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
47977
- var a = (t2, u3, F5) => (nD2(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
47978
- function aD2(t2, u3) {
47979
- if (t2 === u3) return;
47980
- const F5 = t2.split(`
47981
- `), e3 = u3.split(`
47982
- `), s2 = [];
47983
- for (let C5 = 0; C5 < Math.max(F5.length, e3.length); C5++) F5[C5] !== e3[C5] && s2.push(C5);
47984
- return s2;
47985
- }
47986
- var V4 = Symbol("clack:cancel");
47987
- function hD2(t2) {
47988
- return t2 === V4;
47989
- }
47990
- function v3(t2, u3) {
47991
- t2.isTTY && t2.setRawMode(u3);
47992
- }
47993
- var z3 = /* @__PURE__ */ new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"]]);
47994
- var lD2 = /* @__PURE__ */ new Set(["up", "down", "left", "right", "space", "enter"]);
47995
- var x3 = class {
47996
- constructor({ render: u3, input: F5 = import_node_process.stdin, output: e3 = import_node_process.stdout, ...s2 }, C5 = true) {
47997
- a(this, "input"), a(this, "output"), a(this, "rl"), a(this, "opts"), a(this, "_track", false), a(this, "_render"), a(this, "_cursor", 0), a(this, "state", "initial"), a(this, "value"), a(this, "error", ""), a(this, "subscribers", /* @__PURE__ */ new Map()), a(this, "_prevFrame", ""), this.opts = s2, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = u3.bind(this), this._track = C5, this.input = F5, this.output = e3;
47998
- }
47999
- prompt() {
48000
- const u3 = new import_node_tty.WriteStream(0);
48001
- return u3._write = (F5, e3, s2) => {
48002
- this._track && (this.value = this.rl.line.replace(/\t/g, ""), this._cursor = this.rl.cursor, this.emit("value", this.value)), s2();
48003
- }, this.input.pipe(u3), this.rl = import_node_readline.default.createInterface({ input: this.input, output: u3, tabSize: 2, prompt: "", escapeCodeTimeout: 50 }), import_node_readline.default.emitKeypressEvents(this.input, this.rl), this.rl.prompt(), this.opts.initialValue !== void 0 && this._track && this.rl.write(this.opts.initialValue), this.input.on("keypress", this.onKeypress), v3(this.input, true), this.output.on("resize", this.render), this.render(), new Promise((F5, e3) => {
48004
- this.once("submit", () => {
48005
- this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), v3(this.input, false), F5(this.value);
48006
- }), this.once("cancel", () => {
48007
- this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), v3(this.input, false), F5(V4);
48008
- });
48009
- });
48010
- }
48011
- on(u3, F5) {
48012
- const e3 = this.subscribers.get(u3) ?? [];
48013
- e3.push({ cb: F5 }), this.subscribers.set(u3, e3);
48014
- }
48015
- once(u3, F5) {
48016
- const e3 = this.subscribers.get(u3) ?? [];
48017
- e3.push({ cb: F5, once: true }), this.subscribers.set(u3, e3);
48018
- }
48019
- emit(u3, ...F5) {
48020
- const e3 = this.subscribers.get(u3) ?? [], s2 = [];
48021
- for (const C5 of e3) C5.cb(...F5), C5.once && s2.push(() => e3.splice(e3.indexOf(C5), 1));
48022
- for (const C5 of s2) C5();
48023
- }
48024
- unsubscribe() {
48025
- this.subscribers.clear();
48026
- }
48027
- onKeypress(u3, F5) {
48028
- if (this.state === "error" && (this.state = "active"), F5?.name && !this._track && z3.has(F5.name) && this.emit("cursor", z3.get(F5.name)), F5?.name && lD2.has(F5.name) && this.emit("cursor", F5.name), u3 && (u3.toLowerCase() === "y" || u3.toLowerCase() === "n") && this.emit("confirm", u3.toLowerCase() === "y"), u3 === " " && this.opts.placeholder && (this.value || (this.rl.write(this.opts.placeholder), this.emit("value", this.opts.placeholder))), u3 && this.emit("key", u3.toLowerCase()), F5?.name === "return") {
48029
- if (this.opts.validate) {
48030
- const e3 = this.opts.validate(this.value);
48031
- e3 && (this.error = e3, this.state = "error", this.rl.write(this.value));
48032
- }
48033
- this.state !== "error" && (this.state = "submit");
48034
- }
48035
- u3 === "" && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
48036
- }
48037
- close() {
48038
- this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
48039
- `), v3(this.input, false), this.rl.close(), this.emit(`${this.state}`, this.value), this.unsubscribe();
48040
- }
48041
- restoreCursor() {
48042
- const u3 = R4(this._prevFrame, process.stdout.columns, { hard: true }).split(`
48043
- `).length - 1;
48044
- this.output.write(import_sisteransi.cursor.move(-999, u3 * -1));
48045
- }
48046
- render() {
48047
- const u3 = R4(this._render(this) ?? "", process.stdout.columns, { hard: true });
48048
- if (u3 !== this._prevFrame) {
48049
- if (this.state === "initial") this.output.write(import_sisteransi.cursor.hide);
48050
- else {
48051
- const F5 = aD2(this._prevFrame, u3);
48052
- if (this.restoreCursor(), F5 && F5?.length === 1) {
48053
- const e3 = F5[0];
48054
- this.output.write(import_sisteransi.cursor.move(0, e3)), this.output.write(import_sisteransi.erase.lines(1));
48055
- const s2 = u3.split(`
48056
- `);
48057
- this.output.write(s2[e3]), this._prevFrame = u3, this.output.write(import_sisteransi.cursor.move(0, s2.length - e3 - 1));
48058
- return;
48059
- } else if (F5 && F5?.length > 1) {
48060
- const e3 = F5[0];
48061
- this.output.write(import_sisteransi.cursor.move(0, e3)), this.output.write(import_sisteransi.erase.down());
48062
- const s2 = u3.split(`
48063
- `).slice(e3);
48064
- this.output.write(s2.join(`
48065
- `)), this._prevFrame = u3;
48066
- return;
48067
- }
48068
- this.output.write(import_sisteransi.erase.down());
48069
- }
48070
- this.output.write(u3), this.state === "initial" && (this.state = "active"), this._prevFrame = u3;
48071
- }
48072
- }
48073
- };
48074
- var xD2 = class extends x3 {
48075
- get cursor() {
48076
- return this.value ? 0 : 1;
48077
- }
48078
- get _value() {
48079
- return this.cursor === 0;
48080
- }
48081
- constructor(u3) {
48082
- super(u3, false), this.value = !!u3.initialValue, this.on("value", () => {
48083
- this.value = this._value;
48084
- }), this.on("confirm", (F5) => {
48085
- this.output.write(import_sisteransi.cursor.move(0, -1)), this.value = F5, this.state = "submit", this.close();
48086
- }), this.on("cursor", () => {
48087
- this.value = !this.value;
48088
- });
48089
- }
48090
- };
48091
- var pD2 = Object.defineProperty;
48092
- var fD2 = (t2, u3, F5) => u3 in t2 ? pD2(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
48093
- var K3 = (t2, u3, F5) => (fD2(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
48094
- var gD2 = class extends x3 {
48095
- constructor(u3) {
48096
- super(u3, false), K3(this, "options"), K3(this, "cursor", 0), this.options = u3.options, this.value = [...u3.initialValues ?? []], this.cursor = Math.max(this.options.findIndex(({ value: F5 }) => F5 === u3.cursorAt), 0), this.on("key", (F5) => {
48097
- F5 === "a" && this.toggleAll();
48098
- }), this.on("cursor", (F5) => {
48099
- switch (F5) {
48100
- case "left":
48101
- case "up":
48102
- this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
48103
- break;
48104
- case "down":
48105
- case "right":
48106
- this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
48107
- break;
48108
- case "space":
48109
- this.toggleValue();
48110
- break;
48111
- }
48112
- });
48113
- }
48114
- get _value() {
48115
- return this.options[this.cursor].value;
48116
- }
48117
- toggleAll() {
48118
- const u3 = this.value.length === this.options.length;
48119
- this.value = u3 ? [] : this.options.map((F5) => F5.value);
48120
- }
48121
- toggleValue() {
48122
- const u3 = this.value.includes(this._value);
48123
- this.value = u3 ? this.value.filter((F5) => F5 !== this._value) : [...this.value, this._value];
48124
- }
48125
- };
48126
- var bD2 = Object.defineProperty;
48127
- var wD2 = (t2, u3, F5) => u3 in t2 ? bD2(t2, u3, { enumerable: true, configurable: true, writable: true, value: F5 }) : t2[u3] = F5;
48128
- var Z3 = (t2, u3, F5) => (wD2(t2, typeof u3 != "symbol" ? u3 + "" : u3, F5), F5);
48129
- var yD = class extends x3 {
48130
- constructor(u3) {
48131
- super(u3, false), Z3(this, "options"), Z3(this, "cursor", 0), this.options = u3.options, this.cursor = this.options.findIndex(({ value: F5 }) => F5 === u3.initialValue), this.cursor === -1 && (this.cursor = 0), this.changeValue(), this.on("cursor", (F5) => {
48132
- switch (F5) {
48133
- case "left":
48134
- case "up":
48135
- this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
48136
- break;
48137
- case "down":
48138
- case "right":
48139
- this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
48140
- break;
48141
- }
48142
- this.changeValue();
48143
- });
48144
- }
48145
- get _value() {
48146
- return this.options[this.cursor];
48147
- }
48148
- changeValue() {
48149
- this.value = this._value.value;
48150
- }
48151
- };
48152
- var PD = globalThis.process.platform.startsWith("win");
48153
- function WD({ input: t2 = import_node_process.stdin, output: u3 = import_node_process.stdout, overwrite: F5 = true, hideCursor: e3 = true } = {}) {
48154
- const s2 = f.createInterface({ input: t2, output: u3, prompt: "", tabSize: 1 });
48155
- f.emitKeypressEvents(t2, s2), t2.isTTY && t2.setRawMode(true);
48156
- const C5 = (D5, { name: i3 }) => {
48157
- if (String(D5) === "" && process.exit(0), !F5) return;
48158
- let n2 = i3 === "return" ? 0 : -1, E4 = i3 === "return" ? -1 : 0;
48159
- f.moveCursor(u3, n2, E4, () => {
48160
- f.clearLine(u3, 1, () => {
48161
- t2.once("keypress", C5);
48162
- });
48163
- });
48164
- };
48165
- return e3 && process.stdout.write(import_sisteransi.cursor.hide), t2.once("keypress", C5), () => {
48166
- t2.off("keypress", C5), e3 && process.stdout.write(import_sisteransi.cursor.show), t2.isTTY && !PD && t2.setRawMode(false), s2.terminal = false, s2.close();
48167
- };
48168
- }
48169
-
48170
- // node_modules/@clack/prompts/dist/index.mjs
48171
- var import_node_process2 = __toESM(require("node:process"), 1);
48172
- var import_picocolors = __toESM(require_picocolors(), 1);
48173
- var import_sisteransi2 = __toESM(require_src(), 1);
48174
- function N4() {
48175
- return import_node_process2.default.platform !== "win32" ? import_node_process2.default.env.TERM !== "linux" : Boolean(import_node_process2.default.env.CI) || Boolean(import_node_process2.default.env.WT_SESSION) || Boolean(import_node_process2.default.env.TERMINUS_SUBLIME) || import_node_process2.default.env.ConEmuTask === "{cmd::Cmder}" || import_node_process2.default.env.TERM_PROGRAM === "Terminus-Sublime" || import_node_process2.default.env.TERM_PROGRAM === "vscode" || import_node_process2.default.env.TERM === "xterm-256color" || import_node_process2.default.env.TERM === "alacritty" || import_node_process2.default.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
48176
- }
48177
- var p2 = N4();
48178
- var u = (r3, n2) => p2 ? r3 : n2;
48179
- var W4 = u("\u25C6", "*");
48180
- var D3 = u("\u25A0", "x");
48181
- var F3 = u("\u25B2", "x");
48182
- var f2 = u("\u25C7", "o");
48183
- var L5 = u("\u250C", "T");
48184
- var a2 = u("\u2502", "|");
48185
- var o = u("\u2514", "\u2014");
48186
- var w5 = u("\u25CF", ">");
48187
- var S4 = u("\u25CB", " ");
48188
- var _5 = u("\u25FB", "[\u2022]");
48189
- var y4 = u("\u25FC", "[+]");
48190
- var A3 = u("\u25FB", "[ ]");
48191
- var q4 = u("\u25AA", "\u2022");
48192
- var R5 = u("\u2500", "-");
48193
- var G4 = u("\u256E", "+");
48194
- var H3 = u("\u251C", "+");
48195
- var K4 = u("\u256F", "+");
48196
- var U5 = u("\u25CF", "\u2022");
48197
- var Z4 = u("\u25C6", "*");
48198
- var z4 = u("\u25B2", "!");
48199
- var X3 = u("\u25A0", "x");
48200
- var h2 = (r3) => {
48201
- switch (r3) {
48202
- case "initial":
48203
- case "active":
48204
- return import_picocolors.default.cyan(W4);
48205
- case "cancel":
48206
- return import_picocolors.default.red(D3);
48207
- case "error":
48208
- return import_picocolors.default.yellow(F3);
48209
- case "submit":
48210
- return import_picocolors.default.green(f2);
48211
- }
48212
- };
48213
- var Q3 = (r3) => {
48214
- const n2 = r3.active ?? "Yes", s2 = r3.inactive ?? "No";
48215
- return new xD2({ active: n2, inactive: s2, initialValue: r3.initialValue ?? true, render() {
48216
- const t2 = `${import_picocolors.default.gray(a2)}
48217
- ${h2(this.state)} ${r3.message}
48218
- `, i3 = this.value ? n2 : s2;
48219
- switch (this.state) {
48220
- case "submit":
48221
- return `${t2}${import_picocolors.default.gray(a2)} ${import_picocolors.default.dim(i3)}`;
48222
- case "cancel":
48223
- return `${t2}${import_picocolors.default.gray(a2)} ${import_picocolors.default.strikethrough(import_picocolors.default.dim(i3))}
48224
- ${import_picocolors.default.gray(a2)}`;
48225
- default:
48226
- return `${t2}${import_picocolors.default.cyan(a2)} ${this.value ? `${import_picocolors.default.green(w5)} ${n2}` : `${import_picocolors.default.dim(S4)} ${import_picocolors.default.dim(n2)}`} ${import_picocolors.default.dim("/")} ${this.value ? `${import_picocolors.default.dim(S4)} ${import_picocolors.default.dim(s2)}` : `${import_picocolors.default.green(w5)} ${s2}`}
48227
- ${import_picocolors.default.cyan(o)}
48228
- `;
48229
- }
48230
- } }).prompt();
48231
- };
48232
- var ee = (r3) => {
48233
- const n2 = (s2, t2) => {
48234
- const i3 = s2.label ?? String(s2.value);
48235
- return t2 === "active" ? `${import_picocolors.default.green(w5)} ${i3} ${s2.hint ? import_picocolors.default.dim(`(${s2.hint})`) : ""}` : t2 === "selected" ? `${import_picocolors.default.dim(i3)}` : t2 === "cancelled" ? `${import_picocolors.default.strikethrough(import_picocolors.default.dim(i3))}` : `${import_picocolors.default.dim(S4)} ${import_picocolors.default.dim(i3)}`;
48236
- };
48237
- return new yD({ options: r3.options, initialValue: r3.initialValue, render() {
48238
- const s2 = `${import_picocolors.default.gray(a2)}
48239
- ${h2(this.state)} ${r3.message}
48240
- `;
48241
- switch (this.state) {
48242
- case "submit":
48243
- return `${s2}${import_picocolors.default.gray(a2)} ${n2(this.options[this.cursor], "selected")}`;
48244
- case "cancel":
48245
- return `${s2}${import_picocolors.default.gray(a2)} ${n2(this.options[this.cursor], "cancelled")}
48246
- ${import_picocolors.default.gray(a2)}`;
48247
- default:
48248
- return `${s2}${import_picocolors.default.cyan(a2)} ${this.options.map((t2, i3) => n2(t2, i3 === this.cursor ? "active" : "inactive")).join(`
48249
- ${import_picocolors.default.cyan(a2)} `)}
48250
- ${import_picocolors.default.cyan(o)}
48251
- `;
48252
- }
48253
- } }).prompt();
48254
- };
48255
- var re = (r3) => {
48256
- const n2 = (s2, t2) => {
48257
- const i3 = s2.label ?? String(s2.value);
48258
- return t2 === "active" ? `${import_picocolors.default.cyan(_5)} ${i3} ${s2.hint ? import_picocolors.default.dim(`(${s2.hint})`) : ""}` : t2 === "selected" ? `${import_picocolors.default.green(y4)} ${import_picocolors.default.dim(i3)}` : t2 === "cancelled" ? `${import_picocolors.default.strikethrough(import_picocolors.default.dim(i3))}` : t2 === "active-selected" ? `${import_picocolors.default.green(y4)} ${i3} ${s2.hint ? import_picocolors.default.dim(`(${s2.hint})`) : ""}` : t2 === "submitted" ? `${import_picocolors.default.dim(i3)}` : `${import_picocolors.default.dim(A3)} ${import_picocolors.default.dim(i3)}`;
48259
- };
48260
- return new gD2({ options: r3.options, initialValues: r3.initialValues, required: r3.required ?? true, cursorAt: r3.cursorAt, validate(s2) {
48261
- if (this.required && s2.length === 0) return `Please select at least one option.
48262
- ${import_picocolors.default.reset(import_picocolors.default.dim(`Press ${import_picocolors.default.gray(import_picocolors.default.bgWhite(import_picocolors.default.inverse(" space ")))} to select, ${import_picocolors.default.gray(import_picocolors.default.bgWhite(import_picocolors.default.inverse(" enter ")))} to submit`))}`;
48263
- }, render() {
48264
- let s2 = `${import_picocolors.default.gray(a2)}
48265
- ${h2(this.state)} ${r3.message}
48266
- `;
48267
- switch (this.state) {
48268
- case "submit":
48269
- return `${s2}${import_picocolors.default.gray(a2)} ${this.options.filter(({ value: t2 }) => this.value.includes(t2)).map((t2) => n2(t2, "submitted")).join(import_picocolors.default.dim(", ")) || import_picocolors.default.dim("none")}`;
48270
- case "cancel": {
48271
- const t2 = this.options.filter(({ value: i3 }) => this.value.includes(i3)).map((i3) => n2(i3, "cancelled")).join(import_picocolors.default.dim(", "));
48272
- return `${s2}${import_picocolors.default.gray(a2)} ${t2.trim() ? `${t2}
48273
- ${import_picocolors.default.gray(a2)}` : ""}`;
48274
- }
48275
- case "error": {
48276
- const t2 = this.error.split(`
48277
- `).map((i3, c3) => c3 === 0 ? `${import_picocolors.default.yellow(o)} ${import_picocolors.default.yellow(i3)}` : ` ${i3}`).join(`
48278
- `);
48279
- return s2 + import_picocolors.default.yellow(a2) + " " + this.options.map((i3, c3) => {
48280
- const l3 = this.value.includes(i3.value), $6 = c3 === this.cursor;
48281
- return $6 && l3 ? n2(i3, "active-selected") : l3 ? n2(i3, "selected") : n2(i3, $6 ? "active" : "inactive");
48282
- }).join(`
48283
- ${import_picocolors.default.yellow(a2)} `) + `
48284
- ` + t2 + `
48285
- `;
48286
- }
48287
- default:
48288
- return `${s2}${import_picocolors.default.cyan(a2)} ${this.options.map((t2, i3) => {
48289
- const c3 = this.value.includes(t2.value), l3 = i3 === this.cursor;
48290
- return l3 && c3 ? n2(t2, "active-selected") : c3 ? n2(t2, "selected") : n2(t2, l3 ? "active" : "inactive");
48291
- }).join(`
48292
- ${import_picocolors.default.cyan(a2)} `)}
48293
- ${import_picocolors.default.cyan(o)}
48294
- `;
48295
- }
48296
- } }).prompt();
48297
- };
48298
- var b5 = (r3) => r3.replace(ue(), "");
48299
- var ie = (r3 = "", n2 = "") => {
48300
- const s2 = `
48301
- ${r3}
48302
- `.split(`
48303
- `), t2 = Math.max(s2.reduce((c3, l3) => (l3 = b5(l3), l3.length > c3 ? l3.length : c3), 0), b5(n2).length) + 2, i3 = s2.map((c3) => `${import_picocolors.default.gray(a2)} ${import_picocolors.default.dim(c3)}${" ".repeat(t2 - b5(c3).length)}${import_picocolors.default.gray(a2)}`).join(`
48304
- `);
48305
- process.stdout.write(`${import_picocolors.default.gray(a2)}
48306
- ${import_picocolors.default.green(f2)} ${import_picocolors.default.reset(n2)} ${import_picocolors.default.gray(R5.repeat(Math.max(t2 - n2.length - 1, 1)) + G4)}
48307
- ${i3}
48308
- ${import_picocolors.default.gray(H3 + R5.repeat(t2 + 2) + K4)}
48309
- `);
48310
- };
48311
- var ae = (r3 = "") => {
48312
- process.stdout.write(`${import_picocolors.default.gray(L5)} ${r3}
48313
- `);
48314
- };
48315
- var ce = (r3 = "") => {
48316
- process.stdout.write(`${import_picocolors.default.gray(a2)}
48317
- ${import_picocolors.default.gray(o)} ${r3}
48318
-
48319
- `);
48320
- };
48321
- var C3 = p2 ? ["\u25D2", "\u25D0", "\u25D3", "\u25D1"] : ["\u2022", "o", "O", "0"];
48322
- var le = () => {
48323
- let r3, n2;
48324
- const s2 = p2 ? 80 : 120;
48325
- return { start(t2 = "") {
48326
- t2 = t2.replace(/\.?\.?\.$/, ""), r3 = WD(), process.stdout.write(`${import_picocolors.default.gray(a2)}
48327
- ${import_picocolors.default.magenta("\u25CB")} ${t2}
48328
- `);
48329
- let i3 = 0, c3 = 0;
48330
- n2 = setInterval(() => {
48331
- let l3 = C3[i3];
48332
- process.stdout.write(import_sisteransi2.cursor.move(-999, -1)), process.stdout.write(`${import_picocolors.default.magenta(l3)} ${t2}${Math.floor(c3) >= 1 ? ".".repeat(Math.floor(c3)).slice(0, 3) : ""}
48333
- `), i3 = i3 === C3.length - 1 ? 0 : i3 + 1, c3 = c3 === C3.length ? 0 : c3 + 0.125;
48334
- }, s2);
48335
- }, stop(t2 = "") {
48336
- process.stdout.write(import_sisteransi2.cursor.move(-999, -2)), process.stdout.write(import_sisteransi2.erase.down(2)), clearInterval(n2), process.stdout.write(`${import_picocolors.default.gray(a2)}
48337
- ${import_picocolors.default.green(f2)} ${t2}
48338
- `), r3();
48339
- } };
48340
- };
48341
- function ue() {
48342
- const r3 = ["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?\\u0007)", "(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");
48343
- return new RegExp(r3, "g");
48344
- }
48623
+ // src/commands/commit.ts
48624
+ init_dist2();
48345
48625
 
48346
48626
  // node_modules/chalk/source/vendor/ansi-styles/index.js
48347
48627
  var ANSI_BACKGROUND_OFFSET = 10;
@@ -49974,7 +50254,11 @@ function create$(options) {
49974
50254
  }
49975
50255
  var $4 = create$();
49976
50256
 
50257
+ // src/generateCommitMessageFromGitDiff.ts
50258
+ init_dist2();
50259
+
49977
50260
  // src/commands/config.ts
50261
+ init_dist2();
49978
50262
  var dotenv = __toESM(require_main(), 1);
49979
50263
  var import_fs = require("fs");
49980
50264
  var import_ini = __toESM(require_ini(), 1);
@@ -50092,10 +50376,10 @@ var ja_default = {
50092
50376
  var ko_default = {
50093
50377
  localLanguage: "\uD55C\uAD6D\uC5B4",
50094
50378
  commitFix: "fix(server.ts): \uD3EC\uD2B8 \uBCC0\uC218\uB97C \uC18C\uBB38\uC790 port\uC5D0\uC11C \uB300\uBB38\uC790 PORT\uB85C \uBCC0\uACBD",
50095
- commitFeat: "\uD53C\uD2B8(server.ts): process.env.PORT \uD658\uACBD \uBCC0\uC218 \uC9C0\uC6D0 \uCD94\uAC00",
50379
+ commitFeat: "feat(server.ts): process.env.PORT \uD658\uACBD \uBCC0\uC218 \uC9C0\uC6D0 \uCD94\uAC00",
50096
50380
  commitDescription: "\uD3EC\uD2B8 \uBCC0\uC218\uB294 \uC774\uC81C PORT\uB85C \uC774\uB984\uC774 \uC9C0\uC815\uB418\uC5B4 \uC0C1\uC218\uC778 PORT\uC640 \uC77C\uAD00\uC131 \uC788\uB294 \uC774\uB984 \uADDC\uCE59\uC744 \uB530\uB985\uB2C8\uB2E4. \uD658\uACBD \uBCC0\uC218 \uC9C0\uC6D0\uC744 \uD1B5\uD574 \uC560\uD50C\uB9AC\uCF00\uC774\uC158\uC740 \uC774\uC81C process.env.PORT \uD658\uACBD \uBCC0\uC218\uB85C \uC9C0\uC815\uB41C \uC0AC\uC6A9 \uAC00\uB2A5\uD55C \uBAA8\uB4E0 \uD3EC\uD2B8\uC5D0\uC11C \uC2E4\uD589\uD560 \uC218 \uC788\uC73C\uBBC0\uB85C \uB354 \uC720\uC5F0\uD574\uC84C\uC2B5\uB2C8\uB2E4.",
50097
50381
  commitFixOmitScope: "fix: \uD3EC\uD2B8 \uBCC0\uC218\uB97C \uC18C\uBB38\uC790 port\uC5D0\uC11C \uB300\uBB38\uC790 PORT\uB85C \uBCC0\uACBD",
50098
- commitFeatOmitScope: "\uD53C\uD2B8: process.env.PORT \uD658\uACBD \uBCC0\uC218 \uC9C0\uC6D0 \uCD94\uAC00"
50382
+ commitFeatOmitScope: "feat: process.env.PORT \uD658\uACBD \uBCC0\uC218 \uC9C0\uC6D0 \uCD94\uAC00"
50099
50383
  };
50100
50384
 
50101
50385
  // src/i18n/nl.json
@@ -50252,25 +50536,26 @@ function getI18nLocal(value) {
50252
50536
  }
50253
50537
 
50254
50538
  // src/commands/config.ts
50255
- var CONFIG_KEYS = /* @__PURE__ */ ((CONFIG_KEYS2) => {
50256
- CONFIG_KEYS2["OCO_API_KEY"] = "OCO_API_KEY";
50257
- CONFIG_KEYS2["OCO_TOKENS_MAX_INPUT"] = "OCO_TOKENS_MAX_INPUT";
50258
- CONFIG_KEYS2["OCO_TOKENS_MAX_OUTPUT"] = "OCO_TOKENS_MAX_OUTPUT";
50259
- CONFIG_KEYS2["OCO_DESCRIPTION"] = "OCO_DESCRIPTION";
50260
- CONFIG_KEYS2["OCO_EMOJI"] = "OCO_EMOJI";
50261
- CONFIG_KEYS2["OCO_MODEL"] = "OCO_MODEL";
50262
- CONFIG_KEYS2["OCO_LANGUAGE"] = "OCO_LANGUAGE";
50263
- CONFIG_KEYS2["OCO_WHY"] = "OCO_WHY";
50264
- CONFIG_KEYS2["OCO_MESSAGE_TEMPLATE_PLACEHOLDER"] = "OCO_MESSAGE_TEMPLATE_PLACEHOLDER";
50265
- CONFIG_KEYS2["OCO_PROMPT_MODULE"] = "OCO_PROMPT_MODULE";
50266
- CONFIG_KEYS2["OCO_AI_PROVIDER"] = "OCO_AI_PROVIDER";
50267
- CONFIG_KEYS2["OCO_ONE_LINE_COMMIT"] = "OCO_ONE_LINE_COMMIT";
50268
- CONFIG_KEYS2["OCO_TEST_MOCK_TYPE"] = "OCO_TEST_MOCK_TYPE";
50269
- CONFIG_KEYS2["OCO_API_URL"] = "OCO_API_URL";
50270
- CONFIG_KEYS2["OCO_API_CUSTOM_HEADERS"] = "OCO_API_CUSTOM_HEADERS";
50271
- CONFIG_KEYS2["OCO_OMIT_SCOPE"] = "OCO_OMIT_SCOPE";
50272
- CONFIG_KEYS2["OCO_GITPUSH"] = "OCO_GITPUSH";
50273
- return CONFIG_KEYS2;
50539
+ var CONFIG_KEYS = /* @__PURE__ */ ((CONFIG_KEYS3) => {
50540
+ CONFIG_KEYS3["OCO_API_KEY"] = "OCO_API_KEY";
50541
+ CONFIG_KEYS3["OCO_TOKENS_MAX_INPUT"] = "OCO_TOKENS_MAX_INPUT";
50542
+ CONFIG_KEYS3["OCO_TOKENS_MAX_OUTPUT"] = "OCO_TOKENS_MAX_OUTPUT";
50543
+ CONFIG_KEYS3["OCO_DESCRIPTION"] = "OCO_DESCRIPTION";
50544
+ CONFIG_KEYS3["OCO_EMOJI"] = "OCO_EMOJI";
50545
+ CONFIG_KEYS3["OCO_MODEL"] = "OCO_MODEL";
50546
+ CONFIG_KEYS3["OCO_LANGUAGE"] = "OCO_LANGUAGE";
50547
+ CONFIG_KEYS3["OCO_WHY"] = "OCO_WHY";
50548
+ CONFIG_KEYS3["OCO_MESSAGE_TEMPLATE_PLACEHOLDER"] = "OCO_MESSAGE_TEMPLATE_PLACEHOLDER";
50549
+ CONFIG_KEYS3["OCO_PROMPT_MODULE"] = "OCO_PROMPT_MODULE";
50550
+ CONFIG_KEYS3["OCO_AI_PROVIDER"] = "OCO_AI_PROVIDER";
50551
+ CONFIG_KEYS3["OCO_ONE_LINE_COMMIT"] = "OCO_ONE_LINE_COMMIT";
50552
+ CONFIG_KEYS3["OCO_TEST_MOCK_TYPE"] = "OCO_TEST_MOCK_TYPE";
50553
+ CONFIG_KEYS3["OCO_API_URL"] = "OCO_API_URL";
50554
+ CONFIG_KEYS3["OCO_API_CUSTOM_HEADERS"] = "OCO_API_CUSTOM_HEADERS";
50555
+ CONFIG_KEYS3["OCO_OMIT_SCOPE"] = "OCO_OMIT_SCOPE";
50556
+ CONFIG_KEYS3["OCO_GITPUSH"] = "OCO_GITPUSH";
50557
+ CONFIG_KEYS3["OCO_HOOK_AUTO_UNCOMMENT"] = "OCO_HOOK_AUTO_UNCOMMENT";
50558
+ return CONFIG_KEYS3;
50274
50559
  })(CONFIG_KEYS || {});
50275
50560
  var MODEL_LIST = {
50276
50561
  openai: [
@@ -50302,10 +50587,11 @@ var MODEL_LIST = {
50302
50587
  "gpt-4o-mini-2024-07-18"
50303
50588
  ],
50304
50589
  anthropic: [
50305
- "claude-3-5-sonnet-20240620",
50306
- "claude-3-opus-20240229",
50307
- "claude-3-sonnet-20240229",
50308
- "claude-3-haiku-20240307"
50590
+ "claude-sonnet-4-20250514",
50591
+ "claude-opus-4-20250514",
50592
+ "claude-3-7-sonnet-20250219",
50593
+ "claude-3-5-sonnet-20241022",
50594
+ "claude-3-5-haiku-20241022"
50309
50595
  ],
50310
50596
  gemini: [
50311
50597
  "gemini-1.5-flash",
@@ -50372,6 +50658,110 @@ var MODEL_LIST = {
50372
50658
  "mistral-moderation-latest"
50373
50659
  ],
50374
50660
  deepseek: ["deepseek-chat", "deepseek-reasoner"],
50661
+ // AI/ML API available chat-completion models
50662
+ // https://api.aimlapi.com/v1/models
50663
+ aimlapi: [
50664
+ "openai/gpt-4o",
50665
+ "gpt-4o-2024-08-06",
50666
+ "gpt-4o-2024-05-13",
50667
+ "gpt-4o-mini",
50668
+ "gpt-4o-mini-2024-07-18",
50669
+ "chatgpt-4o-latest",
50670
+ "gpt-4-turbo",
50671
+ "gpt-4-turbo-2024-04-09",
50672
+ "gpt-4",
50673
+ "gpt-4-0125-preview",
50674
+ "gpt-4-1106-preview",
50675
+ "gpt-3.5-turbo",
50676
+ "gpt-3.5-turbo-0125",
50677
+ "gpt-3.5-turbo-1106",
50678
+ "o1-preview",
50679
+ "o1-preview-2024-09-12",
50680
+ "o1-mini",
50681
+ "o1-mini-2024-09-12",
50682
+ "o3-mini",
50683
+ "gpt-4o-audio-preview",
50684
+ "gpt-4o-mini-audio-preview",
50685
+ "gpt-4o-search-preview",
50686
+ "gpt-4o-mini-search-preview",
50687
+ "openai/gpt-4.1-2025-04-14",
50688
+ "openai/gpt-4.1-mini-2025-04-14",
50689
+ "openai/gpt-4.1-nano-2025-04-14",
50690
+ "openai/o4-mini-2025-04-16",
50691
+ "openai/o3-2025-04-16",
50692
+ "o1",
50693
+ "openai/o3-pro",
50694
+ "meta-llama/Llama-3.2-90B-Vision-Instruct-Turbo",
50695
+ "google/gemma-2-27b-it",
50696
+ "meta-llama/Llama-Vision-Free",
50697
+ "Qwen/Qwen2-72B-Instruct",
50698
+ "mistralai/Mixtral-8x7B-Instruct-v0.1",
50699
+ "nvidia/Llama-3.1-Nemotron-70B-Instruct-HF",
50700
+ "NousResearch/Nous-Hermes-2-Mixtral-8x7B-DPO",
50701
+ "meta-llama/Llama-3.3-70B-Instruct-Turbo",
50702
+ "meta-llama/Llama-3.2-3B-Instruct-Turbo",
50703
+ "meta-llama/Llama-3.2-11B-Vision-Instruct-Turbo",
50704
+ "meta-llama/Llama-Guard-3-11B-Vision-Turbo",
50705
+ "Qwen/Qwen2.5-7B-Instruct-Turbo",
50706
+ "Qwen/Qwen2.5-Coder-32B-Instruct",
50707
+ "meta-llama/Meta-Llama-3-8B-Instruct-Lite",
50708
+ "meta-llama/Llama-3-8b-chat-hf",
50709
+ "meta-llama/Llama-3-70b-chat-hf",
50710
+ "Qwen/Qwen2.5-72B-Instruct-Turbo",
50711
+ "Qwen/QwQ-32B",
50712
+ "meta-llama/Meta-Llama-3.1-405B-Instruct-Turbo",
50713
+ "meta-llama/Meta-Llama-3.1-8B-Instruct-Turbo",
50714
+ "meta-llama/Meta-Llama-3.1-70B-Instruct-Turbo",
50715
+ "mistralai/Mistral-7B-Instruct-v0.2",
50716
+ "meta-llama/LlamaGuard-2-8b",
50717
+ "mistralai/Mistral-7B-Instruct-v0.1",
50718
+ "mistralai/Mistral-7B-Instruct-v0.3",
50719
+ "meta-llama/Meta-Llama-Guard-3-8B",
50720
+ "meta-llama/llama-4-scout",
50721
+ "meta-llama/llama-4-maverick",
50722
+ "Qwen/Qwen3-235B-A22B-fp8-tput",
50723
+ "claude-3-opus-20240229",
50724
+ "claude-3-haiku-20240307",
50725
+ "claude-3-5-sonnet-20240620",
50726
+ "claude-3-5-sonnet-20241022",
50727
+ "claude-3-5-haiku-20241022",
50728
+ "claude-3-7-sonnet-20250219",
50729
+ "claude-sonnet-4-20250514",
50730
+ "claude-opus-4-20250514",
50731
+ "google/gemini-2.0-flash-exp",
50732
+ "google/gemini-2.0-flash",
50733
+ "google/gemini-2.5-pro",
50734
+ "google/gemini-2.5-flash",
50735
+ "deepseek-chat",
50736
+ "deepseek-reasoner",
50737
+ "qwen-max",
50738
+ "qwen-plus",
50739
+ "qwen-turbo",
50740
+ "qwen-max-2025-01-25",
50741
+ "mistralai/mistral-tiny",
50742
+ "mistralai/mistral-nemo",
50743
+ "anthracite-org/magnum-v4-72b",
50744
+ "nvidia/llama-3.1-nemotron-70b-instruct",
50745
+ "cohere/command-r-plus",
50746
+ "mistralai/codestral-2501",
50747
+ "google/gemma-3-4b-it",
50748
+ "google/gemma-3-12b-it",
50749
+ "google/gemma-3-27b-it",
50750
+ "google/gemini-2.5-flash-lite-preview",
50751
+ "deepseek/deepseek-prover-v2",
50752
+ "google/gemma-3n-e4b-it",
50753
+ "cohere/command-a",
50754
+ "MiniMax-Text-01",
50755
+ "abab6.5s-chat",
50756
+ "minimax/m1",
50757
+ "bagoodex/bagoodex-search-v1",
50758
+ "moonshot/kimi-k2-preview",
50759
+ "perplexity/sonar",
50760
+ "perplexity/sonar-pro",
50761
+ "x-ai/grok-4-07-09",
50762
+ "x-ai/grok-3-beta",
50763
+ "x-ai/grok-3-mini-beta"
50764
+ ],
50375
50765
  // OpenRouter available models
50376
50766
  // input_modalities: 'text'
50377
50767
  // output_modalities: 'text'
@@ -50720,6 +51110,8 @@ var getDefaultModel = (provider) => {
50720
51110
  return MODEL_LIST.mistral[0];
50721
51111
  case "deepseek":
50722
51112
  return MODEL_LIST.deepseek[0];
51113
+ case "aimlapi":
51114
+ return MODEL_LIST.aimlapi[0];
50723
51115
  case "openrouter":
50724
51116
  return MODEL_LIST.openrouter[0];
50725
51117
  default:
@@ -50876,9 +51268,10 @@ var configValidators = {
50876
51268
  "flowise",
50877
51269
  "groq",
50878
51270
  "deepseek",
51271
+ "aimlapi",
50879
51272
  "openrouter"
50880
51273
  ].includes(value) || value.startsWith("ollama"),
50881
- `${value} is not supported yet, use 'ollama', 'mlx', 'anthropic', 'azure', 'gemini', 'flowise', 'mistral', 'deepseek' or 'openai' (default)`
51274
+ `${value} is not supported yet, use 'ollama', 'mlx', 'anthropic', 'azure', 'gemini', 'flowise', 'mistral', 'deepseek', 'aimlapi' or 'openai' (default)`
50882
51275
  );
50883
51276
  return value;
50884
51277
  },
@@ -50907,6 +51300,13 @@ var configValidators = {
50907
51300
  "Must be true or false"
50908
51301
  );
50909
51302
  return value;
51303
+ },
51304
+ ["OCO_HOOK_AUTO_UNCOMMENT" /* OCO_HOOK_AUTO_UNCOMMENT */](value) {
51305
+ validateConfig(
51306
+ "OCO_HOOK_AUTO_UNCOMMENT" /* OCO_HOOK_AUTO_UNCOMMENT */,
51307
+ typeof value === "boolean",
51308
+ "Must be true or false"
51309
+ );
50910
51310
  }
50911
51311
  };
50912
51312
  var OCO_AI_PROVIDER_ENUM = /* @__PURE__ */ ((OCO_AI_PROVIDER_ENUM2) => {
@@ -50921,9 +51321,35 @@ var OCO_AI_PROVIDER_ENUM = /* @__PURE__ */ ((OCO_AI_PROVIDER_ENUM2) => {
50921
51321
  OCO_AI_PROVIDER_ENUM2["MISTRAL"] = "mistral";
50922
51322
  OCO_AI_PROVIDER_ENUM2["MLX"] = "mlx";
50923
51323
  OCO_AI_PROVIDER_ENUM2["DEEPSEEK"] = "deepseek";
51324
+ OCO_AI_PROVIDER_ENUM2["AIMLAPI"] = "aimlapi";
50924
51325
  OCO_AI_PROVIDER_ENUM2["OPENROUTER"] = "openrouter";
50925
51326
  return OCO_AI_PROVIDER_ENUM2;
50926
51327
  })(OCO_AI_PROVIDER_ENUM || {});
51328
+ var PROVIDER_API_KEY_URLS = {
51329
+ ["openai" /* OPENAI */]: "https://platform.openai.com/api-keys",
51330
+ ["anthropic" /* ANTHROPIC */]: "https://console.anthropic.com/settings/keys",
51331
+ ["gemini" /* GEMINI */]: "https://aistudio.google.com/app/apikey",
51332
+ ["groq" /* GROQ */]: "https://console.groq.com/keys",
51333
+ ["mistral" /* MISTRAL */]: "https://console.mistral.ai/api-keys/",
51334
+ ["deepseek" /* DEEPSEEK */]: "https://platform.deepseek.com/api_keys",
51335
+ ["openrouter" /* OPENROUTER */]: "https://openrouter.ai/keys",
51336
+ ["aimlapi" /* AIMLAPI */]: "https://aimlapi.com/app/keys",
51337
+ ["azure" /* AZURE */]: "https://portal.azure.com/",
51338
+ ["ollama" /* OLLAMA */]: null,
51339
+ ["mlx" /* MLX */]: null,
51340
+ ["flowise" /* FLOWISE */]: null,
51341
+ ["test" /* TEST */]: null
51342
+ };
51343
+ var RECOMMENDED_MODELS = {
51344
+ ["openai" /* OPENAI */]: "gpt-4o-mini",
51345
+ ["anthropic" /* ANTHROPIC */]: "claude-sonnet-4-20250514",
51346
+ ["gemini" /* GEMINI */]: "gemini-1.5-flash",
51347
+ ["groq" /* GROQ */]: "llama3-70b-8192",
51348
+ ["mistral" /* MISTRAL */]: "mistral-small-latest",
51349
+ ["deepseek" /* DEEPSEEK */]: "deepseek-chat",
51350
+ ["openrouter" /* OPENROUTER */]: "openai/gpt-4o-mini",
51351
+ ["aimlapi" /* AIMLAPI */]: "gpt-4o-mini"
51352
+ };
50927
51353
  var defaultConfigPath = (0, import_path.join)((0, import_os.homedir)(), ".opencommit");
50928
51354
  var defaultEnvPath = (0, import_path.resolve)(process.cwd(), ".env");
50929
51355
  var OCO_PROMPT_MODULE_ENUM = /* @__PURE__ */ ((OCO_PROMPT_MODULE_ENUM2) => {
@@ -50945,8 +51371,9 @@ var DEFAULT_CONFIG = {
50945
51371
  OCO_TEST_MOCK_TYPE: "commit-message",
50946
51372
  OCO_WHY: false,
50947
51373
  OCO_OMIT_SCOPE: false,
50948
- OCO_GITPUSH: true
51374
+ OCO_GITPUSH: true,
50949
51375
  // todo: deprecate
51376
+ OCO_HOOK_AUTO_UNCOMMENT: false
50950
51377
  };
50951
51378
  var initGlobalConfig = (configPath = defaultConfigPath) => {
50952
51379
  (0, import_fs.writeFileSync)(configPath, (0, import_ini.stringify)(DEFAULT_CONFIG), "utf8");
@@ -51147,6 +51574,11 @@ function getConfigKeyDetails(key) {
51147
51574
  description: "Message template placeholder",
51148
51575
  values: ["String (must start with $)"]
51149
51576
  };
51577
+ case "OCO_HOOK_AUTO_UNCOMMENT" /* OCO_HOOK_AUTO_UNCOMMENT */:
51578
+ return {
51579
+ description: "Automatically uncomment the commit message in the hook",
51580
+ values: ["true", "false"]
51581
+ };
51150
51582
  default:
51151
51583
  return {
51152
51584
  description: "String value",
@@ -51269,6 +51701,12 @@ var configCommand = G3(
51269
51701
  }
51270
51702
  );
51271
51703
 
51704
+ // src/prompts.ts
51705
+ init_dist2();
51706
+
51707
+ // src/modules/commitlint/config.ts
51708
+ init_dist2();
51709
+
51272
51710
  // node_modules/@anthropic-ai/sdk/version.mjs
51273
51711
  var VERSION = "0.19.2";
51274
51712
 
@@ -52874,9 +53312,9 @@ function debug(action, ...args) {
52874
53312
  }
52875
53313
  }
52876
53314
  var uuid4 = () => {
52877
- return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (c3) => {
53315
+ return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (c4) => {
52878
53316
  const r3 = Math.random() * 16 | 0;
52879
- const v5 = c3 === "x" ? r3 : r3 & 3 | 8;
53317
+ const v5 = c4 === "x" ? r3 : r3 & 3 | 8;
52880
53318
  return v5.toString(16);
52881
53319
  });
52882
53320
  };
@@ -53473,6 +53911,9 @@ var { AnthropicError: AnthropicError2, APIError: APIError2, APIConnectionError:
53473
53911
  })(Anthropic || (Anthropic = {}));
53474
53912
  var sdk_default = Anthropic;
53475
53913
 
53914
+ // src/engine/anthropic.ts
53915
+ init_dist2();
53916
+
53476
53917
  // node_modules/axios/lib/helpers/bind.js
53477
53918
  function bind(fn, thisArg) {
53478
53919
  return function wrap() {
@@ -56635,8 +57076,8 @@ var CancelToken = class _CancelToken {
56635
57076
  */
56636
57077
  static source() {
56637
57078
  let cancel;
56638
- const token = new _CancelToken(function executor(c3) {
56639
- cancel = c3;
57079
+ const token = new _CancelToken(function executor(c4) {
57080
+ cancel = c4;
56640
57081
  });
56641
57082
  return {
56642
57083
  token,
@@ -56782,6 +57223,49 @@ var {
56782
57223
  mergeConfig: mergeConfig2
56783
57224
  } = axios_default;
56784
57225
 
57226
+ // src/utils/errors.ts
57227
+ var ModelNotFoundError = class extends Error {
57228
+ constructor(modelName, provider, statusCode = 404) {
57229
+ super(`Model '${modelName}' not found for provider '${provider}'`);
57230
+ this.name = "ModelNotFoundError";
57231
+ this.modelName = modelName;
57232
+ this.provider = provider;
57233
+ this.statusCode = statusCode;
57234
+ }
57235
+ };
57236
+ function isModelNotFoundError(error) {
57237
+ if (error instanceof ModelNotFoundError) {
57238
+ return true;
57239
+ }
57240
+ if (error instanceof Error) {
57241
+ const message = error.message.toLowerCase();
57242
+ if (message.includes("model") && (message.includes("not found") || message.includes("does not exist") || message.includes("invalid model"))) {
57243
+ return true;
57244
+ }
57245
+ if (message.includes("model") && (message.includes("not found") || message.includes("invalid"))) {
57246
+ return true;
57247
+ }
57248
+ if ("status" in error && error.status === 404 && message.includes("model")) {
57249
+ return true;
57250
+ }
57251
+ if ("response" in error) {
57252
+ const response = error.response;
57253
+ if (response?.status === 404) {
57254
+ return true;
57255
+ }
57256
+ }
57257
+ }
57258
+ return false;
57259
+ }
57260
+ function getSuggestedModels(provider, failedModel) {
57261
+ const providerKey = provider.toLowerCase();
57262
+ const models = MODEL_LIST[providerKey];
57263
+ if (!models || !Array.isArray(models)) {
57264
+ return [];
57265
+ }
57266
+ return models.filter((m5) => m5 !== failedModel).slice(0, 5);
57267
+ }
57268
+
56785
57269
  // src/utils/removeContentTags.ts
56786
57270
  function removeContentTags(content, tag) {
56787
57271
  if (!content || typeof content !== "string") {
@@ -56859,6 +57343,12 @@ var AnthropicEngine = class {
56859
57343
  return removeContentTags(content, "think");
56860
57344
  } catch (error) {
56861
57345
  const err = error;
57346
+ if (err.message?.toLowerCase().includes("model") && (err.message?.toLowerCase().includes("not found") || err.message?.toLowerCase().includes("does not exist") || err.message?.toLowerCase().includes("invalid"))) {
57347
+ throw new ModelNotFoundError(this.config.model, "anthropic", 404);
57348
+ }
57349
+ if ("status" in error && error.status === 404) {
57350
+ throw new ModelNotFoundError(this.config.model, "anthropic", 404);
57351
+ }
56862
57352
  ce(`${source_default.red("\u2716")} ${err?.message || err}`);
56863
57353
  if (axios_default.isAxiosError(error) && error.response?.status === 401) {
56864
57354
  const anthropicAiError = error.response.data.error;
@@ -56867,6 +57357,9 @@ var AnthropicEngine = class {
56867
57357
  "For help look into README https://github.com/di-sukharev/opencommit#setup"
56868
57358
  );
56869
57359
  }
57360
+ if (axios_default.isAxiosError(error) && error.response?.status === 404) {
57361
+ throw new ModelNotFoundError(this.config.model, "anthropic", 404);
57362
+ }
56870
57363
  throw err;
56871
57364
  }
56872
57365
  };
@@ -57016,12 +57509,12 @@ function __await(v5) {
57016
57509
  }
57017
57510
  function __asyncGenerator(thisArg, _arguments, generator) {
57018
57511
  if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
57019
- var g4 = generator.apply(thisArg, _arguments || []), i3, q6 = [];
57512
+ var g5 = generator.apply(thisArg, _arguments || []), i3, q6 = [];
57020
57513
  return i3 = {}, verb("next"), verb("throw"), verb("return"), i3[Symbol.asyncIterator] = function() {
57021
57514
  return this;
57022
57515
  }, i3;
57023
57516
  function verb(n2) {
57024
- if (g4[n2]) i3[n2] = function(v5) {
57517
+ if (g5[n2]) i3[n2] = function(v5) {
57025
57518
  return new Promise(function(a4, b7) {
57026
57519
  q6.push([n2, v5, a4, b7]) > 1 || resume(n2, v5);
57027
57520
  });
@@ -57029,7 +57522,7 @@ function __asyncGenerator(thisArg, _arguments, generator) {
57029
57522
  }
57030
57523
  function resume(n2, v5) {
57031
57524
  try {
57032
- step(g4[n2](v5));
57525
+ step(g5[n2](v5));
57033
57526
  } catch (e3) {
57034
57527
  settle2(q6[0][3], e3);
57035
57528
  }
@@ -60683,6 +61176,7 @@ var OpenAIClient = class {
60683
61176
  };
60684
61177
 
60685
61178
  // src/engine/azure.ts
61179
+ init_dist2();
60686
61180
  var AzureEngine = class {
60687
61181
  constructor(config7) {
60688
61182
  this.generateCommitMessage = async (messages) => {
@@ -61063,12 +61557,12 @@ function __await2(v5) {
61063
61557
  }
61064
61558
  function __asyncGenerator2(thisArg, _arguments, generator) {
61065
61559
  if (!Symbol.asyncIterator) throw new TypeError("Symbol.asyncIterator is not defined.");
61066
- var g4 = generator.apply(thisArg, _arguments || []), i3, q6 = [];
61560
+ var g5 = generator.apply(thisArg, _arguments || []), i3, q6 = [];
61067
61561
  return i3 = {}, verb("next"), verb("throw"), verb("return"), i3[Symbol.asyncIterator] = function() {
61068
61562
  return this;
61069
61563
  }, i3;
61070
61564
  function verb(n2) {
61071
- if (g4[n2]) i3[n2] = function(v5) {
61565
+ if (g5[n2]) i3[n2] = function(v5) {
61072
61566
  return new Promise(function(a4, b7) {
61073
61567
  q6.push([n2, v5, a4, b7]) > 1 || resume(n2, v5);
61074
61568
  });
@@ -61076,7 +61570,7 @@ function __asyncGenerator2(thisArg, _arguments, generator) {
61076
61570
  }
61077
61571
  function resume(n2, v5) {
61078
61572
  try {
61079
- step(g4[n2](v5));
61573
+ step(g5[n2](v5));
61080
61574
  } catch (e3) {
61081
61575
  settle2(q6[0][3], e3);
61082
61576
  }
@@ -61609,10 +62103,16 @@ var GeminiEngine = class {
61609
62103
  return removeContentTags(content, "think");
61610
62104
  } catch (error) {
61611
62105
  const err = error;
62106
+ if (err.message?.toLowerCase().includes("model") && (err.message?.toLowerCase().includes("not found") || err.message?.toLowerCase().includes("does not exist") || err.message?.toLowerCase().includes("invalid"))) {
62107
+ throw new ModelNotFoundError(this.config.model, "gemini", 404);
62108
+ }
61612
62109
  if (axios_default.isAxiosError(error) && error.response?.status === 401) {
61613
62110
  const geminiError = error.response.data.error;
61614
62111
  if (geminiError) throw new Error(geminiError?.message);
61615
62112
  }
62113
+ if (axios_default.isAxiosError(error) && error.response?.status === 404) {
62114
+ throw new ModelNotFoundError(this.config.model, "gemini", 404);
62115
+ }
61616
62116
  throw err;
61617
62117
  }
61618
62118
  }
@@ -61648,6 +62148,12 @@ var OllamaEngine = class {
61648
62148
  return removeContentTags(content, "think");
61649
62149
  } catch (err) {
61650
62150
  const message = err.response?.data?.error ?? err.message;
62151
+ if (message?.toLowerCase().includes("model") && (message?.toLowerCase().includes("not found") || message?.toLowerCase().includes("does not exist") || message?.toLowerCase().includes("pull"))) {
62152
+ throw new ModelNotFoundError(this.config.model, "ollama", 404);
62153
+ }
62154
+ if (err.response?.status === 404) {
62155
+ throw new ModelNotFoundError(this.config.model, "ollama", 404);
62156
+ }
61651
62157
  throw new Error(`Ollama provider error: ${message}`);
61652
62158
  }
61653
62159
  }
@@ -62886,9 +63392,9 @@ function debug2(action, ...args) {
62886
63392
  }
62887
63393
  }
62888
63394
  var uuid42 = () => {
62889
- return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (c3) => {
63395
+ return "xxxxxxxx-xxxx-4xxx-yxxx-xxxxxxxxxxxx".replace(/[xy]/g, (c4) => {
62890
63396
  const r3 = Math.random() * 16 | 0;
62891
- const v5 = c3 === "x" ? r3 : r3 & 3 | 8;
63397
+ const v5 = c4 === "x" ? r3 : r3 & 3 | 8;
62892
63398
  return v5.toString(16);
62893
63399
  });
62894
63400
  };
@@ -63678,7 +64184,7 @@ var AbstractChatCompletionRunner = class extends EventStream {
63678
64184
  const finalFunctionCallResult = __classPrivateFieldGet10(this, _AbstractChatCompletionRunner_instances, "m", _AbstractChatCompletionRunner_getFinalFunctionCallResult).call(this);
63679
64185
  if (finalFunctionCallResult != null)
63680
64186
  this._emit("finalFunctionCallResult", finalFunctionCallResult);
63681
- if (this._chatCompletions.some((c3) => c3.usage)) {
64187
+ if (this._chatCompletions.some((c4) => c4.usage)) {
63682
64188
  this._emit("totalUsage", __classPrivateFieldGet10(this, _AbstractChatCompletionRunner_instances, "m", _AbstractChatCompletionRunner_calculateTotalUsage).call(this));
63683
64189
  }
63684
64190
  }
@@ -66378,10 +66884,19 @@ var OpenAiEngine = class {
66378
66884
  return removeContentTags(content, "think");
66379
66885
  } catch (error) {
66380
66886
  const err = error;
66887
+ if (err.message?.toLowerCase().includes("model") && (err.message?.toLowerCase().includes("not found") || err.message?.toLowerCase().includes("does not exist") || err.message?.toLowerCase().includes("invalid"))) {
66888
+ throw new ModelNotFoundError(this.config.model, "openai", 404);
66889
+ }
66890
+ if ("status" in error && error.status === 404) {
66891
+ throw new ModelNotFoundError(this.config.model, "openai", 404);
66892
+ }
66381
66893
  if (axios_default.isAxiosError(error) && error.response?.status === 401) {
66382
66894
  const openAiError = error.response.data.error;
66383
66895
  if (openAiError) throw new Error(openAiError.message);
66384
66896
  }
66897
+ if (axios_default.isAxiosError(error) && error.response?.status === 404) {
66898
+ throw new ModelNotFoundError(this.config.model, "openai", 404);
66899
+ }
66385
66900
  throw err;
66386
66901
  }
66387
66902
  };
@@ -66419,8 +66934,7 @@ var MistralAiEngine = class {
66419
66934
  if (REQUEST_TOKENS > this.config.maxTokensInput - this.config.maxTokensOutput)
66420
66935
  throw new Error("TOO_MUCH_TOKENS" /* tooMuchTokens */);
66421
66936
  const completion = await this.client.chat.complete(params);
66422
- if (!completion.choices)
66423
- throw Error("No completion choice available.");
66937
+ if (!completion.choices) throw Error("No completion choice available.");
66424
66938
  const message = completion.choices[0].message;
66425
66939
  if (!message || !message.content)
66426
66940
  throw Error("No completion choice available.");
@@ -66439,7 +66953,10 @@ var MistralAiEngine = class {
66439
66953
  if (!config7.baseURL) {
66440
66954
  this.client = new Mistral({ apiKey: config7.apiKey });
66441
66955
  } else {
66442
- this.client = new Mistral({ apiKey: config7.apiKey, serverURL: config7.baseURL });
66956
+ this.client = new Mistral({
66957
+ apiKey: config7.apiKey,
66958
+ serverURL: config7.baseURL
66959
+ });
66443
66960
  }
66444
66961
  }
66445
66962
  };
@@ -66521,6 +67038,40 @@ var DeepseekEngine = class extends OpenAiEngine {
66521
67038
  }
66522
67039
  };
66523
67040
 
67041
+ // src/engine/aimlapi.ts
67042
+ var AimlApiEngine = class {
67043
+ constructor(config7) {
67044
+ this.config = config7;
67045
+ this.generateCommitMessage = async (messages) => {
67046
+ try {
67047
+ const response = await this.client.post("", {
67048
+ model: this.config.model,
67049
+ messages
67050
+ });
67051
+ const message = response.data.choices?.[0]?.message;
67052
+ return message?.content ?? null;
67053
+ } catch (error) {
67054
+ const err = error;
67055
+ if (axios_default.isAxiosError(error) && error.response?.status === 401) {
67056
+ const apiError = error.response.data.error;
67057
+ if (apiError) throw new Error(apiError.message);
67058
+ }
67059
+ throw err;
67060
+ }
67061
+ };
67062
+ this.client = axios_default.create({
67063
+ baseURL: config7.baseURL || "https://api.aimlapi.com/v1/chat/completions",
67064
+ headers: {
67065
+ Authorization: `Bearer ${config7.apiKey}`,
67066
+ "HTTP-Referer": "https://github.com/di-sukharev/opencommit",
67067
+ "X-Title": "opencommit",
67068
+ "Content-Type": "application/json",
67069
+ ...config7.customHeaders
67070
+ }
67071
+ });
67072
+ }
67073
+ };
67074
+
66524
67075
  // src/engine/openrouter.ts
66525
67076
  var OpenRouterEngine = class {
66526
67077
  constructor(config7) {
@@ -66607,6 +67158,8 @@ function getEngine() {
66607
67158
  return new MLXEngine(DEFAULT_CONFIG2);
66608
67159
  case "deepseek" /* DEEPSEEK */:
66609
67160
  return new DeepseekEngine(DEFAULT_CONFIG2);
67161
+ case "aimlapi" /* AIMLAPI */:
67162
+ return new AimlApiEngine(DEFAULT_CONFIG2);
66610
67163
  case "openrouter" /* OPENROUTER */:
66611
67164
  return new OpenRouterEngine(DEFAULT_CONFIG2);
66612
67165
  default:
@@ -66631,6 +67184,7 @@ var computeHash = async (content, algorithm = "sha256") => {
66631
67184
  };
66632
67185
 
66633
67186
  // src/modules/commitlint/prompts.ts
67187
+ init_dist2();
66634
67188
  var import_types = __toESM(require_lib5(), 1);
66635
67189
  var config2 = getConfig();
66636
67190
  var translation = i18n[config2.OCO_LANGUAGE || "en"];
@@ -67120,7 +67674,10 @@ var config5 = getConfig();
67120
67674
  var MAX_TOKENS_INPUT = config5.OCO_TOKENS_MAX_INPUT;
67121
67675
  var MAX_TOKENS_OUTPUT = config5.OCO_TOKENS_MAX_OUTPUT;
67122
67676
  var generateCommitMessageChatCompletionPrompt = async (diff, fullGitMojiSpec, context) => {
67123
- const INIT_MESSAGES_PROMPT = await getMainCommitPrompt(fullGitMojiSpec, context);
67677
+ const INIT_MESSAGES_PROMPT = await getMainCommitPrompt(
67678
+ fullGitMojiSpec,
67679
+ context
67680
+ );
67124
67681
  const chatContextAsCompletionRequest = [...INIT_MESSAGES_PROMPT];
67125
67682
  chatContextAsCompletionRequest.push({
67126
67683
  role: "user",
@@ -67135,8 +67692,77 @@ var GenerateCommitMessageErrorEnum = ((GenerateCommitMessageErrorEnum2) => {
67135
67692
  GenerateCommitMessageErrorEnum2["outputTokensTooHigh"] = `Token limit exceeded, OCO_TOKENS_MAX_OUTPUT must not be much higher than the default ${500 /* DEFAULT_MAX_TOKENS_OUTPUT */} tokens.`;
67136
67693
  return GenerateCommitMessageErrorEnum2;
67137
67694
  })(GenerateCommitMessageErrorEnum || {});
67695
+ async function handleModelNotFoundError(error, provider, currentModel) {
67696
+ console.log(
67697
+ source_default.red(`
67698
+ \u2716 Model '${currentModel}' not found
67699
+ `)
67700
+ );
67701
+ const suggestedModels = getSuggestedModels(provider, currentModel);
67702
+ const recommended = RECOMMENDED_MODELS[provider];
67703
+ if (suggestedModels.length === 0) {
67704
+ console.log(
67705
+ source_default.yellow(
67706
+ `No alternative models available. Run 'oco setup' to configure a different model.`
67707
+ )
67708
+ );
67709
+ return null;
67710
+ }
67711
+ const options = [];
67712
+ if (recommended && suggestedModels.includes(recommended)) {
67713
+ options.push({
67714
+ value: recommended,
67715
+ label: `${recommended} (Recommended)`
67716
+ });
67717
+ }
67718
+ suggestedModels.filter((m5) => m5 !== recommended).forEach((model) => {
67719
+ options.push({ value: model, label: model });
67720
+ });
67721
+ options.push({ value: "__custom__", label: "Enter custom model..." });
67722
+ const selection = await ee({
67723
+ message: "Select an alternative model:",
67724
+ options
67725
+ });
67726
+ if (hD2(selection)) {
67727
+ return null;
67728
+ }
67729
+ let newModel;
67730
+ if (selection === "__custom__") {
67731
+ const { text } = await Promise.resolve().then(() => (init_dist2(), dist_exports));
67732
+ const customModel = await text({
67733
+ message: "Enter model name:",
67734
+ validate: (value) => {
67735
+ if (!value || value.trim().length === 0) {
67736
+ return "Model name is required";
67737
+ }
67738
+ return void 0;
67739
+ }
67740
+ });
67741
+ if (hD2(customModel)) {
67742
+ return null;
67743
+ }
67744
+ newModel = customModel;
67745
+ } else {
67746
+ newModel = selection;
67747
+ }
67748
+ const saveAsDefault = await Q3({
67749
+ message: "Save as default model?"
67750
+ });
67751
+ if (!hD2(saveAsDefault) && saveAsDefault) {
67752
+ const existingConfig = getGlobalConfig();
67753
+ setGlobalConfig({
67754
+ ...existingConfig,
67755
+ OCO_MODEL: newModel
67756
+ });
67757
+ console.log(source_default.green("\u2714") + " Model saved as default\n");
67758
+ }
67759
+ return newModel;
67760
+ }
67138
67761
  var ADJUSTMENT_FACTOR = 20;
67139
- var generateCommitMessageByDiff = async (diff, fullGitMojiSpec = false, context = "") => {
67762
+ var generateCommitMessageByDiff = async (diff, fullGitMojiSpec = false, context = "", retryWithModel) => {
67763
+ const currentConfig = getConfig();
67764
+ const provider = currentConfig.OCO_AI_PROVIDER || "openai";
67765
+ const currentModel = retryWithModel || currentConfig.OCO_MODEL;
67140
67766
  try {
67141
67767
  const INIT_MESSAGES_PROMPT = await getMainCommitPrompt(
67142
67768
  fullGitMojiSpec,
@@ -67170,6 +67796,28 @@ var generateCommitMessageByDiff = async (diff, fullGitMojiSpec = false, context
67170
67796
  throw new Error("EMPTY_MESSAGE" /* emptyMessage */);
67171
67797
  return commitMessage;
67172
67798
  } catch (error) {
67799
+ if (isModelNotFoundError(error)) {
67800
+ const newModel = await handleModelNotFoundError(
67801
+ error,
67802
+ provider,
67803
+ currentModel
67804
+ );
67805
+ if (newModel) {
67806
+ console.log(source_default.cyan(`Retrying with ${newModel}...
67807
+ `));
67808
+ const existingConfig = getGlobalConfig();
67809
+ setGlobalConfig({
67810
+ ...existingConfig,
67811
+ OCO_MODEL: newModel
67812
+ });
67813
+ return generateCommitMessageByDiff(
67814
+ diff,
67815
+ fullGitMojiSpec,
67816
+ context,
67817
+ newModel
67818
+ );
67819
+ }
67820
+ }
67173
67821
  throw error;
67174
67822
  }
67175
67823
  };
@@ -67259,6 +67907,8 @@ function delay3(ms) {
67259
67907
  // src/utils/git.ts
67260
67908
  var import_fs3 = require("fs");
67261
67909
  var import_ignore = __toESM(require_ignore(), 1);
67910
+ var import_path4 = require("path");
67911
+ init_dist2();
67262
67912
  var assertGitRepo = async () => {
67263
67913
  try {
67264
67914
  await execa("git", ["rev-parse"]);
@@ -67266,56 +67916,62 @@ var assertGitRepo = async () => {
67266
67916
  throw new Error(error);
67267
67917
  }
67268
67918
  };
67269
- var getOpenCommitIgnore = () => {
67919
+ var getOpenCommitIgnore = async () => {
67920
+ const gitDir = await getGitDir();
67270
67921
  const ig = (0, import_ignore.default)();
67271
67922
  try {
67272
- ig.add((0, import_fs3.readFileSync)(".opencommitignore").toString().split("\n"));
67923
+ ig.add(
67924
+ (0, import_fs3.readFileSync)((0, import_path4.join)(gitDir, ".opencommitignore")).toString().split("\n")
67925
+ );
67273
67926
  } catch (e3) {
67274
67927
  }
67275
67928
  return ig;
67276
67929
  };
67277
67930
  var getCoreHooksPath = async () => {
67278
- const { stdout } = await execa("git", ["config", "core.hooksPath"]);
67931
+ const gitDir = await getGitDir();
67932
+ const { stdout } = await execa("git", ["config", "core.hooksPath"], {
67933
+ cwd: gitDir
67934
+ });
67279
67935
  return stdout;
67280
67936
  };
67281
67937
  var getStagedFiles = async () => {
67282
- const { stdout: gitDir } = await execa("git", [
67283
- "rev-parse",
67284
- "--show-toplevel"
67285
- ]);
67286
- const { stdout: files } = await execa("git", [
67287
- "diff",
67288
- "--name-only",
67289
- "--cached",
67290
- "--relative",
67291
- gitDir
67292
- ]);
67938
+ const gitDir = await getGitDir();
67939
+ const { stdout: files } = await execa(
67940
+ "git",
67941
+ ["diff", "--name-only", "--cached", "--relative"],
67942
+ { cwd: gitDir }
67943
+ );
67293
67944
  if (!files) return [];
67294
67945
  const filesList = files.split("\n");
67295
- const ig = getOpenCommitIgnore();
67946
+ const ig = await getOpenCommitIgnore();
67296
67947
  const allowedFiles = filesList.filter((file) => !ig.ignores(file));
67297
67948
  if (!allowedFiles) return [];
67298
67949
  return allowedFiles.sort();
67299
67950
  };
67300
67951
  var getChangedFiles = async () => {
67301
- const { stdout: modified } = await execa("git", ["ls-files", "--modified"]);
67302
- const { stdout: others } = await execa("git", [
67303
- "ls-files",
67304
- "--others",
67305
- "--exclude-standard"
67306
- ]);
67952
+ const gitDir = await getGitDir();
67953
+ const { stdout: modified } = await execa("git", ["ls-files", "--modified"], {
67954
+ cwd: gitDir
67955
+ });
67956
+ const { stdout: others } = await execa(
67957
+ "git",
67958
+ ["ls-files", "--others", "--exclude-standard"],
67959
+ { cwd: gitDir }
67960
+ );
67307
67961
  const files = [...modified.split("\n"), ...others.split("\n")].filter(
67308
67962
  (file) => !!file
67309
67963
  );
67310
67964
  return files.sort();
67311
67965
  };
67312
67966
  var gitAdd = async ({ files }) => {
67967
+ const gitDir = await getGitDir();
67313
67968
  const gitAddSpinner = le();
67314
67969
  gitAddSpinner.start("Adding files to commit");
67315
- await execa("git", ["add", ...files]);
67970
+ await execa("git", ["add", ...files], { cwd: gitDir });
67316
67971
  gitAddSpinner.stop(`Staged ${files.length} files`);
67317
67972
  };
67318
67973
  var getDiff = async ({ files }) => {
67974
+ const gitDir = await getGitDir();
67319
67975
  const lockFiles = files.filter(
67320
67976
  (file) => file.includes(".lock") || file.includes("-lock.") || file.includes(".svg") || file.includes(".png") || file.includes(".jpg") || file.includes(".jpeg") || file.includes(".webp") || file.includes(".gif")
67321
67977
  );
@@ -67330,14 +67986,20 @@ ${lockFiles.join(
67330
67986
  const filesWithoutLocks = files.filter(
67331
67987
  (file) => !file.includes(".lock") && !file.includes("-lock.")
67332
67988
  );
67333
- const { stdout: diff } = await execa("git", [
67334
- "diff",
67335
- "--staged",
67336
- "--",
67337
- ...filesWithoutLocks
67338
- ]);
67989
+ const { stdout: diff } = await execa(
67990
+ "git",
67991
+ ["diff", "--staged", "--", ...filesWithoutLocks],
67992
+ { cwd: gitDir }
67993
+ );
67339
67994
  return diff;
67340
67995
  };
67996
+ var getGitDir = async () => {
67997
+ const { stdout: gitDir } = await execa("git", [
67998
+ "rev-parse",
67999
+ "--show-toplevel"
68000
+ ]);
68001
+ return gitDir;
68002
+ };
67341
68003
 
67342
68004
  // src/utils/trytm.ts
67343
68005
  var trytm = async (promise) => {
@@ -67395,11 +68057,23 @@ ${source_default.grey("\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2
67395
68057
  ${commitMessage}
67396
68058
  ${source_default.grey("\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014\u2014")}`
67397
68059
  );
67398
- const isCommitConfirmedByUser = skipCommitConfirmation || await Q3({
67399
- message: "Confirm the commit message?"
68060
+ const userAction = skipCommitConfirmation ? "Yes" : await ee({
68061
+ message: "Confirm the commit message?",
68062
+ options: [
68063
+ { value: "Yes", label: "Yes" },
68064
+ { value: "No", label: "No" },
68065
+ { value: "Edit", label: "Edit" }
68066
+ ]
67400
68067
  });
67401
- if (hD2(isCommitConfirmedByUser)) process.exit(1);
67402
- if (isCommitConfirmedByUser) {
68068
+ if (hD2(userAction)) process.exit(1);
68069
+ if (userAction === "Edit") {
68070
+ const textResponse = await J4({
68071
+ message: "Please edit the commit message: (press Enter to continue)",
68072
+ initialValue: commitMessage
68073
+ });
68074
+ commitMessage = textResponse.toString();
68075
+ }
68076
+ if (userAction === "Yes" || userAction === "Edit") {
67403
68077
  const committingChangesSpinner = le();
67404
68078
  committingChangesSpinner.start("Committing the changes");
67405
68079
  const { stdout } = await execa("git", [
@@ -67552,6 +68226,7 @@ ${stagedFiles.map((file) => ` ${file}`).join("\n")}`
67552
68226
  }
67553
68227
 
67554
68228
  // src/commands/commitlint.ts
68229
+ init_dist2();
67555
68230
  var commitlintConfigCommand = G3(
67556
68231
  {
67557
68232
  name: "commitlint" /* commitlint */,
@@ -67581,15 +68256,16 @@ var commitlintConfigCommand = G3(
67581
68256
  );
67582
68257
 
67583
68258
  // src/commands/githook.ts
68259
+ init_dist2();
67584
68260
  var import_fs4 = require("fs");
67585
68261
  var import_promises3 = __toESM(require("fs/promises"), 1);
67586
- var import_path4 = __toESM(require("path"), 1);
68262
+ var import_path5 = __toESM(require("path"), 1);
67587
68263
  var HOOK_NAME = "prepare-commit-msg";
67588
- var DEFAULT_SYMLINK_URL = import_path4.default.join(".git", "hooks", HOOK_NAME);
68264
+ var DEFAULT_SYMLINK_URL = import_path5.default.join(".git", "hooks", HOOK_NAME);
67589
68265
  var getHooksPath = async () => {
67590
68266
  try {
67591
68267
  const hooksPath = await getCoreHooksPath();
67592
- return import_path4.default.join(hooksPath, HOOK_NAME);
68268
+ return import_path5.default.join(hooksPath, HOOK_NAME);
67593
68269
  } catch (error) {
67594
68270
  return DEFAULT_SYMLINK_URL;
67595
68271
  }
@@ -67629,7 +68305,7 @@ var hookCommand = G3(
67629
68305
  `Different ${HOOK_NAME} is already set. Remove it before setting opencommit as '${HOOK_NAME}' hook.`
67630
68306
  );
67631
68307
  }
67632
- await import_promises3.default.mkdir(import_path4.default.dirname(SYMLINK_URL), { recursive: true });
68308
+ await import_promises3.default.mkdir(import_path5.default.dirname(SYMLINK_URL), { recursive: true });
67633
68309
  await import_promises3.default.symlink(HOOK_URL, SYMLINK_URL, "file");
67634
68310
  await import_promises3.default.chmod(SYMLINK_URL, 493);
67635
68311
  return ce(`${source_default.green("\u2714")} Hook set`);
@@ -67664,6 +68340,7 @@ var hookCommand = G3(
67664
68340
 
67665
68341
  // src/commands/prepare-commit-msg-hook.ts
67666
68342
  var import_promises4 = __toESM(require("fs/promises"), 1);
68343
+ init_dist2();
67667
68344
  var [messageFilePath, commitSource] = process.argv.slice(2);
67668
68345
  var prepareCommitMessageHook = async (isStageAllFlag = false) => {
67669
68346
  try {
@@ -67698,17 +68375,480 @@ var prepareCommitMessageHook = async (isStageAllFlag = false) => {
67698
68375
  );
67699
68376
  spin.stop("Done");
67700
68377
  const fileContent = await import_promises4.default.readFile(messageFilePath);
67701
- await import_promises4.default.writeFile(
67702
- messageFilePath,
67703
- commitMessage + "\n" + fileContent.toString()
67704
- );
68378
+ const messageWithComment = `# ${commitMessage}
68379
+
68380
+ # ---------- [OpenCommit] ---------- #
68381
+ # Remove the # above to use this generated commit message.
68382
+ # To cancel the commit, just close this window without making any changes.
68383
+
68384
+ ${fileContent.toString()}`;
68385
+ const messageWithoutComment = `${commitMessage}
68386
+
68387
+ ${fileContent.toString()}`;
68388
+ const message = config7.OCO_HOOK_AUTO_UNCOMMENT ? messageWithoutComment : messageWithComment;
68389
+ await import_promises4.default.writeFile(messageFilePath, message);
67705
68390
  } catch (error) {
67706
68391
  ce(`${source_default.red("\u2716")} ${error}`);
67707
68392
  process.exit(1);
67708
68393
  }
67709
68394
  };
67710
68395
 
68396
+ // src/commands/setup.ts
68397
+ init_dist2();
68398
+
68399
+ // src/utils/modelCache.ts
68400
+ var import_fs5 = require("fs");
68401
+ var import_os2 = require("os");
68402
+ var import_path6 = require("path");
68403
+ var MODEL_CACHE_PATH = (0, import_path6.join)((0, import_os2.homedir)(), ".opencommit-models.json");
68404
+ var CACHE_TTL_MS = 7 * 24 * 60 * 60 * 1e3;
68405
+ function readCache() {
68406
+ try {
68407
+ if (!(0, import_fs5.existsSync)(MODEL_CACHE_PATH)) {
68408
+ return null;
68409
+ }
68410
+ const data = (0, import_fs5.readFileSync)(MODEL_CACHE_PATH, "utf8");
68411
+ return JSON.parse(data);
68412
+ } catch {
68413
+ return null;
68414
+ }
68415
+ }
68416
+ function writeCache(models) {
68417
+ try {
68418
+ const cache = {
68419
+ timestamp: Date.now(),
68420
+ models
68421
+ };
68422
+ (0, import_fs5.writeFileSync)(MODEL_CACHE_PATH, JSON.stringify(cache, null, 2), "utf8");
68423
+ } catch {
68424
+ }
68425
+ }
68426
+ function isCacheValid(cache) {
68427
+ if (!cache) return false;
68428
+ return Date.now() - cache.timestamp < CACHE_TTL_MS;
68429
+ }
68430
+ async function fetchOpenAIModels(apiKey) {
68431
+ try {
68432
+ const response = await fetch("https://api.openai.com/v1/models", {
68433
+ headers: {
68434
+ Authorization: `Bearer ${apiKey}`
68435
+ }
68436
+ });
68437
+ if (!response.ok) {
68438
+ return MODEL_LIST.openai;
68439
+ }
68440
+ const data = await response.json();
68441
+ const models = data.data.map((m5) => m5.id).filter(
68442
+ (id) => id.startsWith("gpt-") || id.startsWith("o1") || id.startsWith("o3") || id.startsWith("o4")
68443
+ ).sort();
68444
+ return models.length > 0 ? models : MODEL_LIST.openai;
68445
+ } catch {
68446
+ return MODEL_LIST.openai;
68447
+ }
68448
+ }
68449
+ async function fetchOllamaModels(baseUrl = "http://localhost:11434") {
68450
+ try {
68451
+ const response = await fetch(`${baseUrl}/api/tags`);
68452
+ if (!response.ok) {
68453
+ return [];
68454
+ }
68455
+ const data = await response.json();
68456
+ return data.models?.map((m5) => m5.name) || [];
68457
+ } catch {
68458
+ return [];
68459
+ }
68460
+ }
68461
+ async function fetchModelsForProvider(provider, apiKey, baseUrl) {
68462
+ const cache = readCache();
68463
+ if (isCacheValid(cache) && cache.models[provider]) {
68464
+ return cache.models[provider];
68465
+ }
68466
+ let models = [];
68467
+ switch (provider.toLowerCase()) {
68468
+ case "openai" /* OPENAI */:
68469
+ if (apiKey) {
68470
+ models = await fetchOpenAIModels(apiKey);
68471
+ } else {
68472
+ models = MODEL_LIST.openai;
68473
+ }
68474
+ break;
68475
+ case "ollama" /* OLLAMA */:
68476
+ models = await fetchOllamaModels(baseUrl);
68477
+ break;
68478
+ case "anthropic" /* ANTHROPIC */:
68479
+ models = MODEL_LIST.anthropic;
68480
+ break;
68481
+ case "gemini" /* GEMINI */:
68482
+ models = MODEL_LIST.gemini;
68483
+ break;
68484
+ case "groq" /* GROQ */:
68485
+ models = MODEL_LIST.groq;
68486
+ break;
68487
+ case "mistral" /* MISTRAL */:
68488
+ models = MODEL_LIST.mistral;
68489
+ break;
68490
+ case "deepseek" /* DEEPSEEK */:
68491
+ models = MODEL_LIST.deepseek;
68492
+ break;
68493
+ case "aimlapi" /* AIMLAPI */:
68494
+ models = MODEL_LIST.aimlapi;
68495
+ break;
68496
+ case "openrouter" /* OPENROUTER */:
68497
+ models = MODEL_LIST.openrouter;
68498
+ break;
68499
+ default:
68500
+ models = MODEL_LIST.openai;
68501
+ }
68502
+ const existingCache = cache?.models || {};
68503
+ existingCache[provider] = models;
68504
+ writeCache(existingCache);
68505
+ return models;
68506
+ }
68507
+
68508
+ // src/commands/setup.ts
68509
+ var PROVIDER_DISPLAY_NAMES = {
68510
+ ["openai" /* OPENAI */]: "OpenAI (GPT-4o, GPT-4)",
68511
+ ["anthropic" /* ANTHROPIC */]: "Anthropic (Claude Sonnet, Opus)",
68512
+ ["ollama" /* OLLAMA */]: "Ollama (Free, runs locally)",
68513
+ ["gemini" /* GEMINI */]: "Google Gemini",
68514
+ ["groq" /* GROQ */]: "Groq (Fast inference, free tier)",
68515
+ ["mistral" /* MISTRAL */]: "Mistral AI",
68516
+ ["deepseek" /* DEEPSEEK */]: "DeepSeek",
68517
+ ["openrouter" /* OPENROUTER */]: "OpenRouter (Multiple providers)",
68518
+ ["aimlapi" /* AIMLAPI */]: "AI/ML API",
68519
+ ["azure" /* AZURE */]: "Azure OpenAI",
68520
+ ["mlx" /* MLX */]: "MLX (Apple Silicon, local)"
68521
+ };
68522
+ var PRIMARY_PROVIDERS = [
68523
+ "openai" /* OPENAI */,
68524
+ "anthropic" /* ANTHROPIC */,
68525
+ "ollama" /* OLLAMA */
68526
+ ];
68527
+ var OTHER_PROVIDERS = [
68528
+ "gemini" /* GEMINI */,
68529
+ "groq" /* GROQ */,
68530
+ "mistral" /* MISTRAL */,
68531
+ "deepseek" /* DEEPSEEK */,
68532
+ "openrouter" /* OPENROUTER */,
68533
+ "aimlapi" /* AIMLAPI */,
68534
+ "azure" /* AZURE */,
68535
+ "mlx" /* MLX */
68536
+ ];
68537
+ var NO_API_KEY_PROVIDERS = [
68538
+ "ollama" /* OLLAMA */,
68539
+ "mlx" /* MLX */
68540
+ ];
68541
+ async function selectProvider() {
68542
+ const primaryOptions = PRIMARY_PROVIDERS.map((provider) => ({
68543
+ value: provider,
68544
+ label: PROVIDER_DISPLAY_NAMES[provider] || provider
68545
+ }));
68546
+ primaryOptions.push({
68547
+ value: "other",
68548
+ label: "Other providers..."
68549
+ });
68550
+ const selection = await ee({
68551
+ message: "Select your AI provider:",
68552
+ options: primaryOptions
68553
+ });
68554
+ if (hD2(selection)) return selection;
68555
+ if (selection === "other") {
68556
+ const otherOptions = OTHER_PROVIDERS.map((provider) => ({
68557
+ value: provider,
68558
+ label: PROVIDER_DISPLAY_NAMES[provider] || provider
68559
+ }));
68560
+ return await ee({
68561
+ message: "Select provider:",
68562
+ options: otherOptions
68563
+ });
68564
+ }
68565
+ return selection;
68566
+ }
68567
+ async function getApiKey(provider) {
68568
+ const url2 = PROVIDER_API_KEY_URLS[provider];
68569
+ let message = `Enter your ${provider} API key:`;
68570
+ if (url2) {
68571
+ message = `Enter your API key:
68572
+ ${source_default.dim(` Get your key at: ${url2}`)}`;
68573
+ }
68574
+ return await J4({
68575
+ message,
68576
+ placeholder: "sk-...",
68577
+ validate: (value) => {
68578
+ if (!value || value.trim().length === 0) {
68579
+ return "API key is required";
68580
+ }
68581
+ return void 0;
68582
+ }
68583
+ });
68584
+ }
68585
+ async function selectModel(provider, apiKey) {
68586
+ const loadingSpinner = le();
68587
+ loadingSpinner.start("Fetching available models...");
68588
+ let models = [];
68589
+ try {
68590
+ models = await fetchModelsForProvider(provider, apiKey);
68591
+ } catch {
68592
+ const providerKey = provider.toLowerCase();
68593
+ models = MODEL_LIST[providerKey] || [];
68594
+ }
68595
+ loadingSpinner.stop("Models loaded");
68596
+ if (models.length === 0) {
68597
+ if (NO_API_KEY_PROVIDERS.includes(provider)) {
68598
+ return await J4({
68599
+ message: "Enter model name (e.g., llama3:8b, mistral):",
68600
+ placeholder: "llama3:8b",
68601
+ validate: (value) => {
68602
+ if (!value || value.trim().length === 0) {
68603
+ return "Model name is required";
68604
+ }
68605
+ return void 0;
68606
+ }
68607
+ });
68608
+ }
68609
+ const providerKey = provider.toLowerCase();
68610
+ return MODEL_LIST[providerKey]?.[0] || "gpt-4o-mini";
68611
+ }
68612
+ const recommended = RECOMMENDED_MODELS[provider];
68613
+ const options = [];
68614
+ if (recommended && models.includes(recommended)) {
68615
+ options.push({
68616
+ value: recommended,
68617
+ label: `${recommended} (Recommended)`
68618
+ });
68619
+ }
68620
+ const otherModels = models.filter((m5) => m5 !== recommended).slice(0, 10);
68621
+ otherModels.forEach((model) => {
68622
+ options.push({ value: model, label: model });
68623
+ });
68624
+ if (models.length > 11) {
68625
+ options.push({ value: "__show_all__", label: "Show all models..." });
68626
+ }
68627
+ options.push({ value: "__custom__", label: "Enter custom model..." });
68628
+ const selection = await ee({
68629
+ message: "Select a model:",
68630
+ options
68631
+ });
68632
+ if (hD2(selection)) return selection;
68633
+ if (selection === "__show_all__") {
68634
+ const allOptions = models.map((model) => ({
68635
+ value: model,
68636
+ label: model === recommended ? `${model} (Recommended)` : model
68637
+ }));
68638
+ return await ee({
68639
+ message: "Select a model:",
68640
+ options: allOptions
68641
+ });
68642
+ }
68643
+ if (selection === "__custom__") {
68644
+ return await J4({
68645
+ message: "Enter model name:",
68646
+ validate: (value) => {
68647
+ if (!value || value.trim().length === 0) {
68648
+ return "Model name is required";
68649
+ }
68650
+ return void 0;
68651
+ }
68652
+ });
68653
+ }
68654
+ return selection;
68655
+ }
68656
+ async function setupOllama() {
68657
+ console.log(source_default.cyan("\n Ollama - Free Local AI\n"));
68658
+ console.log(source_default.dim(" Setup steps:"));
68659
+ console.log(source_default.dim(" 1. Install: https://ollama.ai/download"));
68660
+ console.log(source_default.dim(" 2. Pull a model: ollama pull llama3:8b"));
68661
+ console.log(source_default.dim(" 3. Start server: ollama serve\n"));
68662
+ const loadingSpinner = le();
68663
+ loadingSpinner.start("Checking for local Ollama installation...");
68664
+ const defaultUrl = "http://localhost:11434";
68665
+ let ollamaModels = [];
68666
+ try {
68667
+ ollamaModels = await fetchOllamaModels(defaultUrl);
68668
+ if (ollamaModels.length > 0) {
68669
+ loadingSpinner.stop(
68670
+ `${source_default.green("\u2714")} Found ${ollamaModels.length} local model(s)`
68671
+ );
68672
+ } else {
68673
+ loadingSpinner.stop(
68674
+ source_default.yellow(
68675
+ "Ollama is running but no models found. Pull a model first: ollama pull llama3:8b"
68676
+ )
68677
+ );
68678
+ }
68679
+ } catch {
68680
+ loadingSpinner.stop(
68681
+ source_default.yellow(
68682
+ "Could not connect to Ollama. Make sure it is running: ollama serve"
68683
+ )
68684
+ );
68685
+ }
68686
+ let model;
68687
+ if (ollamaModels.length > 0) {
68688
+ model = await ee({
68689
+ message: "Select a model:",
68690
+ options: [
68691
+ ...ollamaModels.map((m5) => ({ value: m5, label: m5 })),
68692
+ { value: "__custom__", label: "Enter custom model name..." }
68693
+ ]
68694
+ });
68695
+ if (hD2(model)) return null;
68696
+ if (model === "__custom__") {
68697
+ model = await J4({
68698
+ message: "Enter model name (e.g., llama3:8b, mistral):",
68699
+ placeholder: "llama3:8b"
68700
+ });
68701
+ }
68702
+ } else {
68703
+ model = await J4({
68704
+ message: "Enter model name (e.g., llama3:8b, mistral):",
68705
+ placeholder: "llama3:8b",
68706
+ validate: (value) => {
68707
+ if (!value || value.trim().length === 0) {
68708
+ return "Model name is required";
68709
+ }
68710
+ return void 0;
68711
+ }
68712
+ });
68713
+ }
68714
+ if (hD2(model)) return null;
68715
+ const apiUrl = await J4({
68716
+ message: "Ollama URL (press Enter for default):",
68717
+ placeholder: defaultUrl,
68718
+ defaultValue: defaultUrl
68719
+ });
68720
+ if (hD2(apiUrl)) return null;
68721
+ return {
68722
+ provider: "ollama" /* OLLAMA */,
68723
+ model,
68724
+ apiUrl: apiUrl || defaultUrl
68725
+ };
68726
+ }
68727
+ async function runSetup() {
68728
+ ae(source_default.bgCyan(" Welcome to OpenCommit! "));
68729
+ const provider = await selectProvider();
68730
+ if (hD2(provider)) {
68731
+ ce("Setup cancelled");
68732
+ return false;
68733
+ }
68734
+ let config7 = {};
68735
+ if (provider === "ollama" /* OLLAMA */) {
68736
+ const ollamaConfig = await setupOllama();
68737
+ if (!ollamaConfig) {
68738
+ ce("Setup cancelled");
68739
+ return false;
68740
+ }
68741
+ config7 = {
68742
+ OCO_AI_PROVIDER: ollamaConfig.provider,
68743
+ OCO_MODEL: ollamaConfig.model,
68744
+ OCO_API_URL: ollamaConfig.apiUrl,
68745
+ OCO_API_KEY: "ollama"
68746
+ // Placeholder
68747
+ };
68748
+ } else if (provider === "mlx" /* MLX */) {
68749
+ console.log(source_default.cyan("\n MLX - Apple Silicon Local AI\n"));
68750
+ console.log(source_default.dim(" MLX runs locally on Apple Silicon Macs."));
68751
+ console.log(source_default.dim(" No API key required.\n"));
68752
+ const model = await J4({
68753
+ message: "Enter model name:",
68754
+ placeholder: "mlx-community/Llama-3-8B-Instruct-4bit"
68755
+ });
68756
+ if (hD2(model)) {
68757
+ ce("Setup cancelled");
68758
+ return false;
68759
+ }
68760
+ config7 = {
68761
+ OCO_AI_PROVIDER: "mlx" /* MLX */,
68762
+ OCO_MODEL: model,
68763
+ OCO_API_KEY: "mlx"
68764
+ // Placeholder
68765
+ };
68766
+ } else {
68767
+ const apiKey = await getApiKey(provider);
68768
+ if (hD2(apiKey)) {
68769
+ ce("Setup cancelled");
68770
+ return false;
68771
+ }
68772
+ const model = await selectModel(provider, apiKey);
68773
+ if (hD2(model)) {
68774
+ ce("Setup cancelled");
68775
+ return false;
68776
+ }
68777
+ config7 = {
68778
+ OCO_AI_PROVIDER: provider,
68779
+ OCO_API_KEY: apiKey,
68780
+ OCO_MODEL: model
68781
+ };
68782
+ }
68783
+ const existingConfig = getIsGlobalConfigFileExist() ? getGlobalConfig() : DEFAULT_CONFIG;
68784
+ const newConfig = {
68785
+ ...existingConfig,
68786
+ ...config7
68787
+ };
68788
+ setGlobalConfig(newConfig);
68789
+ ce(
68790
+ `${source_default.green("\u2714")} Configuration saved to ~/.opencommit
68791
+
68792
+ Run ${source_default.cyan("oco")} to generate commit messages!`
68793
+ );
68794
+ return true;
68795
+ }
68796
+ function isFirstRun() {
68797
+ if (!getIsGlobalConfigFileExist()) {
68798
+ return true;
68799
+ }
68800
+ const config7 = getConfig();
68801
+ const provider = config7.OCO_AI_PROVIDER || "openai" /* OPENAI */;
68802
+ if (NO_API_KEY_PROVIDERS.includes(provider)) {
68803
+ return !config7.OCO_MODEL;
68804
+ }
68805
+ return !config7.OCO_API_KEY;
68806
+ }
68807
+ async function promptForMissingApiKey() {
68808
+ const config7 = getConfig();
68809
+ const provider = config7.OCO_AI_PROVIDER || "openai" /* OPENAI */;
68810
+ if (NO_API_KEY_PROVIDERS.includes(provider)) {
68811
+ return true;
68812
+ }
68813
+ if (config7.OCO_API_KEY) {
68814
+ return true;
68815
+ }
68816
+ console.log(
68817
+ source_default.yellow(
68818
+ `
68819
+ API key missing for ${provider}. Let's set it up.
68820
+ `
68821
+ )
68822
+ );
68823
+ const apiKey = await getApiKey(provider);
68824
+ if (hD2(apiKey)) {
68825
+ return false;
68826
+ }
68827
+ const existingConfig = getGlobalConfig();
68828
+ setGlobalConfig({
68829
+ ...existingConfig,
68830
+ OCO_API_KEY: apiKey
68831
+ });
68832
+ console.log(source_default.green("\u2714") + " API key saved\n");
68833
+ return true;
68834
+ }
68835
+ var setupCommand = G3(
68836
+ {
68837
+ name: "setup" /* setup */,
68838
+ help: {
68839
+ description: "Interactive setup wizard for OpenCommit"
68840
+ }
68841
+ },
68842
+ async () => {
68843
+ await runSetup();
68844
+ }
68845
+ );
68846
+
68847
+ // src/utils/checkIsLatestVersion.ts
68848
+ init_dist2();
68849
+
67711
68850
  // src/version.ts
68851
+ init_dist2();
67712
68852
  var getOpenCommitLatestVersion = async () => {
67713
68853
  try {
67714
68854
  const { stdout } = await execa("npm", ["view", "opencommit", "version"]);
@@ -67739,9 +68879,9 @@ Current version: ${currentVersion}. Latest version: ${latestVersion}.
67739
68879
  };
67740
68880
 
67741
68881
  // src/migrations/_run.ts
67742
- var import_fs5 = __toESM(require("fs"), 1);
67743
- var import_os2 = require("os");
67744
- var import_path5 = require("path");
68882
+ var import_fs6 = __toESM(require("fs"), 1);
68883
+ var import_os3 = require("os");
68884
+ var import_path7 = require("path");
67745
68885
 
67746
68886
  // src/migrations/00_use_single_api_key_and_url.ts
67747
68887
  function use_single_api_key_and_url_default() {
@@ -67832,18 +68972,19 @@ var migrations = [
67832
68972
  ];
67833
68973
 
67834
68974
  // src/migrations/_run.ts
67835
- var migrationsFile = (0, import_path5.join)((0, import_os2.homedir)(), ".opencommit_migrations");
68975
+ init_dist2();
68976
+ var migrationsFile = (0, import_path7.join)((0, import_os3.homedir)(), ".opencommit_migrations");
67836
68977
  var getCompletedMigrations = () => {
67837
- if (!import_fs5.default.existsSync(migrationsFile)) {
68978
+ if (!import_fs6.default.existsSync(migrationsFile)) {
67838
68979
  return [];
67839
68980
  }
67840
- const data = import_fs5.default.readFileSync(migrationsFile, "utf-8");
68981
+ const data = import_fs6.default.readFileSync(migrationsFile, "utf-8");
67841
68982
  return data ? JSON.parse(data) : [];
67842
68983
  };
67843
68984
  var saveCompletedMigration = (migrationName) => {
67844
68985
  const completedMigrations = getCompletedMigrations();
67845
68986
  completedMigrations.push(migrationName);
67846
- import_fs5.default.writeFileSync(
68987
+ import_fs6.default.writeFileSync(
67847
68988
  migrationsFile,
67848
68989
  JSON.stringify(completedMigrations, null, 2)
67849
68990
  );
@@ -67852,6 +68993,15 @@ var runMigrations = async () => {
67852
68993
  if (!getIsGlobalConfigFileExist()) return;
67853
68994
  const config7 = getConfig();
67854
68995
  if (config7.OCO_AI_PROVIDER === "test" /* TEST */) return;
68996
+ if ([
68997
+ "deepseek" /* DEEPSEEK */,
68998
+ "groq" /* GROQ */,
68999
+ "mistral" /* MISTRAL */,
69000
+ "mlx" /* MLX */,
69001
+ "openrouter" /* OPENROUTER */
69002
+ ].includes(config7.OCO_AI_PROVIDER)) {
69003
+ return;
69004
+ }
67855
69005
  const completedMigrations = getCompletedMigrations();
67856
69006
  let isMigrated = false;
67857
69007
  for (const migration of migrations) {
@@ -67886,7 +69036,7 @@ Z2(
67886
69036
  {
67887
69037
  version: package_default.version,
67888
69038
  name: "opencommit",
67889
- commands: [configCommand, hookCommand, commitlintConfigCommand],
69039
+ commands: [configCommand, hookCommand, commitlintConfigCommand, setupCommand],
67890
69040
  flags: {
67891
69041
  fgm: {
67892
69042
  type: Boolean,
@@ -67915,6 +69065,16 @@ Z2(
67915
69065
  if (await isHookCalled()) {
67916
69066
  prepareCommitMessageHook();
67917
69067
  } else {
69068
+ if (isFirstRun()) {
69069
+ const setupComplete = await runSetup();
69070
+ if (!setupComplete) {
69071
+ process.exit(1);
69072
+ }
69073
+ }
69074
+ const hasApiKey = await promptForMissingApiKey();
69075
+ if (!hasApiKey) {
69076
+ process.exit(1);
69077
+ }
67918
69078
  commit(extraArgs, flags.context, false, flags.fgm, flags.yes);
67919
69079
  }
67920
69080
  },