@hot-updater/supabase 0.21.7 → 0.21.8

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/iac/index.js CHANGED
@@ -1,13 +1,11 @@
1
1
  import { createRequire } from "node:module";
2
- import { aborted, callbackify, debuglog, inspect, promisify, stripVTControlCharacters } from "node:util";
3
- import g, { execArgv, execPath, hrtime, platform, stdin, stdout } from "node:process";
4
- import * as f$1 from "node:readline";
5
- import M from "node:readline";
6
- import tty, { WriteStream } from "node:tty";
7
- import { ConfigBuilder, copyDirToTmp, link, makeEnv, transformEnv, transformTemplate } from "@hot-updater/plugin-core";
2
+ import { ConfigBuilder, copyDirToTmp, link, makeEnv, p, transformEnv, transformTemplate } from "@hot-updater/cli-tools";
8
3
  import { fileURLToPath } from "node:url";
9
4
  import { ChildProcess, execFile, spawn, spawnSync } from "node:child_process";
10
5
  import { StringDecoder } from "node:string_decoder";
6
+ import { aborted, callbackify, debuglog, inspect, promisify, stripVTControlCharacters } from "node:util";
7
+ import process$1, { execArgv, execPath, hrtime, platform } from "node:process";
8
+ import tty from "node:tty";
11
9
  import path from "node:path";
12
10
  import path$1 from "path";
13
11
  import { scheduler, setImmediate, setTimeout as setTimeout$1 } from "node:timers/promises";
@@ -35,7 +33,7 @@ var __copyProps = (to, from, except, desc) => {
35
33
  if (from && typeof from === "object" || typeof from === "function") for (var keys = __getOwnPropNames(from), i$1 = 0, n$1 = keys.length, key; i$1 < n$1; i$1++) {
36
34
  key = keys[i$1];
37
35
  if (!__hasOwnProp.call(to, key) && key !== except) __defProp(to, key, {
38
- get: ((k$2) => from[k$2]).bind(null, key),
36
+ get: ((k) => from[k]).bind(null, key),
39
37
  enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
40
38
  });
41
39
  }
@@ -47,1169 +45,6 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
47
45
  }) : target, mod));
48
46
  var __require = /* @__PURE__ */ createRequire(import.meta.url);
49
47
 
50
- //#endregion
51
- //#region ../../node_modules/.pnpm/sisteransi@1.0.5/node_modules/sisteransi/src/index.js
52
- var require_src = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/sisteransi@1.0.5/node_modules/sisteransi/src/index.js": ((exports, module) => {
53
- const ESC = "\x1B";
54
- const CSI = `${ESC}[`;
55
- const beep = "\x07";
56
- const cursor = {
57
- to(x$1, y$1) {
58
- if (!y$1) return `${CSI}${x$1 + 1}G`;
59
- return `${CSI}${y$1 + 1};${x$1 + 1}H`;
60
- },
61
- move(x$1, y$1) {
62
- let ret = "";
63
- if (x$1 < 0) ret += `${CSI}${-x$1}D`;
64
- else if (x$1 > 0) ret += `${CSI}${x$1}C`;
65
- if (y$1 < 0) ret += `${CSI}${-y$1}A`;
66
- else if (y$1 > 0) ret += `${CSI}${y$1}B`;
67
- return ret;
68
- },
69
- up: (count$1 = 1) => `${CSI}${count$1}A`,
70
- down: (count$1 = 1) => `${CSI}${count$1}B`,
71
- forward: (count$1 = 1) => `${CSI}${count$1}C`,
72
- backward: (count$1 = 1) => `${CSI}${count$1}D`,
73
- nextLine: (count$1 = 1) => `${CSI}E`.repeat(count$1),
74
- prevLine: (count$1 = 1) => `${CSI}F`.repeat(count$1),
75
- left: `${CSI}G`,
76
- hide: `${CSI}?25l`,
77
- show: `${CSI}?25h`,
78
- save: `${ESC}7`,
79
- restore: `${ESC}8`
80
- };
81
- const scroll = {
82
- up: (count$1 = 1) => `${CSI}S`.repeat(count$1),
83
- down: (count$1 = 1) => `${CSI}T`.repeat(count$1)
84
- };
85
- const erase = {
86
- screen: `${CSI}2J`,
87
- up: (count$1 = 1) => `${CSI}1J`.repeat(count$1),
88
- down: (count$1 = 1) => `${CSI}J`.repeat(count$1),
89
- line: `${CSI}2K`,
90
- lineEnd: `${CSI}K`,
91
- lineStart: `${CSI}1K`,
92
- lines(count$1) {
93
- let clear = "";
94
- for (let i$1 = 0; i$1 < count$1; i$1++) clear += this.line + (i$1 < count$1 - 1 ? cursor.up() : "");
95
- if (count$1) clear += cursor.left;
96
- return clear;
97
- }
98
- };
99
- module.exports = {
100
- cursor,
101
- scroll,
102
- erase,
103
- beep
104
- };
105
- }) });
106
-
107
- //#endregion
108
- //#region ../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js
109
- var require_picocolors = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js": ((exports, module) => {
110
- let p = process || {}, argv = p.argv || [], env = p.env || {};
111
- let isColorSupported = !(!!env.NO_COLOR || argv.includes("--no-color")) && (!!env.FORCE_COLOR || argv.includes("--color") || p.platform === "win32" || (p.stdout || {}).isTTY && env.TERM !== "dumb" || !!env.CI);
112
- let formatter = (open, close, replace = open) => (input) => {
113
- let string = "" + input, index = string.indexOf(close, open.length);
114
- return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close;
115
- };
116
- let replaceClose = (string, close, replace, index) => {
117
- let result = "", cursor$1 = 0;
118
- do {
119
- result += string.substring(cursor$1, index) + replace;
120
- cursor$1 = index + close.length;
121
- index = string.indexOf(close, cursor$1);
122
- } while (~index);
123
- return result + string.substring(cursor$1);
124
- };
125
- let createColors = (enabled = isColorSupported) => {
126
- let f$2 = enabled ? formatter : () => String;
127
- return {
128
- isColorSupported: enabled,
129
- reset: f$2("\x1B[0m", "\x1B[0m"),
130
- bold: f$2("\x1B[1m", "\x1B[22m", "\x1B[22m\x1B[1m"),
131
- dim: f$2("\x1B[2m", "\x1B[22m", "\x1B[22m\x1B[2m"),
132
- italic: f$2("\x1B[3m", "\x1B[23m"),
133
- underline: f$2("\x1B[4m", "\x1B[24m"),
134
- inverse: f$2("\x1B[7m", "\x1B[27m"),
135
- hidden: f$2("\x1B[8m", "\x1B[28m"),
136
- strikethrough: f$2("\x1B[9m", "\x1B[29m"),
137
- black: f$2("\x1B[30m", "\x1B[39m"),
138
- red: f$2("\x1B[31m", "\x1B[39m"),
139
- green: f$2("\x1B[32m", "\x1B[39m"),
140
- yellow: f$2("\x1B[33m", "\x1B[39m"),
141
- blue: f$2("\x1B[34m", "\x1B[39m"),
142
- magenta: f$2("\x1B[35m", "\x1B[39m"),
143
- cyan: f$2("\x1B[36m", "\x1B[39m"),
144
- white: f$2("\x1B[37m", "\x1B[39m"),
145
- gray: f$2("\x1B[90m", "\x1B[39m"),
146
- bgBlack: f$2("\x1B[40m", "\x1B[49m"),
147
- bgRed: f$2("\x1B[41m", "\x1B[49m"),
148
- bgGreen: f$2("\x1B[42m", "\x1B[49m"),
149
- bgYellow: f$2("\x1B[43m", "\x1B[49m"),
150
- bgBlue: f$2("\x1B[44m", "\x1B[49m"),
151
- bgMagenta: f$2("\x1B[45m", "\x1B[49m"),
152
- bgCyan: f$2("\x1B[46m", "\x1B[49m"),
153
- bgWhite: f$2("\x1B[47m", "\x1B[49m"),
154
- blackBright: f$2("\x1B[90m", "\x1B[39m"),
155
- redBright: f$2("\x1B[91m", "\x1B[39m"),
156
- greenBright: f$2("\x1B[92m", "\x1B[39m"),
157
- yellowBright: f$2("\x1B[93m", "\x1B[39m"),
158
- blueBright: f$2("\x1B[94m", "\x1B[39m"),
159
- magentaBright: f$2("\x1B[95m", "\x1B[39m"),
160
- cyanBright: f$2("\x1B[96m", "\x1B[39m"),
161
- whiteBright: f$2("\x1B[97m", "\x1B[39m"),
162
- bgBlackBright: f$2("\x1B[100m", "\x1B[49m"),
163
- bgRedBright: f$2("\x1B[101m", "\x1B[49m"),
164
- bgGreenBright: f$2("\x1B[102m", "\x1B[49m"),
165
- bgYellowBright: f$2("\x1B[103m", "\x1B[49m"),
166
- bgBlueBright: f$2("\x1B[104m", "\x1B[49m"),
167
- bgMagentaBright: f$2("\x1B[105m", "\x1B[49m"),
168
- bgCyanBright: f$2("\x1B[106m", "\x1B[49m"),
169
- bgWhiteBright: f$2("\x1B[107m", "\x1B[49m")
170
- };
171
- };
172
- module.exports = createColors();
173
- module.exports.createColors = createColors;
174
- }) });
175
-
176
- //#endregion
177
- //#region ../../node_modules/.pnpm/@clack+core@0.4.1/node_modules/@clack/core/dist/index.mjs
178
- var import_src$1 = /* @__PURE__ */ __toESM(require_src(), 1);
179
- var import_picocolors$1 = /* @__PURE__ */ __toESM(require_picocolors(), 1);
180
- function J$1({ onlyFirst: t = !1 } = {}) {
181
- const F$1 = ["[\\u001B\\u009B][[\\]()#;?]*(?:(?:(?:(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]+)*|[a-zA-Z\\d]+(?:;[-a-zA-Z\\d\\/#&.:=?%@~_]*)*)?(?:\\u0007|\\u001B\\u005C|\\u009C))", "(?:(?:\\d{1,4}(?:;\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]))"].join("|");
182
- return new RegExp(F$1, t ? void 0 : "g");
183
- }
184
- const Q = J$1();
185
- function T$1(t) {
186
- if (typeof t != "string") throw new TypeError(`Expected a \`string\`, got \`${typeof t}\``);
187
- return t.replace(Q, "");
188
- }
189
- function O(t) {
190
- return t && t.__esModule && Object.prototype.hasOwnProperty.call(t, "default") ? t.default : t;
191
- }
192
- var P$1 = { exports: {} };
193
- (function(t) {
194
- var u$2 = {};
195
- t.exports = u$2, u$2.eastAsianWidth = function(e$1) {
196
- var s = e$1.charCodeAt(0), i$1 = e$1.length == 2 ? e$1.charCodeAt(1) : 0, D$1 = s;
197
- return 55296 <= s && s <= 56319 && 56320 <= i$1 && i$1 <= 57343 && (s &= 1023, i$1 &= 1023, D$1 = s << 10 | i$1, D$1 += 65536), D$1 == 12288 || 65281 <= D$1 && D$1 <= 65376 || 65504 <= D$1 && D$1 <= 65510 ? "F" : D$1 == 8361 || 65377 <= D$1 && D$1 <= 65470 || 65474 <= D$1 && D$1 <= 65479 || 65482 <= D$1 && D$1 <= 65487 || 65490 <= D$1 && D$1 <= 65495 || 65498 <= D$1 && D$1 <= 65500 || 65512 <= D$1 && D$1 <= 65518 ? "H" : 4352 <= D$1 && D$1 <= 4447 || 4515 <= D$1 && D$1 <= 4519 || 4602 <= D$1 && D$1 <= 4607 || 9001 <= D$1 && D$1 <= 9002 || 11904 <= D$1 && D$1 <= 11929 || 11931 <= D$1 && D$1 <= 12019 || 12032 <= D$1 && D$1 <= 12245 || 12272 <= D$1 && D$1 <= 12283 || 12289 <= D$1 && D$1 <= 12350 || 12353 <= D$1 && D$1 <= 12438 || 12441 <= D$1 && D$1 <= 12543 || 12549 <= D$1 && D$1 <= 12589 || 12593 <= D$1 && D$1 <= 12686 || 12688 <= D$1 && D$1 <= 12730 || 12736 <= D$1 && D$1 <= 12771 || 12784 <= D$1 && D$1 <= 12830 || 12832 <= D$1 && D$1 <= 12871 || 12880 <= D$1 && D$1 <= 13054 || 13056 <= D$1 && D$1 <= 19903 || 19968 <= D$1 && D$1 <= 42124 || 42128 <= D$1 && D$1 <= 42182 || 43360 <= D$1 && D$1 <= 43388 || 44032 <= D$1 && D$1 <= 55203 || 55216 <= D$1 && D$1 <= 55238 || 55243 <= D$1 && D$1 <= 55291 || 63744 <= D$1 && D$1 <= 64255 || 65040 <= D$1 && D$1 <= 65049 || 65072 <= D$1 && D$1 <= 65106 || 65108 <= D$1 && D$1 <= 65126 || 65128 <= D$1 && D$1 <= 65131 || 110592 <= D$1 && D$1 <= 110593 || 127488 <= D$1 && D$1 <= 127490 || 127504 <= D$1 && D$1 <= 127546 || 127552 <= D$1 && D$1 <= 127560 || 127568 <= D$1 && D$1 <= 127569 || 131072 <= D$1 && D$1 <= 194367 || 177984 <= D$1 && D$1 <= 196605 || 196608 <= D$1 && D$1 <= 262141 ? "W" : 32 <= D$1 && D$1 <= 126 || 162 <= D$1 && D$1 <= 163 || 165 <= D$1 && D$1 <= 166 || D$1 == 172 || D$1 == 175 || 10214 <= D$1 && D$1 <= 10221 || 10629 <= D$1 && D$1 <= 10630 ? "Na" : D$1 == 161 || D$1 == 164 || 167 <= D$1 && D$1 <= 168 || D$1 == 170 || 173 <= D$1 && D$1 <= 174 || 176 <= D$1 && D$1 <= 180 || 182 <= D$1 && D$1 <= 186 || 188 <= D$1 && D$1 <= 191 || D$1 == 198 || D$1 == 208 || 215 <= D$1 && D$1 <= 216 || 222 <= D$1 && D$1 <= 225 || D$1 == 230 || 232 <= D$1 && D$1 <= 234 || 236 <= D$1 && D$1 <= 237 || D$1 == 240 || 242 <= D$1 && D$1 <= 243 || 247 <= D$1 && D$1 <= 250 || D$1 == 252 || D$1 == 254 || D$1 == 257 || D$1 == 273 || D$1 == 275 || D$1 == 283 || 294 <= D$1 && D$1 <= 295 || D$1 == 299 || 305 <= D$1 && D$1 <= 307 || D$1 == 312 || 319 <= D$1 && D$1 <= 322 || D$1 == 324 || 328 <= D$1 && D$1 <= 331 || D$1 == 333 || 338 <= D$1 && D$1 <= 339 || 358 <= D$1 && D$1 <= 359 || D$1 == 363 || D$1 == 462 || D$1 == 464 || D$1 == 466 || D$1 == 468 || D$1 == 470 || D$1 == 472 || D$1 == 474 || D$1 == 476 || D$1 == 593 || D$1 == 609 || D$1 == 708 || D$1 == 711 || 713 <= D$1 && D$1 <= 715 || D$1 == 717 || D$1 == 720 || 728 <= D$1 && D$1 <= 731 || D$1 == 733 || D$1 == 735 || 768 <= D$1 && D$1 <= 879 || 913 <= D$1 && D$1 <= 929 || 931 <= D$1 && D$1 <= 937 || 945 <= D$1 && D$1 <= 961 || 963 <= D$1 && D$1 <= 969 || D$1 == 1025 || 1040 <= D$1 && D$1 <= 1103 || D$1 == 1105 || D$1 == 8208 || 8211 <= D$1 && D$1 <= 8214 || 8216 <= D$1 && D$1 <= 8217 || 8220 <= D$1 && D$1 <= 8221 || 8224 <= D$1 && D$1 <= 8226 || 8228 <= D$1 && D$1 <= 8231 || D$1 == 8240 || 8242 <= D$1 && D$1 <= 8243 || D$1 == 8245 || D$1 == 8251 || D$1 == 8254 || D$1 == 8308 || D$1 == 8319 || 8321 <= D$1 && D$1 <= 8324 || D$1 == 8364 || D$1 == 8451 || D$1 == 8453 || D$1 == 8457 || D$1 == 8467 || D$1 == 8470 || 8481 <= D$1 && D$1 <= 8482 || D$1 == 8486 || D$1 == 8491 || 8531 <= D$1 && D$1 <= 8532 || 8539 <= D$1 && D$1 <= 8542 || 8544 <= D$1 && D$1 <= 8555 || 8560 <= D$1 && D$1 <= 8569 || D$1 == 8585 || 8592 <= D$1 && D$1 <= 8601 || 8632 <= D$1 && D$1 <= 8633 || D$1 == 8658 || D$1 == 8660 || D$1 == 8679 || D$1 == 8704 || 8706 <= D$1 && D$1 <= 8707 || 8711 <= D$1 && D$1 <= 8712 || D$1 == 8715 || D$1 == 8719 || D$1 == 8721 || D$1 == 8725 || D$1 == 8730 || 8733 <= D$1 && D$1 <= 8736 || D$1 == 8739 || D$1 == 8741 || 8743 <= D$1 && D$1 <= 8748 || D$1 == 8750 || 8756 <= D$1 && D$1 <= 8759 || 8764 <= D$1 && D$1 <= 8765 || D$1 == 8776 || D$1 == 8780 || D$1 == 8786 || 8800 <= D$1 && D$1 <= 8801 || 8804 <= D$1 && D$1 <= 8807 || 8810 <= D$1 && D$1 <= 8811 || 8814 <= D$1 && D$1 <= 8815 || 8834 <= D$1 && D$1 <= 8835 || 8838 <= D$1 && D$1 <= 8839 || D$1 == 8853 || D$1 == 8857 || D$1 == 8869 || D$1 == 8895 || D$1 == 8978 || 9312 <= D$1 && D$1 <= 9449 || 9451 <= D$1 && D$1 <= 9547 || 9552 <= D$1 && D$1 <= 9587 || 9600 <= D$1 && D$1 <= 9615 || 9618 <= D$1 && D$1 <= 9621 || 9632 <= D$1 && D$1 <= 9633 || 9635 <= D$1 && D$1 <= 9641 || 9650 <= D$1 && D$1 <= 9651 || 9654 <= D$1 && D$1 <= 9655 || 9660 <= D$1 && D$1 <= 9661 || 9664 <= D$1 && D$1 <= 9665 || 9670 <= D$1 && D$1 <= 9672 || D$1 == 9675 || 9678 <= D$1 && D$1 <= 9681 || 9698 <= D$1 && D$1 <= 9701 || D$1 == 9711 || 9733 <= D$1 && D$1 <= 9734 || D$1 == 9737 || 9742 <= D$1 && D$1 <= 9743 || 9748 <= D$1 && D$1 <= 9749 || D$1 == 9756 || D$1 == 9758 || D$1 == 9792 || D$1 == 9794 || 9824 <= D$1 && D$1 <= 9825 || 9827 <= D$1 && D$1 <= 9829 || 9831 <= D$1 && D$1 <= 9834 || 9836 <= D$1 && D$1 <= 9837 || D$1 == 9839 || 9886 <= D$1 && D$1 <= 9887 || 9918 <= D$1 && D$1 <= 9919 || 9924 <= D$1 && D$1 <= 9933 || 9935 <= D$1 && D$1 <= 9953 || D$1 == 9955 || 9960 <= D$1 && D$1 <= 9983 || D$1 == 10045 || D$1 == 10071 || 10102 <= D$1 && D$1 <= 10111 || 11093 <= D$1 && D$1 <= 11097 || 12872 <= D$1 && D$1 <= 12879 || 57344 <= D$1 && D$1 <= 63743 || 65024 <= D$1 && D$1 <= 65039 || D$1 == 65533 || 127232 <= D$1 && D$1 <= 127242 || 127248 <= D$1 && D$1 <= 127277 || 127280 <= D$1 && D$1 <= 127337 || 127344 <= D$1 && D$1 <= 127386 || 917760 <= D$1 && D$1 <= 917999 || 983040 <= D$1 && D$1 <= 1048573 || 1048576 <= D$1 && D$1 <= 1114109 ? "A" : "N";
198
- }, u$2.characterLength = function(e$1) {
199
- var s = this.eastAsianWidth(e$1);
200
- return s == "F" || s == "W" || s == "A" ? 2 : 1;
201
- };
202
- function F$1(e$1) {
203
- return e$1.match(/[\uD800-\uDBFF][\uDC00-\uDFFF]|[^\uD800-\uDFFF]/g) || [];
204
- }
205
- u$2.length = function(e$1) {
206
- for (var s = F$1(e$1), i$1 = 0, D$1 = 0; D$1 < s.length; D$1++) i$1 = i$1 + this.characterLength(s[D$1]);
207
- return i$1;
208
- }, u$2.slice = function(e$1, s, i$1) {
209
- textLen = u$2.length(e$1), s = s || 0, i$1 = i$1 || 1, s < 0 && (s = textLen + s), i$1 < 0 && (i$1 = textLen + i$1);
210
- for (var D$1 = "", C$1 = 0, o$2 = F$1(e$1), E = 0; E < o$2.length; E++) {
211
- var a$1 = o$2[E], n$1 = u$2.length(a$1);
212
- if (C$1 >= s - (n$1 == 2 ? 1 : 0)) if (C$1 + n$1 <= i$1) D$1 += a$1;
213
- else break;
214
- C$1 += n$1;
215
- }
216
- return D$1;
217
- };
218
- })(P$1);
219
- var X = P$1.exports;
220
- const DD = O(X);
221
- var uD = function() {
222
- 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;
223
- };
224
- const FD = O(uD);
225
- function A$1(t, u$2 = {}) {
226
- if (typeof t != "string" || t.length === 0 || (u$2 = {
227
- ambiguousIsNarrow: !0,
228
- ...u$2
229
- }, t = T$1(t), t.length === 0)) return 0;
230
- t = t.replace(FD(), " ");
231
- const F$1 = u$2.ambiguousIsNarrow ? 1 : 2;
232
- let e$1 = 0;
233
- for (const s of t) {
234
- const i$1 = s.codePointAt(0);
235
- if (i$1 <= 31 || i$1 >= 127 && i$1 <= 159 || i$1 >= 768 && i$1 <= 879) continue;
236
- switch (DD.eastAsianWidth(s)) {
237
- case "F":
238
- case "W":
239
- e$1 += 2;
240
- break;
241
- case "A":
242
- e$1 += F$1;
243
- break;
244
- default: e$1 += 1;
245
- }
246
- }
247
- return e$1;
248
- }
249
- const m = 10, L$1 = (t = 0) => (u$2) => `\x1B[${u$2 + t}m`, N = (t = 0) => (u$2) => `\x1B[${38 + t};5;${u$2}m`, I = (t = 0) => (u$2, F$1, e$1) => `\x1B[${38 + t};2;${u$2};${F$1};${e$1}m`, r = {
250
- modifier: {
251
- reset: [0, 0],
252
- bold: [1, 22],
253
- dim: [2, 22],
254
- italic: [3, 23],
255
- underline: [4, 24],
256
- overline: [53, 55],
257
- inverse: [7, 27],
258
- hidden: [8, 28],
259
- strikethrough: [9, 29]
260
- },
261
- color: {
262
- black: [30, 39],
263
- red: [31, 39],
264
- green: [32, 39],
265
- yellow: [33, 39],
266
- blue: [34, 39],
267
- magenta: [35, 39],
268
- cyan: [36, 39],
269
- white: [37, 39],
270
- blackBright: [90, 39],
271
- gray: [90, 39],
272
- grey: [90, 39],
273
- redBright: [91, 39],
274
- greenBright: [92, 39],
275
- yellowBright: [93, 39],
276
- blueBright: [94, 39],
277
- magentaBright: [95, 39],
278
- cyanBright: [96, 39],
279
- whiteBright: [97, 39]
280
- },
281
- bgColor: {
282
- bgBlack: [40, 49],
283
- bgRed: [41, 49],
284
- bgGreen: [42, 49],
285
- bgYellow: [43, 49],
286
- bgBlue: [44, 49],
287
- bgMagenta: [45, 49],
288
- bgCyan: [46, 49],
289
- bgWhite: [47, 49],
290
- bgBlackBright: [100, 49],
291
- bgGray: [100, 49],
292
- bgGrey: [100, 49],
293
- bgRedBright: [101, 49],
294
- bgGreenBright: [102, 49],
295
- bgYellowBright: [103, 49],
296
- bgBlueBright: [104, 49],
297
- bgMagentaBright: [105, 49],
298
- bgCyanBright: [106, 49],
299
- bgWhiteBright: [107, 49]
300
- }
301
- };
302
- Object.keys(r.modifier);
303
- const tD = Object.keys(r.color), eD = Object.keys(r.bgColor);
304
- [...tD, ...eD];
305
- function sD() {
306
- const t = /* @__PURE__ */ new Map();
307
- for (const [u$2, F$1] of Object.entries(r)) {
308
- for (const [e$1, s] of Object.entries(F$1)) r[e$1] = {
309
- open: `\x1B[${s[0]}m`,
310
- close: `\x1B[${s[1]}m`
311
- }, F$1[e$1] = r[e$1], t.set(s[0], s[1]);
312
- Object.defineProperty(r, u$2, {
313
- value: F$1,
314
- enumerable: !1
315
- });
316
- }
317
- return Object.defineProperty(r, "codes", {
318
- value: t,
319
- enumerable: !1
320
- }), r.color.close = "\x1B[39m", r.bgColor.close = "\x1B[49m", r.color.ansi = L$1(), r.color.ansi256 = N(), r.color.ansi16m = I(), r.bgColor.ansi = L$1(m), r.bgColor.ansi256 = N(m), r.bgColor.ansi16m = I(m), Object.defineProperties(r, {
321
- rgbToAnsi256: {
322
- value: (u$2, F$1, e$1) => u$2 === F$1 && F$1 === e$1 ? u$2 < 8 ? 16 : u$2 > 248 ? 231 : Math.round((u$2 - 8) / 247 * 24) + 232 : 16 + 36 * Math.round(u$2 / 255 * 5) + 6 * Math.round(F$1 / 255 * 5) + Math.round(e$1 / 255 * 5),
323
- enumerable: !1
324
- },
325
- hexToRgb: {
326
- value: (u$2) => {
327
- const F$1 = /[a-f\d]{6}|[a-f\d]{3}/i.exec(u$2.toString(16));
328
- if (!F$1) return [
329
- 0,
330
- 0,
331
- 0
332
- ];
333
- let [e$1] = F$1;
334
- e$1.length === 3 && (e$1 = [...e$1].map((i$1) => i$1 + i$1).join(""));
335
- const s = Number.parseInt(e$1, 16);
336
- return [
337
- s >> 16 & 255,
338
- s >> 8 & 255,
339
- s & 255
340
- ];
341
- },
342
- enumerable: !1
343
- },
344
- hexToAnsi256: {
345
- value: (u$2) => r.rgbToAnsi256(...r.hexToRgb(u$2)),
346
- enumerable: !1
347
- },
348
- ansi256ToAnsi: {
349
- value: (u$2) => {
350
- if (u$2 < 8) return 30 + u$2;
351
- if (u$2 < 16) return 90 + (u$2 - 8);
352
- let F$1, e$1, s;
353
- if (u$2 >= 232) F$1 = ((u$2 - 232) * 10 + 8) / 255, e$1 = F$1, s = F$1;
354
- else {
355
- u$2 -= 16;
356
- const C$1 = u$2 % 36;
357
- F$1 = Math.floor(u$2 / 36) / 5, e$1 = Math.floor(C$1 / 6) / 5, s = C$1 % 6 / 5;
358
- }
359
- const i$1 = Math.max(F$1, e$1, s) * 2;
360
- if (i$1 === 0) return 30;
361
- let D$1 = 30 + (Math.round(s) << 2 | Math.round(e$1) << 1 | Math.round(F$1));
362
- return i$1 === 2 && (D$1 += 60), D$1;
363
- },
364
- enumerable: !1
365
- },
366
- rgbToAnsi: {
367
- value: (u$2, F$1, e$1) => r.ansi256ToAnsi(r.rgbToAnsi256(u$2, F$1, e$1)),
368
- enumerable: !1
369
- },
370
- hexToAnsi: {
371
- value: (u$2) => r.ansi256ToAnsi(r.hexToAnsi256(u$2)),
372
- enumerable: !1
373
- }
374
- }), r;
375
- }
376
- const iD = sD(), v = new Set(["\x1B", "›"]), CD = 39, w$1 = "\x07", W$1 = "[", rD = "]", R = "m", y = `${rD}8;;`, V$1 = (t) => `${v.values().next().value}${W$1}${t}${R}`, z = (t) => `${v.values().next().value}${y}${t}${w$1}`, ED = (t) => t.split(" ").map((u$2) => A$1(u$2)), _$1 = (t, u$2, F$1) => {
377
- const e$1 = [...u$2];
378
- let s = !1, i$1 = !1, D$1 = A$1(T$1(t[t.length - 1]));
379
- for (const [C$1, o$2] of e$1.entries()) {
380
- const E = A$1(o$2);
381
- if (D$1 + E <= F$1 ? t[t.length - 1] += o$2 : (t.push(o$2), D$1 = 0), v.has(o$2) && (s = !0, i$1 = e$1.slice(C$1 + 1).join("").startsWith(y)), s) {
382
- i$1 ? o$2 === w$1 && (s = !1, i$1 = !1) : o$2 === R && (s = !1);
383
- continue;
384
- }
385
- D$1 += E, D$1 === F$1 && C$1 < e$1.length - 1 && (t.push(""), D$1 = 0);
386
- }
387
- !D$1 && t[t.length - 1].length > 0 && t.length > 1 && (t[t.length - 2] += t.pop());
388
- }, nD = (t) => {
389
- const u$2 = t.split(" ");
390
- let F$1 = u$2.length;
391
- for (; F$1 > 0 && !(A$1(u$2[F$1 - 1]) > 0);) F$1--;
392
- return F$1 === u$2.length ? t : u$2.slice(0, F$1).join(" ") + u$2.slice(F$1).join("");
393
- }, oD = (t, u$2, F$1 = {}) => {
394
- if (F$1.trim !== !1 && t.trim() === "") return "";
395
- let e$1 = "", s, i$1;
396
- const D$1 = ED(t);
397
- let C$1 = [""];
398
- for (const [E, a$1] of t.split(" ").entries()) {
399
- F$1.trim !== !1 && (C$1[C$1.length - 1] = C$1[C$1.length - 1].trimStart());
400
- let n$1 = A$1(C$1[C$1.length - 1]);
401
- if (E !== 0 && (n$1 >= u$2 && (F$1.wordWrap === !1 || F$1.trim === !1) && (C$1.push(""), n$1 = 0), (n$1 > 0 || F$1.trim === !1) && (C$1[C$1.length - 1] += " ", n$1++)), F$1.hard && D$1[E] > u$2) {
402
- const B$1 = u$2 - n$1, p$1 = 1 + Math.floor((D$1[E] - B$1 - 1) / u$2);
403
- Math.floor((D$1[E] - 1) / u$2) < p$1 && C$1.push(""), _$1(C$1, a$1, u$2);
404
- continue;
405
- }
406
- if (n$1 + D$1[E] > u$2 && n$1 > 0 && D$1[E] > 0) {
407
- if (F$1.wordWrap === !1 && n$1 < u$2) {
408
- _$1(C$1, a$1, u$2);
409
- continue;
410
- }
411
- C$1.push("");
412
- }
413
- if (n$1 + D$1[E] > u$2 && F$1.wordWrap === !1) {
414
- _$1(C$1, a$1, u$2);
415
- continue;
416
- }
417
- C$1[C$1.length - 1] += a$1;
418
- }
419
- F$1.trim !== !1 && (C$1 = C$1.map((E) => nD(E)));
420
- const o$2 = [...C$1.join(`
421
- `)];
422
- for (const [E, a$1] of o$2.entries()) {
423
- if (e$1 += a$1, v.has(a$1)) {
424
- const { groups: B$1 } = (/* @__PURE__ */ new RegExp(`(?:\\${W$1}(?<code>\\d+)m|\\${y}(?<uri>.*)${w$1})`)).exec(o$2.slice(E).join("")) || { groups: {} };
425
- if (B$1.code !== void 0) {
426
- const p$1 = Number.parseFloat(B$1.code);
427
- s = p$1 === CD ? void 0 : p$1;
428
- } else B$1.uri !== void 0 && (i$1 = B$1.uri.length === 0 ? void 0 : B$1.uri);
429
- }
430
- const n$1 = iD.codes.get(Number(s));
431
- o$2[E + 1] === `
432
- ` ? (i$1 && (e$1 += z("")), s && n$1 && (e$1 += V$1(n$1))) : a$1 === `
433
- ` && (s && n$1 && (e$1 += V$1(s)), i$1 && (e$1 += z(i$1)));
434
- }
435
- return e$1;
436
- };
437
- function G(t, u$2, F$1) {
438
- return String(t).normalize().replace(/\r\n/g, `
439
- `).split(`
440
- `).map((e$1) => oD(e$1, u$2, F$1)).join(`
441
- `);
442
- }
443
- const c$1 = {
444
- actions: new Set([
445
- "up",
446
- "down",
447
- "left",
448
- "right",
449
- "space",
450
- "enter",
451
- "cancel"
452
- ]),
453
- aliases: new Map([
454
- ["k", "up"],
455
- ["j", "down"],
456
- ["h", "left"],
457
- ["l", "right"],
458
- ["", "cancel"],
459
- ["escape", "cancel"]
460
- ])
461
- };
462
- function k$1(t, u$2) {
463
- if (typeof t == "string") return c$1.aliases.get(t) === u$2;
464
- for (const F$1 of t) if (F$1 !== void 0 && k$1(F$1, u$2)) return !0;
465
- return !1;
466
- }
467
- function lD(t, u$2) {
468
- if (t === u$2) return;
469
- const F$1 = t.split(`
470
- `), e$1 = u$2.split(`
471
- `), s = [];
472
- for (let i$1 = 0; i$1 < Math.max(F$1.length, e$1.length); i$1++) F$1[i$1] !== e$1[i$1] && s.push(i$1);
473
- return s;
474
- }
475
- const xD = globalThis.process.platform.startsWith("win"), S = Symbol("clack:cancel");
476
- function BD(t) {
477
- return t === S;
478
- }
479
- function d$1(t, u$2) {
480
- const F$1 = t;
481
- F$1.isTTY && F$1.setRawMode(u$2);
482
- }
483
- function cD({ input: t = stdin, output: u$2 = stdout, overwrite: F$1 = !0, hideCursor: e$1 = !0 } = {}) {
484
- const s = f$1.createInterface({
485
- input: t,
486
- output: u$2,
487
- prompt: "",
488
- tabSize: 1
489
- });
490
- f$1.emitKeypressEvents(t, s), t.isTTY && t.setRawMode(!0);
491
- const i$1 = (D$1, { name: C$1, sequence: o$2 }) => {
492
- if (k$1([
493
- String(D$1),
494
- C$1,
495
- o$2
496
- ], "cancel")) {
497
- e$1 && u$2.write(import_src$1.cursor.show), process.exit(0);
498
- return;
499
- }
500
- if (!F$1) return;
501
- const a$1 = C$1 === "return" ? 0 : -1, n$1 = C$1 === "return" ? -1 : 0;
502
- f$1.moveCursor(u$2, a$1, n$1, () => {
503
- f$1.clearLine(u$2, 1, () => {
504
- t.once("keypress", i$1);
505
- });
506
- });
507
- };
508
- return e$1 && u$2.write(import_src$1.cursor.hide), t.once("keypress", i$1), () => {
509
- t.off("keypress", i$1), e$1 && u$2.write(import_src$1.cursor.show), t.isTTY && !xD && t.setRawMode(!1), s.terminal = !1, s.close();
510
- };
511
- }
512
- var AD = Object.defineProperty, pD = (t, u$2, F$1) => u$2 in t ? AD(t, u$2, {
513
- enumerable: !0,
514
- configurable: !0,
515
- writable: !0,
516
- value: F$1
517
- }) : t[u$2] = F$1, h$1 = (t, u$2, F$1) => (pD(t, typeof u$2 != "symbol" ? u$2 + "" : u$2, F$1), F$1);
518
- var x = class {
519
- constructor(u$2, F$1 = !0) {
520
- h$1(this, "input"), h$1(this, "output"), h$1(this, "_abortSignal"), h$1(this, "rl"), h$1(this, "opts"), h$1(this, "_render"), h$1(this, "_track", !1), h$1(this, "_prevFrame", ""), h$1(this, "_subscribers", /* @__PURE__ */ new Map()), h$1(this, "_cursor", 0), h$1(this, "state", "initial"), h$1(this, "error", ""), h$1(this, "value");
521
- const { input: e$1 = stdin, output: s = stdout, render: i$1, signal: D$1,...C$1 } = u$2;
522
- this.opts = C$1, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = i$1.bind(this), this._track = F$1, this._abortSignal = D$1, this.input = e$1, this.output = s;
523
- }
524
- unsubscribe() {
525
- this._subscribers.clear();
526
- }
527
- setSubscriber(u$2, F$1) {
528
- const e$1 = this._subscribers.get(u$2) ?? [];
529
- e$1.push(F$1), this._subscribers.set(u$2, e$1);
530
- }
531
- on(u$2, F$1) {
532
- this.setSubscriber(u$2, { cb: F$1 });
533
- }
534
- once(u$2, F$1) {
535
- this.setSubscriber(u$2, {
536
- cb: F$1,
537
- once: !0
538
- });
539
- }
540
- emit(u$2, ...F$1) {
541
- const e$1 = this._subscribers.get(u$2) ?? [], s = [];
542
- for (const i$1 of e$1) i$1.cb(...F$1), i$1.once && s.push(() => e$1.splice(e$1.indexOf(i$1), 1));
543
- for (const i$1 of s) i$1();
544
- }
545
- prompt() {
546
- return new Promise((u$2, F$1) => {
547
- if (this._abortSignal) {
548
- if (this._abortSignal.aborted) return this.state = "cancel", this.close(), u$2(S);
549
- this._abortSignal.addEventListener("abort", () => {
550
- this.state = "cancel", this.close();
551
- }, { once: !0 });
552
- }
553
- const e$1 = new WriteStream(0);
554
- e$1._write = (s, i$1, D$1) => {
555
- this._track && (this.value = this.rl?.line.replace(/\t/g, ""), this._cursor = this.rl?.cursor ?? 0, this.emit("value", this.value)), D$1();
556
- }, this.input.pipe(e$1), this.rl = M.createInterface({
557
- input: this.input,
558
- output: e$1,
559
- tabSize: 2,
560
- prompt: "",
561
- escapeCodeTimeout: 50
562
- }), M.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), d$1(this.input, !0), this.output.on("resize", this.render), this.render(), this.once("submit", () => {
563
- this.output.write(import_src$1.cursor.show), this.output.off("resize", this.render), d$1(this.input, !1), u$2(this.value);
564
- }), this.once("cancel", () => {
565
- this.output.write(import_src$1.cursor.show), this.output.off("resize", this.render), d$1(this.input, !1), u$2(S);
566
- });
567
- });
568
- }
569
- onKeypress(u$2, F$1) {
570
- if (this.state === "error" && (this.state = "active"), F$1?.name && (!this._track && c$1.aliases.has(F$1.name) && this.emit("cursor", c$1.aliases.get(F$1.name)), c$1.actions.has(F$1.name) && this.emit("cursor", F$1.name)), u$2 && (u$2.toLowerCase() === "y" || u$2.toLowerCase() === "n") && this.emit("confirm", u$2.toLowerCase() === "y"), u$2 === " " && this.opts.placeholder && (this.value || (this.rl?.write(this.opts.placeholder), this.emit("value", this.opts.placeholder))), u$2 && this.emit("key", u$2.toLowerCase()), F$1?.name === "return") {
571
- if (this.opts.validate) {
572
- const e$1 = this.opts.validate(this.value);
573
- e$1 && (this.error = e$1 instanceof Error ? e$1.message : e$1, this.state = "error", this.rl?.write(this.value));
574
- }
575
- this.state !== "error" && (this.state = "submit");
576
- }
577
- k$1([
578
- u$2,
579
- F$1?.name,
580
- F$1?.sequence
581
- ], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
582
- }
583
- close() {
584
- this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
585
- `), d$1(this.input, !1), this.rl?.close(), this.rl = void 0, this.emit(`${this.state}`, this.value), this.unsubscribe();
586
- }
587
- restoreCursor() {
588
- const u$2 = G(this._prevFrame, process.stdout.columns, { hard: !0 }).split(`
589
- `).length - 1;
590
- this.output.write(import_src$1.cursor.move(-999, u$2 * -1));
591
- }
592
- render() {
593
- const u$2 = G(this._render(this) ?? "", process.stdout.columns, { hard: !0 });
594
- if (u$2 !== this._prevFrame) {
595
- if (this.state === "initial") this.output.write(import_src$1.cursor.hide);
596
- else {
597
- const F$1 = lD(this._prevFrame, u$2);
598
- if (this.restoreCursor(), F$1 && F$1?.length === 1) {
599
- const e$1 = F$1[0];
600
- this.output.write(import_src$1.cursor.move(0, e$1)), this.output.write(import_src$1.erase.lines(1));
601
- const s = u$2.split(`
602
- `);
603
- this.output.write(s[e$1]), this._prevFrame = u$2, this.output.write(import_src$1.cursor.move(0, s.length - e$1 - 1));
604
- return;
605
- }
606
- if (F$1 && F$1?.length > 1) {
607
- const e$1 = F$1[0];
608
- this.output.write(import_src$1.cursor.move(0, e$1)), this.output.write(import_src$1.erase.down());
609
- const s = u$2.split(`
610
- `).slice(e$1);
611
- this.output.write(s.join(`
612
- `)), this._prevFrame = u$2;
613
- return;
614
- }
615
- this.output.write(import_src$1.erase.down());
616
- }
617
- this.output.write(u$2), this.state === "initial" && (this.state = "active"), this._prevFrame = u$2;
618
- }
619
- }
620
- };
621
- var fD = class extends x {
622
- get cursor() {
623
- return this.value ? 0 : 1;
624
- }
625
- get _value() {
626
- return this.cursor === 0;
627
- }
628
- constructor(u$2) {
629
- super(u$2, !1), this.value = !!u$2.initialValue, this.on("value", () => {
630
- this.value = this._value;
631
- }), this.on("confirm", (F$1) => {
632
- this.output.write(import_src$1.cursor.move(0, -1)), this.value = F$1, this.state = "submit", this.close();
633
- }), this.on("cursor", () => {
634
- this.value = !this.value;
635
- });
636
- }
637
- };
638
- var gD = Object.defineProperty, vD = (t, u$2, F$1) => u$2 in t ? gD(t, u$2, {
639
- enumerable: !0,
640
- configurable: !0,
641
- writable: !0,
642
- value: F$1
643
- }) : t[u$2] = F$1, K$1 = (t, u$2, F$1) => (vD(t, typeof u$2 != "symbol" ? u$2 + "" : u$2, F$1), F$1);
644
- let dD = class extends x {
645
- constructor(u$2) {
646
- super(u$2, !1), K$1(this, "options"), K$1(this, "cursor", 0);
647
- const { options: F$1 } = u$2;
648
- this.options = Object.entries(F$1).flatMap(([e$1, s]) => [{
649
- value: e$1,
650
- group: !0,
651
- label: e$1
652
- }, ...s.map((i$1) => ({
653
- ...i$1,
654
- group: e$1
655
- }))]), this.value = [...u$2.initialValues ?? []], this.cursor = Math.max(this.options.findIndex(({ value: e$1 }) => e$1 === u$2.cursorAt), 0), this.on("cursor", (e$1) => {
656
- switch (e$1) {
657
- case "left":
658
- case "up":
659
- this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
660
- break;
661
- case "down":
662
- case "right":
663
- this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
664
- break;
665
- case "space":
666
- this.toggleValue();
667
- break;
668
- }
669
- });
670
- }
671
- getGroupItems(u$2) {
672
- return this.options.filter((F$1) => F$1.group === u$2);
673
- }
674
- isGroupSelected(u$2) {
675
- return this.getGroupItems(u$2).every((F$1) => this.value.includes(F$1.value));
676
- }
677
- toggleValue() {
678
- const u$2 = this.options[this.cursor];
679
- if (u$2.group === !0) {
680
- const F$1 = u$2.value, e$1 = this.getGroupItems(F$1);
681
- this.isGroupSelected(F$1) ? this.value = this.value.filter((s) => e$1.findIndex((i$1) => i$1.value === s) === -1) : this.value = [...this.value, ...e$1.map((s) => s.value)], this.value = Array.from(new Set(this.value));
682
- } else this.value = this.value.includes(u$2.value) ? this.value.filter((e$1) => e$1 !== u$2.value) : [...this.value, u$2.value];
683
- }
684
- };
685
- var bD = Object.defineProperty, mD = (t, u$2, F$1) => u$2 in t ? bD(t, u$2, {
686
- enumerable: !0,
687
- configurable: !0,
688
- writable: !0,
689
- value: F$1
690
- }) : t[u$2] = F$1, Y$1 = (t, u$2, F$1) => (mD(t, typeof u$2 != "symbol" ? u$2 + "" : u$2, F$1), F$1);
691
- let wD = class extends x {
692
- constructor(u$2) {
693
- super(u$2, !1), Y$1(this, "options"), Y$1(this, "cursor", 0), this.options = u$2.options, this.value = [...u$2.initialValues ?? []], this.cursor = Math.max(this.options.findIndex(({ value: F$1 }) => F$1 === u$2.cursorAt), 0), this.on("key", (F$1) => {
694
- F$1 === "a" && this.toggleAll();
695
- }), this.on("cursor", (F$1) => {
696
- switch (F$1) {
697
- case "left":
698
- case "up":
699
- this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
700
- break;
701
- case "down":
702
- case "right":
703
- this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
704
- break;
705
- case "space":
706
- this.toggleValue();
707
- break;
708
- }
709
- });
710
- }
711
- get _value() {
712
- return this.options[this.cursor].value;
713
- }
714
- toggleAll() {
715
- this.value = this.value.length === this.options.length ? [] : this.options.map((F$1) => F$1.value);
716
- }
717
- toggleValue() {
718
- this.value = this.value.includes(this._value) ? this.value.filter((F$1) => F$1 !== this._value) : [...this.value, this._value];
719
- }
720
- };
721
- var yD = Object.defineProperty, _D = (t, u$2, F$1) => u$2 in t ? yD(t, u$2, {
722
- enumerable: !0,
723
- configurable: !0,
724
- writable: !0,
725
- value: F$1
726
- }) : t[u$2] = F$1, Z = (t, u$2, F$1) => (_D(t, typeof u$2 != "symbol" ? u$2 + "" : u$2, F$1), F$1);
727
- var kD = class extends x {
728
- constructor({ mask: u$2,...F$1 }) {
729
- super(F$1), Z(this, "valueWithCursor", ""), Z(this, "_mask", "•"), this._mask = u$2 ?? "•", this.on("finalize", () => {
730
- this.valueWithCursor = this.masked;
731
- }), this.on("value", () => {
732
- if (this.cursor >= this.value.length) this.valueWithCursor = `${this.masked}${import_picocolors$1.default.inverse(import_picocolors$1.default.hidden("_"))}`;
733
- else {
734
- const e$1 = this.masked.slice(0, this.cursor), s = this.masked.slice(this.cursor);
735
- this.valueWithCursor = `${e$1}${import_picocolors$1.default.inverse(s[0])}${s.slice(1)}`;
736
- }
737
- });
738
- }
739
- get cursor() {
740
- return this._cursor;
741
- }
742
- get masked() {
743
- return this.value.replaceAll(/./g, this._mask);
744
- }
745
- };
746
- var SD = Object.defineProperty, $D = (t, u$2, F$1) => u$2 in t ? SD(t, u$2, {
747
- enumerable: !0,
748
- configurable: !0,
749
- writable: !0,
750
- value: F$1
751
- }) : t[u$2] = F$1, q$1 = (t, u$2, F$1) => ($D(t, typeof u$2 != "symbol" ? u$2 + "" : u$2, F$1), F$1);
752
- var jD = class extends x {
753
- constructor(u$2) {
754
- super(u$2, !1), q$1(this, "options"), q$1(this, "cursor", 0), this.options = u$2.options, this.cursor = this.options.findIndex(({ value: F$1 }) => F$1 === u$2.initialValue), this.cursor === -1 && (this.cursor = 0), this.changeValue(), this.on("cursor", (F$1) => {
755
- switch (F$1) {
756
- case "left":
757
- case "up":
758
- this.cursor = this.cursor === 0 ? this.options.length - 1 : this.cursor - 1;
759
- break;
760
- case "down":
761
- case "right":
762
- this.cursor = this.cursor === this.options.length - 1 ? 0 : this.cursor + 1;
763
- break;
764
- }
765
- this.changeValue();
766
- });
767
- }
768
- get _value() {
769
- return this.options[this.cursor];
770
- }
771
- changeValue() {
772
- this.value = this._value.value;
773
- }
774
- };
775
- var MD = Object.defineProperty, TD = (t, u$2, F$1) => u$2 in t ? MD(t, u$2, {
776
- enumerable: !0,
777
- configurable: !0,
778
- writable: !0,
779
- value: F$1
780
- }) : t[u$2] = F$1, H = (t, u$2, F$1) => (TD(t, typeof u$2 != "symbol" ? u$2 + "" : u$2, F$1), F$1);
781
- var OD = class extends x {
782
- constructor(u$2) {
783
- super(u$2, !1), H(this, "options"), H(this, "cursor", 0), this.options = u$2.options;
784
- const F$1 = this.options.map(({ value: [e$1] }) => e$1?.toLowerCase());
785
- this.cursor = Math.max(F$1.indexOf(u$2.initialValue), 0), this.on("key", (e$1) => {
786
- if (!F$1.includes(e$1)) return;
787
- const s = this.options.find(({ value: [i$1] }) => i$1?.toLowerCase() === e$1);
788
- s && (this.value = s.value, this.state = "submit", this.emit("submit"));
789
- });
790
- }
791
- };
792
- var PD = class extends x {
793
- get valueWithCursor() {
794
- if (this.state === "submit") return this.value;
795
- if (this.cursor >= this.value.length) return `${this.value}\u2588`;
796
- const u$2 = this.value.slice(0, this.cursor), [F$1, ...e$1] = this.value.slice(this.cursor);
797
- return `${u$2}${import_picocolors$1.default.inverse(F$1)}${e$1.join("")}`;
798
- }
799
- get cursor() {
800
- return this._cursor;
801
- }
802
- constructor(u$2) {
803
- super(u$2), this.on("finalize", () => {
804
- this.value || (this.value = u$2.defaultValue);
805
- });
806
- }
807
- };
808
-
809
- //#endregion
810
- //#region ../../node_modules/.pnpm/@clack+prompts@0.10.0/node_modules/@clack/prompts/dist/index.mjs
811
- var import_picocolors = /* @__PURE__ */ __toESM(require_picocolors(), 1);
812
- var import_src = /* @__PURE__ */ __toESM(require_src(), 1);
813
- function ce() {
814
- return g.platform !== "win32" ? g.env.TERM !== "linux" : !!g.env.CI || !!g.env.WT_SESSION || !!g.env.TERMINUS_SUBLIME || g.env.ConEmuTask === "{cmd::Cmder}" || g.env.TERM_PROGRAM === "Terminus-Sublime" || g.env.TERM_PROGRAM === "vscode" || g.env.TERM === "xterm-256color" || g.env.TERM === "alacritty" || g.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
815
- }
816
- const V = ce(), u$1 = (t, n$1) => V ? t : n$1, le = u$1("◆", "*"), L = u$1("■", "x"), W = u$1("▲", "x"), C = u$1("◇", "o"), ue = u$1("┌", "T"), o$1 = u$1("│", "|"), d = u$1("└", "—"), k = u$1("●", ">"), P = u$1("○", " "), A = u$1("◻", "[•]"), T = u$1("◼", "[+]"), F = u$1("◻", "[ ]"), $e = u$1("▪", "•"), _ = u$1("─", "-"), me = u$1("╮", "+"), de = u$1("├", "+"), pe = u$1("╯", "+"), q = u$1("●", "•"), D = u$1("◆", "*"), U = u$1("▲", "!"), K = u$1("■", "x"), w = (t) => {
817
- switch (t) {
818
- case "initial":
819
- case "active": return import_picocolors.default.cyan(le);
820
- case "cancel": return import_picocolors.default.red(L);
821
- case "error": return import_picocolors.default.yellow(W);
822
- case "submit": return import_picocolors.default.green(C);
823
- }
824
- }, B = (t) => {
825
- const { cursor: n$1, options: s, style: r$1 } = t, i$1 = t.maxItems ?? Number.POSITIVE_INFINITY, a$1 = Math.max(process.stdout.rows - 4, 0), c$2 = Math.min(a$1, Math.max(i$1, 5));
826
- let l$1 = 0;
827
- n$1 >= l$1 + c$2 - 3 ? l$1 = Math.max(Math.min(n$1 - c$2 + 3, s.length - c$2), 0) : n$1 < l$1 + 2 && (l$1 = Math.max(n$1 - 2, 0));
828
- const $$1 = c$2 < s.length && l$1 > 0, p$1 = c$2 < s.length && l$1 + c$2 < s.length;
829
- return s.slice(l$1, l$1 + c$2).map((M$1, v$1, x$1) => {
830
- const j = v$1 === 0 && $$1, E = v$1 === x$1.length - 1 && p$1;
831
- return j || E ? import_picocolors.default.dim("...") : r$1(M$1, v$1 + l$1 === n$1);
832
- });
833
- }, he = (t) => new PD({
834
- validate: t.validate,
835
- placeholder: t.placeholder,
836
- defaultValue: t.defaultValue,
837
- initialValue: t.initialValue,
838
- render() {
839
- const n$1 = `${import_picocolors.default.gray(o$1)}
840
- ${w(this.state)} ${t.message}
841
- `, s = t.placeholder ? import_picocolors.default.inverse(t.placeholder[0]) + import_picocolors.default.dim(t.placeholder.slice(1)) : import_picocolors.default.inverse(import_picocolors.default.hidden("_")), r$1 = this.value ? this.valueWithCursor : s;
842
- switch (this.state) {
843
- case "error": return `${n$1.trim()}
844
- ${import_picocolors.default.yellow(o$1)} ${r$1}
845
- ${import_picocolors.default.yellow(d)} ${import_picocolors.default.yellow(this.error)}
846
- `;
847
- case "submit": return `${n$1}${import_picocolors.default.gray(o$1)} ${import_picocolors.default.dim(this.value || t.placeholder)}`;
848
- case "cancel": return `${n$1}${import_picocolors.default.gray(o$1)} ${import_picocolors.default.strikethrough(import_picocolors.default.dim(this.value ?? ""))}${this.value?.trim() ? `
849
- ${import_picocolors.default.gray(o$1)}` : ""}`;
850
- default: return `${n$1}${import_picocolors.default.cyan(o$1)} ${r$1}
851
- ${import_picocolors.default.cyan(d)}
852
- `;
853
- }
854
- }
855
- }).prompt(), ge = (t) => new kD({
856
- validate: t.validate,
857
- mask: t.mask ?? $e,
858
- render() {
859
- const n$1 = `${import_picocolors.default.gray(o$1)}
860
- ${w(this.state)} ${t.message}
861
- `, s = this.valueWithCursor, r$1 = this.masked;
862
- switch (this.state) {
863
- case "error": return `${n$1.trim()}
864
- ${import_picocolors.default.yellow(o$1)} ${r$1}
865
- ${import_picocolors.default.yellow(d)} ${import_picocolors.default.yellow(this.error)}
866
- `;
867
- case "submit": return `${n$1}${import_picocolors.default.gray(o$1)} ${import_picocolors.default.dim(r$1)}`;
868
- case "cancel": return `${n$1}${import_picocolors.default.gray(o$1)} ${import_picocolors.default.strikethrough(import_picocolors.default.dim(r$1 ?? ""))}${r$1 ? `
869
- ${import_picocolors.default.gray(o$1)}` : ""}`;
870
- default: return `${n$1}${import_picocolors.default.cyan(o$1)} ${s}
871
- ${import_picocolors.default.cyan(d)}
872
- `;
873
- }
874
- }
875
- }).prompt(), ye = (t) => {
876
- const n$1 = t.active ?? "Yes", s = t.inactive ?? "No";
877
- return new fD({
878
- active: n$1,
879
- inactive: s,
880
- initialValue: t.initialValue ?? !0,
881
- render() {
882
- const r$1 = `${import_picocolors.default.gray(o$1)}
883
- ${w(this.state)} ${t.message}
884
- `, i$1 = this.value ? n$1 : s;
885
- switch (this.state) {
886
- case "submit": return `${r$1}${import_picocolors.default.gray(o$1)} ${import_picocolors.default.dim(i$1)}`;
887
- case "cancel": return `${r$1}${import_picocolors.default.gray(o$1)} ${import_picocolors.default.strikethrough(import_picocolors.default.dim(i$1))}
888
- ${import_picocolors.default.gray(o$1)}`;
889
- default: return `${r$1}${import_picocolors.default.cyan(o$1)} ${this.value ? `${import_picocolors.default.green(k)} ${n$1}` : `${import_picocolors.default.dim(P)} ${import_picocolors.default.dim(n$1)}`} ${import_picocolors.default.dim("/")} ${this.value ? `${import_picocolors.default.dim(P)} ${import_picocolors.default.dim(s)}` : `${import_picocolors.default.green(k)} ${s}`}
890
- ${import_picocolors.default.cyan(d)}
891
- `;
892
- }
893
- }
894
- }).prompt();
895
- }, ve = (t) => {
896
- const n$1 = (s, r$1) => {
897
- const i$1 = s.label ?? String(s.value);
898
- switch (r$1) {
899
- case "selected": return `${import_picocolors.default.dim(i$1)}`;
900
- case "active": return `${import_picocolors.default.green(k)} ${i$1} ${s.hint ? import_picocolors.default.dim(`(${s.hint})`) : ""}`;
901
- case "cancelled": return `${import_picocolors.default.strikethrough(import_picocolors.default.dim(i$1))}`;
902
- default: return `${import_picocolors.default.dim(P)} ${import_picocolors.default.dim(i$1)}`;
903
- }
904
- };
905
- return new jD({
906
- options: t.options,
907
- initialValue: t.initialValue,
908
- render() {
909
- const s = `${import_picocolors.default.gray(o$1)}
910
- ${w(this.state)} ${t.message}
911
- `;
912
- switch (this.state) {
913
- case "submit": return `${s}${import_picocolors.default.gray(o$1)} ${n$1(this.options[this.cursor], "selected")}`;
914
- case "cancel": return `${s}${import_picocolors.default.gray(o$1)} ${n$1(this.options[this.cursor], "cancelled")}
915
- ${import_picocolors.default.gray(o$1)}`;
916
- default: return `${s}${import_picocolors.default.cyan(o$1)} ${B({
917
- cursor: this.cursor,
918
- options: this.options,
919
- maxItems: t.maxItems,
920
- style: (r$1, i$1) => n$1(r$1, i$1 ? "active" : "inactive")
921
- }).join(`
922
- ${import_picocolors.default.cyan(o$1)} `)}
923
- ${import_picocolors.default.cyan(d)}
924
- `;
925
- }
926
- }
927
- }).prompt();
928
- }, we = (t) => {
929
- const n$1 = (s, r$1 = "inactive") => {
930
- const i$1 = s.label ?? String(s.value);
931
- return r$1 === "selected" ? `${import_picocolors.default.dim(i$1)}` : r$1 === "cancelled" ? `${import_picocolors.default.strikethrough(import_picocolors.default.dim(i$1))}` : r$1 === "active" ? `${import_picocolors.default.bgCyan(import_picocolors.default.gray(` ${s.value} `))} ${i$1} ${s.hint ? import_picocolors.default.dim(`(${s.hint})`) : ""}` : `${import_picocolors.default.gray(import_picocolors.default.bgWhite(import_picocolors.default.inverse(` ${s.value} `)))} ${i$1} ${s.hint ? import_picocolors.default.dim(`(${s.hint})`) : ""}`;
932
- };
933
- return new OD({
934
- options: t.options,
935
- initialValue: t.initialValue,
936
- render() {
937
- const s = `${import_picocolors.default.gray(o$1)}
938
- ${w(this.state)} ${t.message}
939
- `;
940
- switch (this.state) {
941
- case "submit": return `${s}${import_picocolors.default.gray(o$1)} ${n$1(this.options.find((r$1) => r$1.value === this.value) ?? t.options[0], "selected")}`;
942
- case "cancel": return `${s}${import_picocolors.default.gray(o$1)} ${n$1(this.options[0], "cancelled")}
943
- ${import_picocolors.default.gray(o$1)}`;
944
- default: return `${s}${import_picocolors.default.cyan(o$1)} ${this.options.map((r$1, i$1) => n$1(r$1, i$1 === this.cursor ? "active" : "inactive")).join(`
945
- ${import_picocolors.default.cyan(o$1)} `)}
946
- ${import_picocolors.default.cyan(d)}
947
- `;
948
- }
949
- }
950
- }).prompt();
951
- }, fe = (t) => {
952
- const n$1 = (s, r$1) => {
953
- const i$1 = s.label ?? String(s.value);
954
- return r$1 === "active" ? `${import_picocolors.default.cyan(A)} ${i$1} ${s.hint ? import_picocolors.default.dim(`(${s.hint})`) : ""}` : r$1 === "selected" ? `${import_picocolors.default.green(T)} ${import_picocolors.default.dim(i$1)}` : r$1 === "cancelled" ? `${import_picocolors.default.strikethrough(import_picocolors.default.dim(i$1))}` : r$1 === "active-selected" ? `${import_picocolors.default.green(T)} ${i$1} ${s.hint ? import_picocolors.default.dim(`(${s.hint})`) : ""}` : r$1 === "submitted" ? `${import_picocolors.default.dim(i$1)}` : `${import_picocolors.default.dim(F)} ${import_picocolors.default.dim(i$1)}`;
955
- };
956
- return new wD({
957
- options: t.options,
958
- initialValues: t.initialValues,
959
- required: t.required ?? !0,
960
- cursorAt: t.cursorAt,
961
- validate(s) {
962
- if (this.required && s.length === 0) return `Please select at least one option.
963
- ${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`))}`;
964
- },
965
- render() {
966
- const s = `${import_picocolors.default.gray(o$1)}
967
- ${w(this.state)} ${t.message}
968
- `, r$1 = (i$1, a$1) => {
969
- const c$2 = this.value.includes(i$1.value);
970
- return a$1 && c$2 ? n$1(i$1, "active-selected") : c$2 ? n$1(i$1, "selected") : n$1(i$1, a$1 ? "active" : "inactive");
971
- };
972
- switch (this.state) {
973
- case "submit": return `${s}${import_picocolors.default.gray(o$1)} ${this.options.filter(({ value: i$1 }) => this.value.includes(i$1)).map((i$1) => n$1(i$1, "submitted")).join(import_picocolors.default.dim(", ")) || import_picocolors.default.dim("none")}`;
974
- case "cancel": {
975
- const i$1 = this.options.filter(({ value: a$1 }) => this.value.includes(a$1)).map((a$1) => n$1(a$1, "cancelled")).join(import_picocolors.default.dim(", "));
976
- return `${s}${import_picocolors.default.gray(o$1)} ${i$1.trim() ? `${i$1}
977
- ${import_picocolors.default.gray(o$1)}` : ""}`;
978
- }
979
- case "error": {
980
- const i$1 = this.error.split(`
981
- `).map((a$1, c$2) => c$2 === 0 ? `${import_picocolors.default.yellow(d)} ${import_picocolors.default.yellow(a$1)}` : ` ${a$1}`).join(`
982
- `);
983
- return `${s + import_picocolors.default.yellow(o$1)} ${B({
984
- options: this.options,
985
- cursor: this.cursor,
986
- maxItems: t.maxItems,
987
- style: r$1
988
- }).join(`
989
- ${import_picocolors.default.yellow(o$1)} `)}
990
- ${i$1}
991
- `;
992
- }
993
- default: return `${s}${import_picocolors.default.cyan(o$1)} ${B({
994
- options: this.options,
995
- cursor: this.cursor,
996
- maxItems: t.maxItems,
997
- style: r$1
998
- }).join(`
999
- ${import_picocolors.default.cyan(o$1)} `)}
1000
- ${import_picocolors.default.cyan(d)}
1001
- `;
1002
- }
1003
- }
1004
- }).prompt();
1005
- }, be = (t) => {
1006
- const n$1 = (s, r$1, i$1 = []) => {
1007
- const a$1 = s.label ?? String(s.value), c$2 = typeof s.group == "string", l$1 = c$2 && (i$1[i$1.indexOf(s) + 1] ?? { group: !0 }), $$1 = c$2 && l$1.group === !0, p$1 = c$2 ? `${$$1 ? d : o$1} ` : "";
1008
- return r$1 === "active" ? `${import_picocolors.default.dim(p$1)}${import_picocolors.default.cyan(A)} ${a$1} ${s.hint ? import_picocolors.default.dim(`(${s.hint})`) : ""}` : r$1 === "group-active" ? `${p$1}${import_picocolors.default.cyan(A)} ${import_picocolors.default.dim(a$1)}` : r$1 === "group-active-selected" ? `${p$1}${import_picocolors.default.green(T)} ${import_picocolors.default.dim(a$1)}` : r$1 === "selected" ? `${import_picocolors.default.dim(p$1)}${import_picocolors.default.green(T)} ${import_picocolors.default.dim(a$1)}` : r$1 === "cancelled" ? `${import_picocolors.default.strikethrough(import_picocolors.default.dim(a$1))}` : r$1 === "active-selected" ? `${import_picocolors.default.dim(p$1)}${import_picocolors.default.green(T)} ${a$1} ${s.hint ? import_picocolors.default.dim(`(${s.hint})`) : ""}` : r$1 === "submitted" ? `${import_picocolors.default.dim(a$1)}` : `${import_picocolors.default.dim(p$1)}${import_picocolors.default.dim(F)} ${import_picocolors.default.dim(a$1)}`;
1009
- };
1010
- return new dD({
1011
- options: t.options,
1012
- initialValues: t.initialValues,
1013
- required: t.required ?? !0,
1014
- cursorAt: t.cursorAt,
1015
- validate(s) {
1016
- if (this.required && s.length === 0) return `Please select at least one option.
1017
- ${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`))}`;
1018
- },
1019
- render() {
1020
- const s = `${import_picocolors.default.gray(o$1)}
1021
- ${w(this.state)} ${t.message}
1022
- `;
1023
- switch (this.state) {
1024
- case "submit": return `${s}${import_picocolors.default.gray(o$1)} ${this.options.filter(({ value: r$1 }) => this.value.includes(r$1)).map((r$1) => n$1(r$1, "submitted")).join(import_picocolors.default.dim(", "))}`;
1025
- case "cancel": {
1026
- const r$1 = this.options.filter(({ value: i$1 }) => this.value.includes(i$1)).map((i$1) => n$1(i$1, "cancelled")).join(import_picocolors.default.dim(", "));
1027
- return `${s}${import_picocolors.default.gray(o$1)} ${r$1.trim() ? `${r$1}
1028
- ${import_picocolors.default.gray(o$1)}` : ""}`;
1029
- }
1030
- case "error": {
1031
- const r$1 = this.error.split(`
1032
- `).map((i$1, a$1) => a$1 === 0 ? `${import_picocolors.default.yellow(d)} ${import_picocolors.default.yellow(i$1)}` : ` ${i$1}`).join(`
1033
- `);
1034
- return `${s}${import_picocolors.default.yellow(o$1)} ${this.options.map((i$1, a$1, c$2) => {
1035
- const l$1 = this.value.includes(i$1.value) || i$1.group === !0 && this.isGroupSelected(`${i$1.value}`), $$1 = a$1 === this.cursor;
1036
- return !$$1 && typeof i$1.group == "string" && this.options[this.cursor].value === i$1.group ? n$1(i$1, l$1 ? "group-active-selected" : "group-active", c$2) : $$1 && l$1 ? n$1(i$1, "active-selected", c$2) : l$1 ? n$1(i$1, "selected", c$2) : n$1(i$1, $$1 ? "active" : "inactive", c$2);
1037
- }).join(`
1038
- ${import_picocolors.default.yellow(o$1)} `)}
1039
- ${r$1}
1040
- `;
1041
- }
1042
- default: return `${s}${import_picocolors.default.cyan(o$1)} ${this.options.map((r$1, i$1, a$1) => {
1043
- const c$2 = this.value.includes(r$1.value) || r$1.group === !0 && this.isGroupSelected(`${r$1.value}`), l$1 = i$1 === this.cursor;
1044
- return !l$1 && typeof r$1.group == "string" && this.options[this.cursor].value === r$1.group ? n$1(r$1, c$2 ? "group-active-selected" : "group-active", a$1) : l$1 && c$2 ? n$1(r$1, "active-selected", a$1) : c$2 ? n$1(r$1, "selected", a$1) : n$1(r$1, l$1 ? "active" : "inactive", a$1);
1045
- }).join(`
1046
- ${import_picocolors.default.cyan(o$1)} `)}
1047
- ${import_picocolors.default.cyan(d)}
1048
- `;
1049
- }
1050
- }
1051
- }).prompt();
1052
- }, Me = (t = "", n$1 = "") => {
1053
- const s = `
1054
- ${t}
1055
- `.split(`
1056
- `), r$1 = stripVTControlCharacters(n$1).length, i$1 = Math.max(s.reduce((c$2, l$1) => {
1057
- const $$1 = stripVTControlCharacters(l$1);
1058
- return $$1.length > c$2 ? $$1.length : c$2;
1059
- }, 0), r$1) + 2, a$1 = s.map((c$2) => `${import_picocolors.default.gray(o$1)} ${import_picocolors.default.dim(c$2)}${" ".repeat(i$1 - stripVTControlCharacters(c$2).length)}${import_picocolors.default.gray(o$1)}`).join(`
1060
- `);
1061
- process.stdout.write(`${import_picocolors.default.gray(o$1)}
1062
- ${import_picocolors.default.green(C)} ${import_picocolors.default.reset(n$1)} ${import_picocolors.default.gray(_.repeat(Math.max(i$1 - r$1 - 1, 1)) + me)}
1063
- ${a$1}
1064
- ${import_picocolors.default.gray(de + _.repeat(i$1 + 2) + pe)}
1065
- `);
1066
- }, xe = (t = "") => {
1067
- process.stdout.write(`${import_picocolors.default.gray(d)} ${import_picocolors.default.red(t)}
1068
-
1069
- `);
1070
- }, Ie = (t = "") => {
1071
- process.stdout.write(`${import_picocolors.default.gray(ue)} ${t}
1072
- `);
1073
- }, Se = (t = "") => {
1074
- process.stdout.write(`${import_picocolors.default.gray(o$1)}
1075
- ${import_picocolors.default.gray(d)} ${t}
1076
-
1077
- `);
1078
- }, f = {
1079
- message: (t = "", { symbol: n$1 = import_picocolors.default.gray(o$1) } = {}) => {
1080
- const s = [`${import_picocolors.default.gray(o$1)}`];
1081
- if (t) {
1082
- const [r$1, ...i$1] = t.split(`
1083
- `);
1084
- s.push(`${n$1} ${r$1}`, ...i$1.map((a$1) => `${import_picocolors.default.gray(o$1)} ${a$1}`));
1085
- }
1086
- process.stdout.write(`${s.join(`
1087
- `)}
1088
- `);
1089
- },
1090
- info: (t) => {
1091
- f.message(t, { symbol: import_picocolors.default.blue(q) });
1092
- },
1093
- success: (t) => {
1094
- f.message(t, { symbol: import_picocolors.default.green(D) });
1095
- },
1096
- step: (t) => {
1097
- f.message(t, { symbol: import_picocolors.default.green(C) });
1098
- },
1099
- warn: (t) => {
1100
- f.message(t, { symbol: import_picocolors.default.yellow(U) });
1101
- },
1102
- warning: (t) => {
1103
- f.warn(t);
1104
- },
1105
- error: (t) => {
1106
- f.message(t, { symbol: import_picocolors.default.red(K) });
1107
- }
1108
- }, J = `${import_picocolors.default.gray(o$1)} `, b = {
1109
- message: async (t, { symbol: n$1 = import_picocolors.default.gray(o$1) } = {}) => {
1110
- process.stdout.write(`${import_picocolors.default.gray(o$1)}
1111
- ${n$1} `);
1112
- let s = 3;
1113
- for await (let r$1 of t) {
1114
- r$1 = r$1.replace(/\n/g, `
1115
- ${J}`), r$1.includes(`
1116
- `) && (s = 3 + stripVTControlCharacters(r$1.slice(r$1.lastIndexOf(`
1117
- `))).length);
1118
- const i$1 = stripVTControlCharacters(r$1).length;
1119
- s + i$1 < process.stdout.columns ? (s += i$1, process.stdout.write(r$1)) : (process.stdout.write(`
1120
- ${J}${r$1.trimStart()}`), s = 3 + stripVTControlCharacters(r$1.trimStart()).length);
1121
- }
1122
- process.stdout.write(`
1123
- `);
1124
- },
1125
- info: (t) => b.message(t, { symbol: import_picocolors.default.blue(q) }),
1126
- success: (t) => b.message(t, { symbol: import_picocolors.default.green(D) }),
1127
- step: (t) => b.message(t, { symbol: import_picocolors.default.green(C) }),
1128
- warn: (t) => b.message(t, { symbol: import_picocolors.default.yellow(U) }),
1129
- warning: (t) => b.warn(t),
1130
- error: (t) => b.message(t, { symbol: import_picocolors.default.red(K) })
1131
- }, Y = ({ indicator: t = "dots" } = {}) => {
1132
- const n$1 = V ? [
1133
- "◒",
1134
- "◐",
1135
- "◓",
1136
- "◑"
1137
- ] : [
1138
- "•",
1139
- "o",
1140
- "O",
1141
- "0"
1142
- ], s = V ? 80 : 120, r$1 = process.env.CI === "true";
1143
- let i$1, a$1, c$2 = !1, l$1 = "", $$1, p$1 = performance.now();
1144
- const M$1 = (m$1) => {
1145
- c$2 && N$1(m$1 > 1 ? "Something went wrong" : "Canceled", m$1);
1146
- }, v$1 = () => M$1(2), x$1 = () => M$1(1), j = () => {
1147
- process.on("uncaughtExceptionMonitor", v$1), process.on("unhandledRejection", v$1), process.on("SIGINT", x$1), process.on("SIGTERM", x$1), process.on("exit", M$1);
1148
- }, E = () => {
1149
- process.removeListener("uncaughtExceptionMonitor", v$1), process.removeListener("unhandledRejection", v$1), process.removeListener("SIGINT", x$1), process.removeListener("SIGTERM", x$1), process.removeListener("exit", M$1);
1150
- }, O$1 = () => {
1151
- if ($$1 === void 0) return;
1152
- r$1 && process.stdout.write(`
1153
- `);
1154
- const m$1 = $$1.split(`
1155
- `);
1156
- process.stdout.write(import_src.cursor.move(-999, m$1.length - 1)), process.stdout.write(import_src.erase.down(m$1.length));
1157
- }, R$1 = (m$1) => m$1.replace(/\.+$/, ""), G$1 = (m$1) => {
1158
- const h$2 = (performance.now() - m$1) / 1e3, y$1 = Math.floor(h$2 / 60), I$1 = Math.floor(h$2 % 60);
1159
- return y$1 > 0 ? `[${y$1}m ${I$1}s]` : `[${I$1}s]`;
1160
- }, H$1 = (m$1 = "") => {
1161
- c$2 = !0, i$1 = cD(), l$1 = R$1(m$1), p$1 = performance.now(), process.stdout.write(`${import_picocolors.default.gray(o$1)}
1162
- `);
1163
- let h$2 = 0, y$1 = 0;
1164
- j(), a$1 = setInterval(() => {
1165
- if (r$1 && l$1 === $$1) return;
1166
- O$1(), $$1 = l$1;
1167
- const I$1 = import_picocolors.default.magenta(n$1[h$2]);
1168
- if (r$1) process.stdout.write(`${I$1} ${l$1}...`);
1169
- else if (t === "timer") process.stdout.write(`${I$1} ${l$1} ${G$1(p$1)}`);
1170
- else {
1171
- const z$1 = ".".repeat(Math.floor(y$1)).slice(0, 3);
1172
- process.stdout.write(`${I$1} ${l$1}${z$1}`);
1173
- }
1174
- h$2 = h$2 + 1 < n$1.length ? h$2 + 1 : 0, y$1 = y$1 < n$1.length ? y$1 + .125 : 0;
1175
- }, s);
1176
- }, N$1 = (m$1 = "", h$2 = 0) => {
1177
- c$2 = !1, clearInterval(a$1), O$1();
1178
- const y$1 = h$2 === 0 ? import_picocolors.default.green(C) : h$2 === 1 ? import_picocolors.default.red(L) : import_picocolors.default.red(W);
1179
- l$1 = R$1(m$1 ?? l$1), t === "timer" ? process.stdout.write(`${y$1} ${l$1} ${G$1(p$1)}
1180
- `) : process.stdout.write(`${y$1} ${l$1}
1181
- `), E(), i$1();
1182
- };
1183
- return {
1184
- start: H$1,
1185
- stop: N$1,
1186
- message: (m$1 = "") => {
1187
- l$1 = R$1(m$1 ?? l$1);
1188
- }
1189
- };
1190
- }, Ce = async (t, n$1) => {
1191
- const s = {}, r$1 = Object.keys(t);
1192
- for (const i$1 of r$1) {
1193
- const a$1 = t[i$1], c$2 = await a$1({ results: s })?.catch((l$1) => {
1194
- throw l$1;
1195
- });
1196
- if (typeof n$1?.onCancel == "function" && BD(c$2)) {
1197
- s[i$1] = "canceled", n$1.onCancel({ results: s });
1198
- continue;
1199
- }
1200
- s[i$1] = c$2;
1201
- }
1202
- return s;
1203
- }, Te = async (t) => {
1204
- for (const n$1 of t) {
1205
- if (n$1.enabled === !1) continue;
1206
- const s = Y();
1207
- s.start(n$1.title);
1208
- const r$1 = await n$1.task(s.message);
1209
- s.stop(r$1 || n$1.title);
1210
- }
1211
- };
1212
-
1213
48
  //#endregion
1214
49
  //#region ../../node_modules/.pnpm/es-toolkit@1.32.0/node_modules/es-toolkit/dist/error/AbortError.mjs
1215
50
  var AbortError = class extends Error {
@@ -1398,20 +233,20 @@ const parseExpression = (expression) => {
1398
233
  if (expression instanceof ChildProcess || Object.prototype.toString.call(expression) === "[object Promise]") throw new TypeError("Unexpected subprocess in template expression. Please use ${await subprocess} instead of ${subprocess}.");
1399
234
  throw new TypeError(`Unexpected "${typeOfExpression}" in template expression`);
1400
235
  };
1401
- const getSubprocessResult = ({ stdout: stdout$1 }) => {
1402
- if (typeof stdout$1 === "string") return stdout$1;
1403
- if (isUint8Array(stdout$1)) return uint8ArrayToString(stdout$1);
1404
- if (stdout$1 === void 0) throw new TypeError("Missing result.stdout in template expression. This is probably due to the previous subprocess' \"stdout\" option.");
1405
- throw new TypeError(`Unexpected "${typeof stdout$1}" stdout in template expression`);
236
+ const getSubprocessResult = ({ stdout }) => {
237
+ if (typeof stdout === "string") return stdout;
238
+ if (isUint8Array(stdout)) return uint8ArrayToString(stdout);
239
+ if (stdout === void 0) throw new TypeError("Missing result.stdout in template expression. This is probably due to the previous subprocess' \"stdout\" option.");
240
+ throw new TypeError(`Unexpected "${typeof stdout}" stdout in template expression`);
1406
241
  };
1407
242
 
1408
243
  //#endregion
1409
244
  //#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/utils/standard-stream.js
1410
245
  const isStandardStream = (stream) => STANDARD_STREAMS.includes(stream);
1411
246
  const STANDARD_STREAMS = [
1412
- g.stdin,
1413
- g.stdout,
1414
- g.stderr
247
+ process$1.stdin,
248
+ process$1.stdout,
249
+ process$1.stderr
1415
250
  ];
1416
251
  const STANDARD_STREAMS_ALIASES = [
1417
252
  "stdin",
@@ -1536,10 +371,10 @@ const NO_ESCAPE_REGEXP = /^[\w./-]+$/;
1536
371
  //#endregion
1537
372
  //#region ../../node_modules/.pnpm/is-unicode-supported@2.1.0/node_modules/is-unicode-supported/index.js
1538
373
  function isUnicodeSupported() {
1539
- const { env: env$1 } = g;
1540
- const { TERM, TERM_PROGRAM } = env$1;
1541
- if (g.platform !== "win32") return TERM !== "linux";
1542
- return Boolean(env$1.WT_SESSION) || Boolean(env$1.TERMINUS_SUBLIME) || env$1.ConEmuTask === "{cmd::Cmder}" || TERM_PROGRAM === "Terminus-Sublime" || TERM_PROGRAM === "vscode" || TERM === "xterm-256color" || TERM === "alacritty" || TERM === "rxvt-unicode" || TERM === "rxvt-unicode-256color" || env$1.TERMINAL_EMULATOR === "JetBrains-JediTerm";
374
+ const { env } = process$1;
375
+ const { TERM, TERM_PROGRAM } = env;
376
+ if (process$1.platform !== "win32") return TERM !== "linux";
377
+ return Boolean(env.WT_SESSION) || Boolean(env.TERMINUS_SUBLIME) || env.ConEmuTask === "{cmd::Cmder}" || TERM_PROGRAM === "Terminus-Sublime" || TERM_PROGRAM === "vscode" || TERM === "xterm-256color" || TERM === "alacritty" || TERM === "rxvt-unicode" || TERM === "rxvt-unicode-256color" || env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
1543
378
  }
1544
379
 
1545
380
  //#endregion
@@ -2079,11 +914,11 @@ var require_mode = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm/isexe@
2079
914
  var gid = stat.gid;
2080
915
  var myUid = options.uid !== void 0 ? options.uid : process.getuid && process.getuid();
2081
916
  var myGid = options.gid !== void 0 ? options.gid : process.getgid && process.getgid();
2082
- var u$2 = parseInt("100", 8);
2083
- var g$2 = parseInt("010", 8);
2084
- var o$2 = parseInt("001", 8);
2085
- var ug = u$2 | g$2;
2086
- return mod & o$2 || mod & g$2 && gid === myGid || mod & u$2 && uid === myUid || mod & ug && myUid === 0;
917
+ var u$1 = parseInt("100", 8);
918
+ var g = parseInt("010", 8);
919
+ var o$1 = parseInt("001", 8);
920
+ var ug = u$1 | g;
921
+ return mod & o$1 || mod & g && gid === myGid || mod & u$1 && uid === myUid || mod & ug && myUid === 0;
2087
922
  }
2088
923
  }) });
2089
924
 
@@ -2222,7 +1057,7 @@ var require_resolveCommand = /* @__PURE__ */ __commonJS({ "../../node_modules/.p
2222
1057
  const which = require_which();
2223
1058
  const getPathKey = require_path_key();
2224
1059
  function resolveCommandAttempt(parsed, withoutPathExt) {
2225
- const env$1 = parsed.options.env || process.env;
1060
+ const env = parsed.options.env || process.env;
2226
1061
  const cwd = process.cwd();
2227
1062
  const hasCustomCwd = parsed.options.cwd != null;
2228
1063
  const shouldSwitchCwd = hasCustomCwd && process.chdir !== void 0 && !process.chdir.disabled;
@@ -2232,10 +1067,10 @@ var require_resolveCommand = /* @__PURE__ */ __commonJS({ "../../node_modules/.p
2232
1067
  let resolved;
2233
1068
  try {
2234
1069
  resolved = which.sync(parsed.command, {
2235
- path: env$1[getPathKey({ env: env$1 })],
1070
+ path: env[getPathKey({ env })],
2236
1071
  pathExt: withoutPathExt ? path$3.delimiter : void 0
2237
1072
  });
2238
- } catch (e$1) {} finally {
1073
+ } catch (e) {} finally {
2239
1074
  if (shouldSwitchCwd) process.chdir(cwd);
2240
1075
  }
2241
1076
  if (resolved) resolved = path$3.resolve(hasCustomCwd ? parsed.options.cwd : "", resolved);
@@ -2301,7 +1136,7 @@ var require_readShebang = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm
2301
1136
  fd = fs$1.openSync(command, "r");
2302
1137
  fs$1.readSync(fd, buffer, 0, size, 0);
2303
1138
  fs$1.closeSync(fd);
2304
- } catch (e$1) {}
1139
+ } catch (e) {}
2305
1140
  return shebangCommand(buffer.toString());
2306
1141
  }
2307
1142
  module.exports = readShebang$1;
@@ -2438,9 +1273,9 @@ var require_cross_spawn = /* @__PURE__ */ __commonJS({ "../../node_modules/.pnpm
2438
1273
  //#region ../../node_modules/.pnpm/path-key@4.0.0/node_modules/path-key/index.js
2439
1274
  var import_cross_spawn = /* @__PURE__ */ __toESM(require_cross_spawn(), 1);
2440
1275
  function pathKey(options = {}) {
2441
- const { env: env$1 = process.env, platform: platform$1 = process.platform } = options;
1276
+ const { env = process.env, platform: platform$1 = process.platform } = options;
2442
1277
  if (platform$1 !== "win32") return "PATH";
2443
- return Object.keys(env$1).reverse().find((key) => key.toUpperCase() === "PATH") || "Path";
1278
+ return Object.keys(env).reverse().find((key) => key.toUpperCase() === "PATH") || "Path";
2444
1279
  }
2445
1280
 
2446
1281
  //#endregion
@@ -2464,7 +1299,7 @@ const TEN_MEGABYTES_IN_BYTES = 10 * 1024 * 1024;
2464
1299
 
2465
1300
  //#endregion
2466
1301
  //#region ../../node_modules/.pnpm/npm-run-path@6.0.0/node_modules/npm-run-path/index.js
2467
- const npmRunPath = ({ cwd = g.cwd(), path: pathOption = g.env[pathKey()], preferLocal = true, execPath: execPath$1 = g.execPath, addExecPath = true } = {}) => {
1302
+ const npmRunPath = ({ cwd = process$1.cwd(), path: pathOption = process$1.env[pathKey()], preferLocal = true, execPath: execPath$1 = process$1.execPath, addExecPath = true } = {}) => {
2468
1303
  const cwdPath = path.resolve(toPath(cwd));
2469
1304
  const result = [];
2470
1305
  const pathParts = pathOption.split(path.delimiter);
@@ -2482,12 +1317,12 @@ const applyExecPath = (result, pathParts, execPath$1, cwdPath) => {
2482
1317
  const pathPart = path.resolve(cwdPath, toPath(execPath$1), "..");
2483
1318
  if (!pathParts.includes(pathPart)) result.push(pathPart);
2484
1319
  };
2485
- const npmRunPathEnv = ({ env: env$1 = g.env,...options } = {}) => {
2486
- env$1 = { ...env$1 };
2487
- const pathName = pathKey({ env: env$1 });
2488
- options.path = env$1[pathName];
2489
- env$1[pathName] = npmRunPath(options);
2490
- return env$1;
1320
+ const npmRunPathEnv = ({ env = process$1.env,...options } = {}) => {
1321
+ env = { ...env };
1322
+ const pathName = pathKey({ env });
1323
+ options.path = env[pathName];
1324
+ env[pathName] = npmRunPath(options);
1325
+ return env;
2491
1326
  };
2492
1327
 
2493
1328
  //#endregion
@@ -3091,15 +1926,15 @@ const getInvalidStdioOptionMessage = (fdNumber, fdName, options, isWritable) =>
3091
1926
  return `The "${optionName}: ${serializeOptionValue(optionValue)}" option is incompatible with using "${getOptionName(isWritable)}: ${serializeOptionValue(fdName)}".
3092
1927
  Please set this option with "pipe" instead.`;
3093
1928
  };
3094
- const getInvalidStdioOption = (fdNumber, { stdin: stdin$1, stdout: stdout$1, stderr, stdio }) => {
1929
+ const getInvalidStdioOption = (fdNumber, { stdin, stdout, stderr, stdio }) => {
3095
1930
  const usedDescriptor = getUsedDescriptor(fdNumber);
3096
- if (usedDescriptor === 0 && stdin$1 !== void 0) return {
1931
+ if (usedDescriptor === 0 && stdin !== void 0) return {
3097
1932
  optionName: "stdin",
3098
- optionValue: stdin$1
1933
+ optionValue: stdin
3099
1934
  };
3100
- if (usedDescriptor === 1 && stdout$1 !== void 0) return {
1935
+ if (usedDescriptor === 1 && stdout !== void 0) return {
3101
1936
  optionName: "stdout",
3102
- optionValue: stdout$1
1937
+ optionValue: stdout
3103
1938
  };
3104
1939
  if (usedDescriptor === 2 && stderr !== void 0) return {
3105
1940
  optionName: "stderr",
@@ -3617,7 +2452,7 @@ const normalizeCwd = (cwd = getDefaultCwd()) => {
3617
2452
  };
3618
2453
  const getDefaultCwd = () => {
3619
2454
  try {
3620
- return g.cwd();
2455
+ return process$1.cwd();
3621
2456
  } catch (error) {
3622
2457
  error.message = `The current directory does not exist.\n${error.message}`;
3623
2458
  throw error;
@@ -3652,7 +2487,7 @@ const normalizeOptions = (filePath, rawArguments, rawOptions) => {
3652
2487
  options.killSignal = normalizeKillSignal(options.killSignal);
3653
2488
  options.forceKillAfterDelay = normalizeForceKillAfterDelay(options.forceKillAfterDelay);
3654
2489
  options.lines = options.lines.map((lines, fdNumber) => lines && !BINARY_ENCODINGS.has(options.encoding) && options.buffer[fdNumber]);
3655
- if (g.platform === "win32" && path.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
2490
+ if (process$1.platform === "win32" && path.basename(file, ".exe") === "cmd") commandArguments.unshift("/q");
3656
2491
  return {
3657
2492
  file,
3658
2493
  commandArguments,
@@ -3678,18 +2513,18 @@ const addDefaultOptions = ({ extendEnv = true, preferLocal = false, cwd, localDi
3678
2513
  serialization
3679
2514
  });
3680
2515
  const getEnv = ({ env: envOption, extendEnv, preferLocal, node, localDirectory, nodePath }) => {
3681
- const env$1 = extendEnv ? {
3682
- ...g.env,
2516
+ const env = extendEnv ? {
2517
+ ...process$1.env,
3683
2518
  ...envOption
3684
2519
  } : envOption;
3685
2520
  if (preferLocal || node) return npmRunPathEnv({
3686
- env: env$1,
2521
+ env,
3687
2522
  cwd: localDirectory,
3688
2523
  execPath: nodePath,
3689
2524
  preferLocal,
3690
2525
  addExecPath: node
3691
2526
  });
3692
- return env$1;
2527
+ return env;
3693
2528
  };
3694
2529
 
3695
2530
  //#endregion
@@ -3732,15 +2567,15 @@ var c = class {
3732
2567
  #n;
3733
2568
  #r = !1;
3734
2569
  #e = void 0;
3735
- constructor(e$1, t) {
3736
- this.#t = e$1, this.#n = t;
2570
+ constructor(e, t) {
2571
+ this.#t = e, this.#n = t;
3737
2572
  }
3738
2573
  next() {
3739
- const e$1 = () => this.#s();
3740
- return this.#e = this.#e ? this.#e.then(e$1, e$1) : e$1(), this.#e;
2574
+ const e = () => this.#s();
2575
+ return this.#e = this.#e ? this.#e.then(e, e) : e(), this.#e;
3741
2576
  }
3742
- return(e$1) {
3743
- const t = () => this.#i(e$1);
2577
+ return(e) {
2578
+ const t = () => this.#i(e);
3744
2579
  return this.#e ? this.#e.then(t, t) : t();
3745
2580
  }
3746
2581
  async #s() {
@@ -3748,29 +2583,29 @@ var c = class {
3748
2583
  done: !0,
3749
2584
  value: void 0
3750
2585
  };
3751
- let e$1;
2586
+ let e;
3752
2587
  try {
3753
- e$1 = await this.#t.read();
2588
+ e = await this.#t.read();
3754
2589
  } catch (t) {
3755
2590
  throw this.#e = void 0, this.#r = !0, this.#t.releaseLock(), t;
3756
2591
  }
3757
- return e$1.done && (this.#e = void 0, this.#r = !0, this.#t.releaseLock()), e$1;
2592
+ return e.done && (this.#e = void 0, this.#r = !0, this.#t.releaseLock()), e;
3758
2593
  }
3759
- async #i(e$1) {
2594
+ async #i(e) {
3760
2595
  if (this.#r) return {
3761
2596
  done: !0,
3762
- value: e$1
2597
+ value: e
3763
2598
  };
3764
2599
  if (this.#r = !0, !this.#n) {
3765
- const t = this.#t.cancel(e$1);
2600
+ const t = this.#t.cancel(e);
3766
2601
  return this.#t.releaseLock(), await t, {
3767
2602
  done: !0,
3768
- value: e$1
2603
+ value: e
3769
2604
  };
3770
2605
  }
3771
2606
  return this.#t.releaseLock(), {
3772
2607
  done: !0,
3773
- value: e$1
2608
+ value: e
3774
2609
  };
3775
2610
  }
3776
2611
  };
@@ -3779,8 +2614,8 @@ function i() {
3779
2614
  return this[n].next();
3780
2615
  }
3781
2616
  Object.defineProperty(i, "name", { value: "next" });
3782
- function o(r$1) {
3783
- return this[n].return(r$1);
2617
+ function o(r) {
2618
+ return this[n].return(r);
3784
2619
  }
3785
2620
  Object.defineProperty(o, "name", { value: "return" });
3786
2621
  const u = Object.create(a, {
@@ -3797,8 +2632,8 @@ const u = Object.create(a, {
3797
2632
  value: o
3798
2633
  }
3799
2634
  });
3800
- function h({ preventCancel: r$1 = !1 } = {}) {
3801
- const t = new c(this.getReader(), r$1), s = Object.create(u);
2635
+ function h({ preventCancel: r = !1 } = {}) {
2636
+ const t = new c(this.getReader(), r), s = Object.create(u);
3802
2637
  return s[n] = t, s;
3803
2638
  }
3804
2639
 
@@ -4667,12 +3502,12 @@ const guessStreamDirection = {
4667
3502
  }
4668
3503
  };
4669
3504
  const getStandardStreamDirection = (value) => {
4670
- if ([0, g.stdin].includes(value)) return "input";
3505
+ if ([0, process$1.stdin].includes(value)) return "input";
4671
3506
  if ([
4672
3507
  1,
4673
3508
  2,
4674
- g.stdout,
4675
- g.stderr
3509
+ process$1.stdout,
3510
+ process$1.stderr
4676
3511
  ].includes(value)) return "output";
4677
3512
  };
4678
3513
  const DEFAULT_DIRECTION = "output";
@@ -4697,7 +3532,7 @@ const getStdioArray = (stdio, options) => {
4697
3532
  ];
4698
3533
  if (!Array.isArray(stdio)) throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof stdio}\``);
4699
3534
  const length = Math.max(stdio.length, STANDARD_STREAMS_ALIASES.length);
4700
- return Array.from({ length }, (_$2, fdNumber) => stdio[fdNumber]);
3535
+ return Array.from({ length }, (_, fdNumber) => stdio[fdNumber]);
4701
3536
  };
4702
3537
  const hasAlias = (options) => STANDARD_STREAMS_ALIASES.some((alias) => options[alias] !== void 0);
4703
3538
  const addDefaultValue = (stdioOption, fdNumber) => {
@@ -5430,14 +4265,14 @@ const writeToFiles = (serializedResult, stdioItems, outputFiles) => {
5430
4265
 
5431
4266
  //#endregion
5432
4267
  //#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/resolve/all-sync.js
5433
- const getAllSync = ([, stdout$1, stderr], options) => {
4268
+ const getAllSync = ([, stdout, stderr], options) => {
5434
4269
  if (!options.all) return;
5435
- if (stdout$1 === void 0) return stderr;
5436
- if (stderr === void 0) return stdout$1;
5437
- if (Array.isArray(stdout$1)) return Array.isArray(stderr) ? [...stdout$1, ...stderr] : [...stdout$1, stripNewline(stderr, options, "all")];
5438
- if (Array.isArray(stderr)) return [stripNewline(stdout$1, options, "all"), ...stderr];
5439
- if (isUint8Array(stdout$1) && isUint8Array(stderr)) return concatUint8Arrays([stdout$1, stderr]);
5440
- return `${stdout$1}${stderr}`;
4270
+ if (stdout === void 0) return stderr;
4271
+ if (stderr === void 0) return stdout;
4272
+ if (Array.isArray(stdout)) return Array.isArray(stderr) ? [...stdout, ...stderr] : [...stdout, stripNewline(stderr, options, "all")];
4273
+ if (Array.isArray(stderr)) return [stripNewline(stdout, options, "all"), ...stderr];
4274
+ if (isUint8Array(stdout) && isUint8Array(stderr)) return concatUint8Arrays([stdout, stderr]);
4275
+ return `${stdout}${stderr}`;
5441
4276
  };
5442
4277
 
5443
4278
  //#endregion
@@ -5736,9 +4571,9 @@ const addIpcMethods = (subprocess, { ipc }) => {
5736
4571
  Object.assign(subprocess, getIpcMethods(subprocess, false, ipc));
5737
4572
  };
5738
4573
  const getIpcExport = () => {
5739
- const anyProcess = g;
4574
+ const anyProcess = process$1;
5740
4575
  const isSubprocess = true;
5741
- const ipc = g.channel !== void 0;
4576
+ const ipc = process$1.channel !== void 0;
5742
4577
  return {
5743
4578
  ...getIpcMethods(anyProcess, isSubprocess, ipc),
5744
4579
  getCancelSignal: getCancelSignal$1.bind(void 0, {
@@ -5795,20 +4630,20 @@ const handleEarlyError = ({ error, command, escapedCommand, fileDescriptors, opt
5795
4630
  };
5796
4631
  };
5797
4632
  const createDummyStreams = (subprocess, fileDescriptors) => {
5798
- const stdin$1 = createDummyStream();
5799
- const stdout$1 = createDummyStream();
4633
+ const stdin = createDummyStream();
4634
+ const stdout = createDummyStream();
5800
4635
  const stderr = createDummyStream();
5801
4636
  const extraStdio = Array.from({ length: fileDescriptors.length - 3 }, createDummyStream);
5802
4637
  const all = createDummyStream();
5803
4638
  const stdio = [
5804
- stdin$1,
5805
- stdout$1,
4639
+ stdin,
4640
+ stdout,
5806
4641
  stderr,
5807
4642
  ...extraStdio
5808
4643
  ];
5809
4644
  Object.assign(subprocess, {
5810
- stdin: stdin$1,
5811
- stdout: stdout$1,
4645
+ stdin,
4646
+ stdout,
5812
4647
  stderr,
5813
4648
  all,
5814
4649
  stdio
@@ -6147,7 +4982,7 @@ if (process.platform === "linux") signals.push("SIGIO", "SIGPOLL", "SIGPWR", "SI
6147
4982
 
6148
4983
  //#endregion
6149
4984
  //#region ../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/index.js
6150
- const processOk = (process$2) => !!process$2 && typeof process$2 === "object" && typeof process$2.removeListener === "function" && typeof process$2.emit === "function" && typeof process$2.reallyExit === "function" && typeof process$2.listeners === "function" && typeof process$2.kill === "function" && typeof process$2.pid === "number" && typeof process$2.on === "function";
4985
+ const processOk = (process$3) => !!process$3 && typeof process$3 === "object" && typeof process$3.removeListener === "function" && typeof process$3.emit === "function" && typeof process$3.reallyExit === "function" && typeof process$3.listeners === "function" && typeof process$3.kill === "function" && typeof process$3.pid === "number" && typeof process$3.on === "function";
6151
4986
  const kExitEmitter = Symbol.for("signal-exit emitter");
6152
4987
  const global$1 = globalThis;
6153
4988
  const ObjectDefineProperty = Object.defineProperty.bind(Object);
@@ -6215,7 +5050,7 @@ var SignalExitFallback = class extends SignalExitBase {
6215
5050
  };
6216
5051
  var SignalExit = class extends SignalExitBase {
6217
5052
  /* c8 ignore start */
6218
- #hupSig = process$1.platform === "win32" ? "SIGINT" : "SIGHUP";
5053
+ #hupSig = process$2.platform === "win32" ? "SIGINT" : "SIGHUP";
6219
5054
  /* c8 ignore stop */
6220
5055
  #emitter = new Emitter();
6221
5056
  #process;
@@ -6223,15 +5058,15 @@ var SignalExit = class extends SignalExitBase {
6223
5058
  #originalProcessReallyExit;
6224
5059
  #sigListeners = {};
6225
5060
  #loaded = false;
6226
- constructor(process$2) {
5061
+ constructor(process$3) {
6227
5062
  super();
6228
- this.#process = process$2;
5063
+ this.#process = process$3;
6229
5064
  this.#sigListeners = {};
6230
5065
  for (const sig of signals) this.#sigListeners[sig] = () => {
6231
5066
  const listeners = this.#process.listeners(sig);
6232
5067
  let { count: count$1 } = this.#emitter;
6233
5068
  /* c8 ignore start */
6234
- const p$1 = process$2;
5069
+ const p$1 = process$3;
6235
5070
  if (typeof p$1.__signal_exit_emitter__ === "object" && typeof p$1.__signal_exit_emitter__.count === "number") count$1 += p$1.__signal_exit_emitter__.count;
6236
5071
  /* c8 ignore stop */
6237
5072
  if (listeners.length === count$1) {
@@ -6239,11 +5074,11 @@ var SignalExit = class extends SignalExitBase {
6239
5074
  const ret = this.#emitter.emit("exit", null, sig);
6240
5075
  /* c8 ignore start */
6241
5076
  const s = sig === "SIGHUP" ? this.#hupSig : sig;
6242
- if (!ret) process$2.kill(process$2.pid, s);
5077
+ if (!ret) process$3.kill(process$3.pid, s);
6243
5078
  }
6244
5079
  };
6245
- this.#originalProcessReallyExit = process$2.reallyExit;
6246
- this.#originalProcessEmit = process$2.emit;
5080
+ this.#originalProcessReallyExit = process$3.reallyExit;
5081
+ this.#originalProcessEmit = process$3.emit;
6247
5082
  }
6248
5083
  onExit(cb, opts) {
6249
5084
  /* c8 ignore start */
@@ -6264,7 +5099,7 @@ var SignalExit = class extends SignalExitBase {
6264
5099
  for (const sig of signals) try {
6265
5100
  const fn = this.#sigListeners[sig];
6266
5101
  if (fn) this.#process.on(sig, fn);
6267
- } catch (_$2) {}
5102
+ } catch (_) {}
6268
5103
  this.#process.emit = (ev, ...a$1) => {
6269
5104
  return this.#processEmit(ev, ...a$1);
6270
5105
  };
@@ -6282,7 +5117,7 @@ var SignalExit = class extends SignalExitBase {
6282
5117
  /* c8 ignore stop */
6283
5118
  try {
6284
5119
  this.#process.removeListener(sig, listener);
6285
- } catch (_$2) {}
5120
+ } catch (_) {}
6286
5121
  /* c8 ignore stop */
6287
5122
  });
6288
5123
  this.#process.emit = this.#originalProcessEmit;
@@ -6310,8 +5145,8 @@ var SignalExit = class extends SignalExitBase {
6310
5145
  } else return og.call(this.#process, ev, ...args);
6311
5146
  }
6312
5147
  };
6313
- const process$1 = globalThis.process;
6314
- const { onExit, load, unload } = signalExitWrap(processOk(process$1) ? new SignalExit(process$1) : new SignalExitFallback());
5148
+ const process$2 = globalThis.process;
5149
+ const { onExit, load, unload } = signalExitWrap(processOk(process$2) ? new SignalExit(process$2) : new SignalExitFallback());
6315
5150
 
6316
5151
  //#endregion
6317
5152
  //#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/terminate/cleanup.js
@@ -6780,7 +5615,7 @@ const waitForSubprocessStream = async ({ stream, fdNumber, encoding, buffer, max
6780
5615
 
6781
5616
  //#endregion
6782
5617
  //#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/resolve/all-async.js
6783
- const makeAllStream = ({ stdout: stdout$1, stderr }, { all }) => all && (stdout$1 || stderr) ? mergeStreams([stdout$1, stderr].filter(Boolean)) : void 0;
5618
+ const makeAllStream = ({ stdout, stderr }, { all }) => all && (stdout || stderr) ? mergeStreams([stdout, stderr].filter(Boolean)) : void 0;
6784
5619
  const waitForAllStream = ({ subprocess, encoding, buffer, maxBuffer, lines, stripFinalNewline: stripFinalNewline$1, verboseInfo, streamInfo }) => waitForSubprocessStream({
6785
5620
  ...getAllStream(subprocess, buffer),
6786
5621
  fdNumber: "all",
@@ -6792,7 +5627,7 @@ const waitForAllStream = ({ subprocess, encoding, buffer, maxBuffer, lines, stri
6792
5627
  verboseInfo,
6793
5628
  streamInfo
6794
5629
  });
6795
- const getAllStream = ({ stdout: stdout$1, stderr, all }, [, bufferStdout, bufferStderr]) => {
5630
+ const getAllStream = ({ stdout, stderr, all }, [, bufferStdout, bufferStderr]) => {
6796
5631
  const buffer = bufferStdout || bufferStderr;
6797
5632
  if (!buffer) return {
6798
5633
  stream: all,
@@ -6803,7 +5638,7 @@ const getAllStream = ({ stdout: stdout$1, stderr, all }, [, bufferStdout, buffer
6803
5638
  buffer
6804
5639
  };
6805
5640
  if (!bufferStderr) return {
6806
- stream: stdout$1,
5641
+ stream: stdout,
6807
5642
  buffer
6808
5643
  };
6809
5644
  return {
@@ -6811,7 +5646,7 @@ const getAllStream = ({ stdout: stdout$1, stderr, all }, [, bufferStdout, buffer
6811
5646
  buffer
6812
5647
  };
6813
5648
  };
6814
- const getAllMixed = ({ all, stdout: stdout$1, stderr }) => all && stdout$1 && stderr && stdout$1.readableObjectMode !== stderr.readableObjectMode;
5649
+ const getAllMixed = ({ all, stdout, stderr }) => all && stdout && stderr && stdout.readableObjectMode !== stderr.readableObjectMode;
6815
5650
 
6816
5651
  //#endregion
6817
5652
  //#region ../../node_modules/.pnpm/execa@9.5.2/node_modules/execa/lib/verbose/ipc.js
@@ -7616,7 +6451,7 @@ project_id = "%%projectId%%"
7616
6451
  enabled = false
7617
6452
  `;
7618
6453
  const selectProject = async () => {
7619
- const spinner = Y();
6454
+ const spinner = p.spinner();
7620
6455
  spinner.start("Fetching Supabase projects...");
7621
6456
  let projectsProcess = [];
7622
6457
  try {
@@ -7636,7 +6471,7 @@ const selectProject = async () => {
7636
6471
  }
7637
6472
  spinner.stop();
7638
6473
  const createProjectOption = `create/${Math.random().toString(36).substring(2, 15)}`;
7639
- const selectedProjectId = await ve({
6474
+ const selectedProjectId = await p.select({
7640
6475
  message: "Select a Supabase project",
7641
6476
  options: [...projectsProcess.map((project) => ({
7642
6477
  label: `${project.name} (${project.region})`,
@@ -7646,7 +6481,7 @@ const selectProject = async () => {
7646
6481
  value: createProjectOption
7647
6482
  }]
7648
6483
  });
7649
- if (BD(selectedProjectId)) process.exit(0);
6484
+ if (p.isCancel(selectedProjectId)) process.exit(0);
7650
6485
  if (selectedProjectId === createProjectOption) {
7651
6486
  try {
7652
6487
  await execa("npx", [
@@ -7672,7 +6507,7 @@ const selectProject = async () => {
7672
6507
  const selectBucket = async (api) => {
7673
6508
  let buckets = [];
7674
6509
  let retryCount = 0;
7675
- await Te([{
6510
+ await p.tasks([{
7676
6511
  title: "Fetching bucket list...",
7677
6512
  task: async (message) => {
7678
6513
  while (retryCount < 300) try {
@@ -7683,12 +6518,12 @@ const selectBucket = async (api) => {
7683
6518
  retryCount++;
7684
6519
  await delay(1e3);
7685
6520
  }
7686
- f.error("Failed to fetch bucket list");
6521
+ p.log.error("Failed to fetch bucket list");
7687
6522
  process.exit(1);
7688
6523
  }
7689
6524
  }]);
7690
6525
  const createBucketOption = `create/${Math.random().toString(36).substring(2, 15)}`;
7691
- const selectedBucketId = await ve({
6526
+ const selectedBucketId = await p.select({
7692
6527
  message: "Select a storage bucket",
7693
6528
  options: [...buckets.map((bucket) => ({
7694
6529
  label: bucket.name,
@@ -7701,13 +6536,13 @@ const selectBucket = async (api) => {
7701
6536
  value: createBucketOption
7702
6537
  }]
7703
6538
  });
7704
- if (BD(selectedBucketId)) process.exit(0);
6539
+ if (p.isCancel(selectedBucketId)) process.exit(0);
7705
6540
  if (selectedBucketId === createBucketOption) {
7706
- const bucketName = await he({ message: "Enter a name for the new bucket" });
7707
- if (BD(bucketName)) process.exit(0);
6541
+ const bucketName = await p.text({ message: "Enter a name for the new bucket" });
6542
+ if (p.isCancel(bucketName)) process.exit(0);
7708
6543
  try {
7709
6544
  await api.createBucket(bucketName, { public: false });
7710
- f.success(`Bucket "${bucketName}" created successfully.`);
6545
+ p.log.success(`Bucket "${bucketName}" created successfully.`);
7711
6546
  const newBucket = (await api.listBuckets()).find((bucket) => bucket.name === bucketName);
7712
6547
  if (!newBucket) throw new Error("Failed to create and select new bucket");
7713
6548
  return {
@@ -7715,14 +6550,14 @@ const selectBucket = async (api) => {
7715
6550
  name: newBucket.name
7716
6551
  };
7717
6552
  } catch (err) {
7718
- f.error(`Failed to create new bucket: ${err}`);
6553
+ p.log.error(`Failed to create new bucket: ${err}`);
7719
6554
  process.exit(1);
7720
6555
  }
7721
6556
  }
7722
6557
  return JSON.parse(selectedBucketId);
7723
6558
  };
7724
6559
  const linkSupabase = async (workdir, { projectId, dbPassword }) => {
7725
- const spinner = Y();
6560
+ const spinner = p.spinner();
7726
6561
  try {
7727
6562
  await fs.writeFile(path$1.join(workdir, "supabase", "config.toml"), transformTemplate(SUPABASE_CONFIG_TEMPLATE, { projectId }));
7728
6563
  spinner.start("Linking Supabase...");
@@ -7746,7 +6581,7 @@ const linkSupabase = async (workdir, { projectId, dbPassword }) => {
7746
6581
  spinner.stop("Supabase linked ✔");
7747
6582
  } catch (err) {
7748
6583
  spinner.stop();
7749
- if (err instanceof ExecaError && err.stderr) f.error(err.stderr);
6584
+ if (err instanceof ExecaError && err.stderr) p.log.error(err.stderr);
7750
6585
  else console.error(err);
7751
6586
  process.exit(1);
7752
6587
  }
@@ -7764,28 +6599,28 @@ const pushDB = async (workdir, { dbPassword }) => {
7764
6599
  stdio: "inherit",
7765
6600
  shell: true
7766
6601
  });
7767
- f.success("DB pushed ✔");
6602
+ p.log.success("DB pushed ✔");
7768
6603
  return dbPush.stdout;
7769
6604
  } catch (err) {
7770
- if (err instanceof ExecaError && err.stderr) f.error(err.stderr);
6605
+ if (err instanceof ExecaError && err.stderr) p.log.error(err.stderr);
7771
6606
  else console.error(err);
7772
6607
  process.exit(1);
7773
6608
  }
7774
6609
  };
7775
6610
  const deployEdgeFunction = async (workdir, projectId) => {
7776
- const functionName = await he({
6611
+ const functionName = await p.text({
7777
6612
  message: "Enter a name for the edge function",
7778
6613
  initialValue: "update-server",
7779
6614
  placeholder: "update-server"
7780
6615
  });
7781
- if (BD(functionName)) process.exit(0);
6616
+ if (p.isCancel(functionName)) process.exit(0);
7782
6617
  const edgeFunctionsLibPath = path$1.join(workdir, "supabase", "edge-functions");
7783
6618
  const edgeFunctionsCode = transformEnv(path$1.join(edgeFunctionsLibPath, "index.ts"), { FUNCTION_NAME: functionName });
7784
6619
  const targetDir = path$1.join(workdir, "supabase", "functions", functionName);
7785
6620
  await fs.mkdir(targetDir, { recursive: true });
7786
6621
  const targetPath = path$1.join(targetDir, "index.ts");
7787
6622
  await fs.writeFile(targetPath, edgeFunctionsCode);
7788
- await Te([{
6623
+ await p.tasks([{
7789
6624
  title: "Supabase edge function deploy. This may take a few minutes.",
7790
6625
  task: async () => {
7791
6626
  try {
@@ -7801,7 +6636,7 @@ const deployEdgeFunction = async (workdir, projectId) => {
7801
6636
  workdir
7802
6637
  ], { cwd: workdir })).stdout;
7803
6638
  } catch (err) {
7804
- if (err instanceof ExecaError && err.stderr) f.error(err.stderr);
6639
+ if (err instanceof ExecaError && err.stderr) p.log.error(err.stderr);
7805
6640
  else console.error(err);
7806
6641
  process.exit(1);
7807
6642
  }
@@ -7810,7 +6645,7 @@ const deployEdgeFunction = async (workdir, projectId) => {
7810
6645
  };
7811
6646
  const runInit = async ({ build }) => {
7812
6647
  const project = await selectProject();
7813
- const spinner = Y();
6648
+ const spinner = p.spinner();
7814
6649
  spinner.start(`Getting API keys for ${project.name}...`);
7815
6650
  let apiKeys = [];
7816
6651
  try {
@@ -7842,8 +6677,8 @@ const runInit = async ({ build }) => {
7842
6677
  const content = await fs.readFile(filePath, "utf-8");
7843
6678
  await fs.writeFile(filePath, transformTemplate(content, { BUCKET_NAME: bucket.name }));
7844
6679
  }
7845
- const dbPassword = await ge({ message: "Enter your Supabase database password (press Enter to skip if none)" });
7846
- if (BD(dbPassword)) process.exit(0);
6680
+ const dbPassword = await p.password({ message: "Enter your Supabase database password (press Enter to skip if none)" });
6681
+ if (p.isCancel(dbPassword)) process.exit(0);
7847
6682
  await linkSupabase(tmpDir, {
7848
6683
  projectId: project.id,
7849
6684
  dbPassword
@@ -7857,11 +6692,11 @@ const runInit = async ({ build }) => {
7857
6692
  HOT_UPDATER_SUPABASE_BUCKET_NAME: bucket.name,
7858
6693
  HOT_UPDATER_SUPABASE_URL: `https://${project.id}.supabase.co`
7859
6694
  });
7860
- f.success("Generated '.env.hotupdater' file with Supabase settings.");
7861
- f.success("Generated 'hot-updater.config.ts' file with Supabase settings.");
7862
- Me(transformTemplate(SOURCE_TEMPLATE, { source: `https://${project.id}.supabase.co/functions/v1/update-server` }));
7863
- f.message(`Next step: ${link("https://hot-updater.dev/docs/managed/supabase#step-4-add-hotupdater-to-your-project")}`);
7864
- f.success("Done! 🎉");
6695
+ p.log.success("Generated '.env.hotupdater' file with Supabase settings.");
6696
+ p.log.success("Generated 'hot-updater.config.ts' file with Supabase settings.");
6697
+ p.note(transformTemplate(SOURCE_TEMPLATE, { source: `https://${project.id}.supabase.co/functions/v1/update-server` }));
6698
+ p.log.message(`Next step: ${link("https://hot-updater.dev/docs/managed/supabase#step-4-add-hotupdater-to-your-project")}`);
6699
+ p.log.success("Done! 🎉");
7865
6700
  };
7866
6701
 
7867
6702
  //#endregion