@shopify/create-app 4.6.1 → 4.7.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (51) hide show
  1. package/dist/{analytics-HXZNGNCN.js → analytics-A7XUM3DE.js} +16 -13
  2. package/dist/analytics-CVOS4X5D.js +44 -0
  3. package/dist/{chunk-CMK3RV4O.js → chunk-5LLHAM5N.js} +9 -6
  4. package/dist/{chunk-JK6PBDEW.js → chunk-A67PO4UO.js} +17 -17
  5. package/dist/{chunk-TNZEM7JJ.js → chunk-AOCVCJS6.js} +17 -14
  6. package/dist/{chunk-ZGSDAUKG.js → chunk-B7LXQVGX.js} +21809 -346
  7. package/dist/chunk-CM6ALOD7.js +32 -0
  8. package/dist/{chunk-K5NLRHZR.js → chunk-E43EDJOG.js} +4 -4
  9. package/dist/{chunk-N7J64MYF.js → chunk-FU4STSWX.js} +27 -18
  10. package/dist/{chunk-VLCFLRJB.js → chunk-HHKEZAAX.js} +2 -2
  11. package/dist/chunk-HNIAZN6U.js +14 -0
  12. package/dist/chunk-JMC4PKOZ.js +1391 -0
  13. package/dist/chunk-LEQAULOW.js +179 -0
  14. package/dist/chunk-PK2M5CKS.js +7350 -0
  15. package/dist/{chunk-ZUKA5LQU.js → chunk-TGZSJFOF.js} +4509 -7671
  16. package/dist/{chunk-QK2IQEBY.js → chunk-VJHCFG5K.js} +2 -2
  17. package/dist/chunk-X2X377NR.js +301 -0
  18. package/dist/{chunk-3JSJSGAQ.js → chunk-XYNOPL42.js} +2 -2
  19. package/dist/{chunk-ZLYYWQWW.js → chunk-YYJ6EVI6.js} +3 -3
  20. package/dist/{chunk-K5UHKI43.js → chunk-ZPNNBR5Z.js} +33 -58
  21. package/dist/{conf-store-ZYB6IGB7.js → conf-store-NT7HUXZL.js} +9 -7
  22. package/dist/{custom-oclif-loader-MNCB3QFM.js → custom-oclif-loader-HTLL62HO.js} +15 -15
  23. package/dist/{deprecations-FOMUQSMA.js → deprecations-37ZUNG4Z.js} +12 -9
  24. package/dist/{environments-SWXYO6KQ.js → environments-ISQBBMTF.js} +13 -10
  25. package/dist/{error-handler-PXVIL3GI.js → error-handler-GGBOXL7F.js} +16 -13
  26. package/dist/{fs-FVYWMVWY.js → fs-ZG73KWF7.js} +4 -3
  27. package/dist/hooks/postrun.js +5 -4
  28. package/dist/hooks/prerun.js +26 -8
  29. package/dist/index.js +2008 -1819
  30. package/dist/index.test.js +8 -8
  31. package/dist/{is-global-QP5DA2PW.js → is-global-DL3ZQWOO.js} +4 -3
  32. package/dist/{lib-SEAHPNPA.js → lib-XCYUJYSO.js} +3 -3
  33. package/dist/{local-FQ2FNAKK.js → local-XAHKS4F6.js} +3 -2
  34. package/dist/{metadata-7RRKVERI.js → metadata-4WOIDT2F.js} +4 -3
  35. package/dist/{node-package-manager-7MTYEDAO.js → node-package-manager-JO3BBXYZ.js} +14 -11
  36. package/dist/{notifications-system-GHCK5E2U.js → notifications-system-ZK44GBNG.js} +17 -14
  37. package/dist/os-XDQECFDE.js +19 -0
  38. package/dist/{output-7VC5AJM7.js → output-2RGSJNA6.js} +4 -3
  39. package/dist/{system-OTGPJVTA.js → system-KQM7CSD6.js} +14 -9
  40. package/dist/tsconfig.tsbuildinfo +1 -1
  41. package/dist/{ui-3H6HVYPD.js → ui-UAVSRCJ7.js} +12 -9
  42. package/dist/{upgrade-AYIRDOVJ.js → upgrade-QE6OI6PW.js} +23 -20
  43. package/dist/{version-CCMJSEAI.js → version-6CVFB4SF.js} +13 -10
  44. package/dist/{version-OHC3XUOI.js → version-AALUTWIR.js} +2 -2
  45. package/oclif.manifest.json +11 -7
  46. package/package.json +3 -3
  47. package/dist/analytics-GP57RR6R.js +0 -39
  48. package/dist/chunk-BPIA4T3X.js +0 -655
  49. package/dist/chunk-HNMF25KI.js +0 -5632
  50. package/dist/chunk-T446SGE5.js +0 -21746
  51. package/dist/is-wsl-63MHD6QC.js +0 -65
@@ -0,0 +1,1391 @@
1
+ import {
2
+ mimicFunction
3
+ } from "./chunk-CM6ALOD7.js";
4
+ import {
5
+ require_get_stream
6
+ } from "./chunk-JGGOQOPO.js";
7
+ import {
8
+ outputContent,
9
+ outputDebug
10
+ } from "./chunk-PK2M5CKS.js";
11
+ import {
12
+ __commonJS,
13
+ __require,
14
+ __toESM,
15
+ init_cjs_shims
16
+ } from "./chunk-3XNI6LP4.js";
17
+
18
+ // ../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js
19
+ var require_windows = __commonJS({
20
+ "../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/windows.js"(exports, module) {
21
+ init_cjs_shims();
22
+ module.exports = isexe;
23
+ isexe.sync = sync;
24
+ var fs = __require("fs");
25
+ function checkPathExt(path3, options) {
26
+ var pathext = options.pathExt !== void 0 ? options.pathExt : process.env.PATHEXT;
27
+ if (!pathext || (pathext = pathext.split(";"), pathext.indexOf("") !== -1))
28
+ return !0;
29
+ for (var i = 0; i < pathext.length; i++) {
30
+ var p = pathext[i].toLowerCase();
31
+ if (p && path3.substr(-p.length).toLowerCase() === p)
32
+ return !0;
33
+ }
34
+ return !1;
35
+ }
36
+ function checkStat(stat, path3, options) {
37
+ return !stat.isSymbolicLink() && !stat.isFile() ? !1 : checkPathExt(path3, options);
38
+ }
39
+ function isexe(path3, options, cb) {
40
+ fs.stat(path3, function(er, stat) {
41
+ cb(er, er ? !1 : checkStat(stat, path3, options));
42
+ });
43
+ }
44
+ function sync(path3, options) {
45
+ return checkStat(fs.statSync(path3), path3, options);
46
+ }
47
+ }
48
+ });
49
+
50
+ // ../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js
51
+ var require_mode = __commonJS({
52
+ "../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/mode.js"(exports, module) {
53
+ init_cjs_shims();
54
+ module.exports = isexe;
55
+ isexe.sync = sync;
56
+ var fs = __require("fs");
57
+ function isexe(path3, options, cb) {
58
+ fs.stat(path3, function(er, stat) {
59
+ cb(er, er ? !1 : checkStat(stat, options));
60
+ });
61
+ }
62
+ function sync(path3, options) {
63
+ return checkStat(fs.statSync(path3), options);
64
+ }
65
+ function checkStat(stat, options) {
66
+ return stat.isFile() && checkMode(stat, options);
67
+ }
68
+ function checkMode(stat, options) {
69
+ var mod = stat.mode, uid = stat.uid, gid = stat.gid, myUid = options.uid !== void 0 ? options.uid : process.getuid && process.getuid(), myGid = options.gid !== void 0 ? options.gid : process.getgid && process.getgid(), u = parseInt("100", 8), g = parseInt("010", 8), o = parseInt("001", 8), ug = u | g, ret = mod & o || mod & g && gid === myGid || mod & u && uid === myUid || mod & ug && myUid === 0;
70
+ return ret;
71
+ }
72
+ }
73
+ });
74
+
75
+ // ../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js
76
+ var require_isexe = __commonJS({
77
+ "../../node_modules/.pnpm/isexe@2.0.0/node_modules/isexe/index.js"(exports, module) {
78
+ init_cjs_shims();
79
+ var fs = __require("fs"), core;
80
+ process.platform === "win32" || global.TESTING_WINDOWS ? core = require_windows() : core = require_mode();
81
+ module.exports = isexe;
82
+ isexe.sync = sync;
83
+ function isexe(path3, options, cb) {
84
+ if (typeof options == "function" && (cb = options, options = {}), !cb) {
85
+ if (typeof Promise != "function")
86
+ throw new TypeError("callback not provided");
87
+ return new Promise(function(resolve, reject) {
88
+ isexe(path3, options || {}, function(er, is) {
89
+ er ? reject(er) : resolve(is);
90
+ });
91
+ });
92
+ }
93
+ core(path3, options || {}, function(er, is) {
94
+ er && (er.code === "EACCES" || options && options.ignoreErrors) && (er = null, is = !1), cb(er, is);
95
+ });
96
+ }
97
+ function sync(path3, options) {
98
+ try {
99
+ return core.sync(path3, options || {});
100
+ } catch (er) {
101
+ if (options && options.ignoreErrors || er.code === "EACCES")
102
+ return !1;
103
+ throw er;
104
+ }
105
+ }
106
+ }
107
+ });
108
+
109
+ // ../../node_modules/.pnpm/which@2.0.2/node_modules/which/which.js
110
+ var require_which = __commonJS({
111
+ "../../node_modules/.pnpm/which@2.0.2/node_modules/which/which.js"(exports, module) {
112
+ init_cjs_shims();
113
+ var isWindows = process.platform === "win32" || process.env.OSTYPE === "cygwin" || process.env.OSTYPE === "msys", path3 = __require("path"), COLON = isWindows ? ";" : ":", isexe = require_isexe(), getNotFoundError = (cmd) => Object.assign(new Error(`not found: ${cmd}`), { code: "ENOENT" }), getPathInfo = (cmd, opt) => {
114
+ let colon = opt.colon || COLON, pathEnv = cmd.match(/\//) || isWindows && cmd.match(/\\/) ? [""] : [
115
+ // windows always checks the cwd first
116
+ ...isWindows ? [process.cwd()] : [],
117
+ ...(opt.path || process.env.PATH || /* istanbul ignore next: very unusual */
118
+ "").split(colon)
119
+ ], pathExtExe = isWindows ? opt.pathExt || process.env.PATHEXT || ".EXE;.CMD;.BAT;.COM" : "", pathExt = isWindows ? pathExtExe.split(colon) : [""];
120
+ return isWindows && cmd.indexOf(".") !== -1 && pathExt[0] !== "" && pathExt.unshift(""), {
121
+ pathEnv,
122
+ pathExt,
123
+ pathExtExe
124
+ };
125
+ }, which = (cmd, opt, cb) => {
126
+ typeof opt == "function" && (cb = opt, opt = {}), opt || (opt = {});
127
+ let { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt), found = [], step = (i) => new Promise((resolve, reject) => {
128
+ if (i === pathEnv.length)
129
+ return opt.all && found.length ? resolve(found) : reject(getNotFoundError(cmd));
130
+ let ppRaw = pathEnv[i], pathPart = /^".*"$/.test(ppRaw) ? ppRaw.slice(1, -1) : ppRaw, pCmd = path3.join(pathPart, cmd), p = !pathPart && /^\.[\\\/]/.test(cmd) ? cmd.slice(0, 2) + pCmd : pCmd;
131
+ resolve(subStep(p, i, 0));
132
+ }), subStep = (p, i, ii) => new Promise((resolve, reject) => {
133
+ if (ii === pathExt.length)
134
+ return resolve(step(i + 1));
135
+ let ext = pathExt[ii];
136
+ isexe(p + ext, { pathExt: pathExtExe }, (er, is) => {
137
+ if (!er && is)
138
+ if (opt.all)
139
+ found.push(p + ext);
140
+ else
141
+ return resolve(p + ext);
142
+ return resolve(subStep(p, i, ii + 1));
143
+ });
144
+ });
145
+ return cb ? step(0).then((res) => cb(null, res), cb) : step(0);
146
+ }, whichSync = (cmd, opt) => {
147
+ opt = opt || {};
148
+ let { pathEnv, pathExt, pathExtExe } = getPathInfo(cmd, opt), found = [];
149
+ for (let i = 0; i < pathEnv.length; i++) {
150
+ let ppRaw = pathEnv[i], pathPart = /^".*"$/.test(ppRaw) ? ppRaw.slice(1, -1) : ppRaw, pCmd = path3.join(pathPart, cmd), p = !pathPart && /^\.[\\\/]/.test(cmd) ? cmd.slice(0, 2) + pCmd : pCmd;
151
+ for (let j = 0; j < pathExt.length; j++) {
152
+ let cur = p + pathExt[j];
153
+ try {
154
+ if (isexe.sync(cur, { pathExt: pathExtExe }))
155
+ if (opt.all)
156
+ found.push(cur);
157
+ else
158
+ return cur;
159
+ } catch {
160
+ }
161
+ }
162
+ }
163
+ if (opt.all && found.length)
164
+ return found;
165
+ if (opt.nothrow)
166
+ return null;
167
+ throw getNotFoundError(cmd);
168
+ };
169
+ module.exports = which;
170
+ which.sync = whichSync;
171
+ }
172
+ });
173
+
174
+ // ../../node_modules/.pnpm/path-key@3.1.1/node_modules/path-key/index.js
175
+ var require_path_key = __commonJS({
176
+ "../../node_modules/.pnpm/path-key@3.1.1/node_modules/path-key/index.js"(exports, module) {
177
+ "use strict";
178
+ init_cjs_shims();
179
+ var pathKey2 = (options = {}) => {
180
+ let environment = options.env || process.env;
181
+ return (options.platform || process.platform) !== "win32" ? "PATH" : Object.keys(environment).reverse().find((key) => key.toUpperCase() === "PATH") || "Path";
182
+ };
183
+ module.exports = pathKey2;
184
+ module.exports.default = pathKey2;
185
+ }
186
+ });
187
+
188
+ // ../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/resolveCommand.js
189
+ var require_resolveCommand = __commonJS({
190
+ "../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/resolveCommand.js"(exports, module) {
191
+ "use strict";
192
+ init_cjs_shims();
193
+ var path3 = __require("path"), which = require_which(), getPathKey = require_path_key();
194
+ function resolveCommandAttempt(parsed, withoutPathExt) {
195
+ let env = parsed.options.env || process.env, cwd = process.cwd(), hasCustomCwd = parsed.options.cwd != null, shouldSwitchCwd = hasCustomCwd && process.chdir !== void 0 && !process.chdir.disabled;
196
+ if (shouldSwitchCwd)
197
+ try {
198
+ process.chdir(parsed.options.cwd);
199
+ } catch {
200
+ }
201
+ let resolved;
202
+ try {
203
+ resolved = which.sync(parsed.command, {
204
+ path: env[getPathKey({ env })],
205
+ pathExt: withoutPathExt ? path3.delimiter : void 0
206
+ });
207
+ } catch {
208
+ } finally {
209
+ shouldSwitchCwd && process.chdir(cwd);
210
+ }
211
+ return resolved && (resolved = path3.resolve(hasCustomCwd ? parsed.options.cwd : "", resolved)), resolved;
212
+ }
213
+ function resolveCommand(parsed) {
214
+ return resolveCommandAttempt(parsed) || resolveCommandAttempt(parsed, !0);
215
+ }
216
+ module.exports = resolveCommand;
217
+ }
218
+ });
219
+
220
+ // ../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/escape.js
221
+ var require_escape = __commonJS({
222
+ "../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/escape.js"(exports, module) {
223
+ "use strict";
224
+ init_cjs_shims();
225
+ var metaCharsRegExp = /([()\][%!^"`<>&|;, *?])/g;
226
+ function escapeCommand(arg) {
227
+ return arg = arg.replace(metaCharsRegExp, "^$1"), arg;
228
+ }
229
+ function escapeArgument(arg, doubleEscapeMetaChars) {
230
+ return arg = `${arg}`, arg = arg.replace(/(?=(\\+?)?)\1"/g, '$1$1\\"'), arg = arg.replace(/(?=(\\+?)?)\1$/, "$1$1"), arg = `"${arg}"`, arg = arg.replace(metaCharsRegExp, "^$1"), doubleEscapeMetaChars && (arg = arg.replace(metaCharsRegExp, "^$1")), arg;
231
+ }
232
+ module.exports.command = escapeCommand;
233
+ module.exports.argument = escapeArgument;
234
+ }
235
+ });
236
+
237
+ // ../../node_modules/.pnpm/shebang-regex@3.0.0/node_modules/shebang-regex/index.js
238
+ var require_shebang_regex = __commonJS({
239
+ "../../node_modules/.pnpm/shebang-regex@3.0.0/node_modules/shebang-regex/index.js"(exports, module) {
240
+ "use strict";
241
+ init_cjs_shims();
242
+ module.exports = /^#!(.*)/;
243
+ }
244
+ });
245
+
246
+ // ../../node_modules/.pnpm/shebang-command@2.0.0/node_modules/shebang-command/index.js
247
+ var require_shebang_command = __commonJS({
248
+ "../../node_modules/.pnpm/shebang-command@2.0.0/node_modules/shebang-command/index.js"(exports, module) {
249
+ "use strict";
250
+ init_cjs_shims();
251
+ var shebangRegex = require_shebang_regex();
252
+ module.exports = (string = "") => {
253
+ let match = string.match(shebangRegex);
254
+ if (!match)
255
+ return null;
256
+ let [path3, argument] = match[0].replace(/#! ?/, "").split(" "), binary = path3.split("/").pop();
257
+ return binary === "env" ? argument : argument ? `${binary} ${argument}` : binary;
258
+ };
259
+ }
260
+ });
261
+
262
+ // ../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/readShebang.js
263
+ var require_readShebang = __commonJS({
264
+ "../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/util/readShebang.js"(exports, module) {
265
+ "use strict";
266
+ init_cjs_shims();
267
+ var fs = __require("fs"), shebangCommand = require_shebang_command();
268
+ function readShebang(command) {
269
+ let buffer = Buffer.alloc(150), fd;
270
+ try {
271
+ fd = fs.openSync(command, "r"), fs.readSync(fd, buffer, 0, 150, 0), fs.closeSync(fd);
272
+ } catch {
273
+ }
274
+ return shebangCommand(buffer.toString());
275
+ }
276
+ module.exports = readShebang;
277
+ }
278
+ });
279
+
280
+ // ../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/parse.js
281
+ var require_parse = __commonJS({
282
+ "../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/parse.js"(exports, module) {
283
+ "use strict";
284
+ init_cjs_shims();
285
+ var path3 = __require("path"), resolveCommand = require_resolveCommand(), escape = require_escape(), readShebang = require_readShebang(), isWin = process.platform === "win32", isExecutableRegExp = /\.(?:com|exe)$/i, isCmdShimRegExp = /node_modules[\\/].bin[\\/][^\\/]+\.cmd$/i;
286
+ function detectShebang(parsed) {
287
+ parsed.file = resolveCommand(parsed);
288
+ let shebang = parsed.file && readShebang(parsed.file);
289
+ return shebang ? (parsed.args.unshift(parsed.file), parsed.command = shebang, resolveCommand(parsed)) : parsed.file;
290
+ }
291
+ function parseNonShell(parsed) {
292
+ if (!isWin)
293
+ return parsed;
294
+ let commandFile = detectShebang(parsed), needsShell = !isExecutableRegExp.test(commandFile);
295
+ if (parsed.options.forceShell || needsShell) {
296
+ let needsDoubleEscapeMetaChars = isCmdShimRegExp.test(commandFile);
297
+ parsed.command = path3.normalize(parsed.command), parsed.command = escape.command(parsed.command), parsed.args = parsed.args.map((arg) => escape.argument(arg, needsDoubleEscapeMetaChars));
298
+ let shellCommand = [parsed.command].concat(parsed.args).join(" ");
299
+ parsed.args = ["/d", "/s", "/c", `"${shellCommand}"`], parsed.command = process.env.comspec || "cmd.exe", parsed.options.windowsVerbatimArguments = !0;
300
+ }
301
+ return parsed;
302
+ }
303
+ function parse(command, args, options) {
304
+ args && !Array.isArray(args) && (options = args, args = null), args = args ? args.slice(0) : [], options = Object.assign({}, options);
305
+ let parsed = {
306
+ command,
307
+ args,
308
+ options,
309
+ file: void 0,
310
+ original: {
311
+ command,
312
+ args
313
+ }
314
+ };
315
+ return options.shell ? parsed : parseNonShell(parsed);
316
+ }
317
+ module.exports = parse;
318
+ }
319
+ });
320
+
321
+ // ../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/enoent.js
322
+ var require_enoent = __commonJS({
323
+ "../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/lib/enoent.js"(exports, module) {
324
+ "use strict";
325
+ init_cjs_shims();
326
+ var isWin = process.platform === "win32";
327
+ function notFoundError(original, syscall) {
328
+ return Object.assign(new Error(`${syscall} ${original.command} ENOENT`), {
329
+ code: "ENOENT",
330
+ errno: "ENOENT",
331
+ syscall: `${syscall} ${original.command}`,
332
+ path: original.command,
333
+ spawnargs: original.args
334
+ });
335
+ }
336
+ function hookChildProcess(cp, parsed) {
337
+ if (!isWin)
338
+ return;
339
+ let originalEmit = cp.emit;
340
+ cp.emit = function(name, arg1) {
341
+ if (name === "exit") {
342
+ let err = verifyENOENT(arg1, parsed);
343
+ if (err)
344
+ return originalEmit.call(cp, "error", err);
345
+ }
346
+ return originalEmit.apply(cp, arguments);
347
+ };
348
+ }
349
+ function verifyENOENT(status, parsed) {
350
+ return isWin && status === 1 && !parsed.file ? notFoundError(parsed.original, "spawn") : null;
351
+ }
352
+ function verifyENOENTSync(status, parsed) {
353
+ return isWin && status === 1 && !parsed.file ? notFoundError(parsed.original, "spawnSync") : null;
354
+ }
355
+ module.exports = {
356
+ hookChildProcess,
357
+ verifyENOENT,
358
+ verifyENOENTSync,
359
+ notFoundError
360
+ };
361
+ }
362
+ });
363
+
364
+ // ../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/index.js
365
+ var require_cross_spawn = __commonJS({
366
+ "../../node_modules/.pnpm/cross-spawn@7.0.6/node_modules/cross-spawn/index.js"(exports, module) {
367
+ "use strict";
368
+ init_cjs_shims();
369
+ var cp = __require("child_process"), parse = require_parse(), enoent = require_enoent();
370
+ function spawn(command, args, options) {
371
+ let parsed = parse(command, args, options), spawned = cp.spawn(parsed.command, parsed.args, parsed.options);
372
+ return enoent.hookChildProcess(spawned, parsed), spawned;
373
+ }
374
+ function spawnSync(command, args, options) {
375
+ let parsed = parse(command, args, options), result = cp.spawnSync(parsed.command, parsed.args, parsed.options);
376
+ return result.error = result.error || enoent.verifyENOENTSync(result.status, parsed), result;
377
+ }
378
+ module.exports = spawn;
379
+ module.exports.spawn = spawn;
380
+ module.exports.sync = spawnSync;
381
+ module.exports._parse = parse;
382
+ module.exports._enoent = enoent;
383
+ }
384
+ });
385
+
386
+ // ../../node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js
387
+ var require_signals = __commonJS({
388
+ "../../node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js"(exports, module) {
389
+ init_cjs_shims();
390
+ module.exports = [
391
+ "SIGABRT",
392
+ "SIGALRM",
393
+ "SIGHUP",
394
+ "SIGINT",
395
+ "SIGTERM"
396
+ ];
397
+ process.platform !== "win32" && module.exports.push(
398
+ "SIGVTALRM",
399
+ "SIGXCPU",
400
+ "SIGXFSZ",
401
+ "SIGUSR2",
402
+ "SIGTRAP",
403
+ "SIGSYS",
404
+ "SIGQUIT",
405
+ "SIGIOT"
406
+ // should detect profiler and enable/disable accordingly.
407
+ // see #21
408
+ // 'SIGPROF'
409
+ );
410
+ process.platform === "linux" && module.exports.push(
411
+ "SIGIO",
412
+ "SIGPOLL",
413
+ "SIGPWR",
414
+ "SIGSTKFLT",
415
+ "SIGUNUSED"
416
+ );
417
+ }
418
+ });
419
+
420
+ // ../../node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js
421
+ var require_signal_exit = __commonJS({
422
+ "../../node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js"(exports, module) {
423
+ init_cjs_shims();
424
+ var process6 = global.process, processOk = function(process7) {
425
+ return process7 && typeof process7 == "object" && typeof process7.removeListener == "function" && typeof process7.emit == "function" && typeof process7.reallyExit == "function" && typeof process7.listeners == "function" && typeof process7.kill == "function" && typeof process7.pid == "number" && typeof process7.on == "function";
426
+ };
427
+ processOk(process6) ? (assert = __require("assert"), signals = require_signals(), isWin = /^win/i.test(process6.platform), EE = __require("events"), typeof EE != "function" && (EE = EE.EventEmitter), process6.__signal_exit_emitter__ ? emitter = process6.__signal_exit_emitter__ : (emitter = process6.__signal_exit_emitter__ = new EE(), emitter.count = 0, emitter.emitted = {}), emitter.infinite || (emitter.setMaxListeners(1 / 0), emitter.infinite = !0), module.exports = function(cb, opts) {
428
+ if (!processOk(global.process))
429
+ return function() {
430
+ };
431
+ assert.equal(typeof cb, "function", "a callback must be provided for exit handler"), loaded === !1 && load();
432
+ var ev = "exit";
433
+ opts && opts.alwaysLast && (ev = "afterexit");
434
+ var remove = function() {
435
+ emitter.removeListener(ev, cb), emitter.listeners("exit").length === 0 && emitter.listeners("afterexit").length === 0 && unload();
436
+ };
437
+ return emitter.on(ev, cb), remove;
438
+ }, unload = function() {
439
+ !loaded || !processOk(global.process) || (loaded = !1, signals.forEach(function(sig) {
440
+ try {
441
+ process6.removeListener(sig, sigListeners[sig]);
442
+ } catch {
443
+ }
444
+ }), process6.emit = originalProcessEmit, process6.reallyExit = originalProcessReallyExit, emitter.count -= 1);
445
+ }, module.exports.unload = unload, emit = function(event, code, signal) {
446
+ emitter.emitted[event] || (emitter.emitted[event] = !0, emitter.emit(event, code, signal));
447
+ }, sigListeners = {}, signals.forEach(function(sig) {
448
+ sigListeners[sig] = function() {
449
+ if (processOk(global.process)) {
450
+ var listeners = process6.listeners(sig);
451
+ listeners.length === emitter.count && (unload(), emit("exit", null, sig), emit("afterexit", null, sig), isWin && sig === "SIGHUP" && (sig = "SIGINT"), process6.kill(process6.pid, sig));
452
+ }
453
+ };
454
+ }), module.exports.signals = function() {
455
+ return signals;
456
+ }, loaded = !1, load = function() {
457
+ loaded || !processOk(global.process) || (loaded = !0, emitter.count += 1, signals = signals.filter(function(sig) {
458
+ try {
459
+ return process6.on(sig, sigListeners[sig]), !0;
460
+ } catch {
461
+ return !1;
462
+ }
463
+ }), process6.emit = processEmit, process6.reallyExit = processReallyExit);
464
+ }, module.exports.load = load, originalProcessReallyExit = process6.reallyExit, processReallyExit = function(code) {
465
+ processOk(global.process) && (process6.exitCode = code || /* istanbul ignore next */
466
+ 0, emit("exit", process6.exitCode, null), emit("afterexit", process6.exitCode, null), originalProcessReallyExit.call(process6, process6.exitCode));
467
+ }, originalProcessEmit = process6.emit, processEmit = function(ev, arg) {
468
+ if (ev === "exit" && processOk(global.process)) {
469
+ arg !== void 0 && (process6.exitCode = arg);
470
+ var ret = originalProcessEmit.apply(this, arguments);
471
+ return emit("exit", process6.exitCode, null), emit("afterexit", process6.exitCode, null), ret;
472
+ } else
473
+ return originalProcessEmit.apply(this, arguments);
474
+ }) : module.exports = function() {
475
+ return function() {
476
+ };
477
+ };
478
+ var assert, signals, isWin, EE, emitter, unload, emit, sigListeners, loaded, load, originalProcessReallyExit, processReallyExit, originalProcessEmit, processEmit;
479
+ }
480
+ });
481
+
482
+ // ../../node_modules/.pnpm/merge-stream@2.0.0/node_modules/merge-stream/index.js
483
+ var require_merge_stream = __commonJS({
484
+ "../../node_modules/.pnpm/merge-stream@2.0.0/node_modules/merge-stream/index.js"(exports, module) {
485
+ "use strict";
486
+ init_cjs_shims();
487
+ var { PassThrough } = __require("stream");
488
+ module.exports = function() {
489
+ var sources = [], output = new PassThrough({ objectMode: !0 });
490
+ return output.setMaxListeners(0), output.add = add, output.isEmpty = isEmpty, output.on("unpipe", remove), Array.prototype.slice.call(arguments).forEach(add), output;
491
+ function add(source) {
492
+ return Array.isArray(source) ? (source.forEach(add), this) : (sources.push(source), source.once("end", remove.bind(null, source)), source.once("error", output.emit.bind(output, "error")), source.pipe(output, { end: !1 }), this);
493
+ }
494
+ function isEmpty() {
495
+ return sources.length == 0;
496
+ }
497
+ function remove(source) {
498
+ sources = sources.filter(function(it) {
499
+ return it !== source;
500
+ }), !sources.length && output.readable && output.end();
501
+ }
502
+ };
503
+ }
504
+ });
505
+
506
+ // ../cli-kit/dist/public/node/os.js
507
+ init_cjs_shims();
508
+
509
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/index.js
510
+ init_cjs_shims();
511
+ var import_cross_spawn = __toESM(require_cross_spawn(), 1);
512
+ import { Buffer as Buffer3 } from "node:buffer";
513
+ import path2 from "node:path";
514
+ import childProcess from "node:child_process";
515
+ import process5 from "node:process";
516
+
517
+ // ../../node_modules/.pnpm/strip-final-newline@3.0.0/node_modules/strip-final-newline/index.js
518
+ init_cjs_shims();
519
+ function stripFinalNewline(input) {
520
+ let LF = typeof input == "string" ? `
521
+ ` : 10, CR = typeof input == "string" ? "\r" : 13;
522
+ return input[input.length - 1] === LF && (input = input.slice(0, -1)), input[input.length - 1] === CR && (input = input.slice(0, -1)), input;
523
+ }
524
+
525
+ // ../../node_modules/.pnpm/npm-run-path@5.3.0/node_modules/npm-run-path/index.js
526
+ init_cjs_shims();
527
+ import process2 from "node:process";
528
+ import path from "node:path";
529
+ import { fileURLToPath } from "node:url";
530
+
531
+ // ../../node_modules/.pnpm/path-key@4.0.0/node_modules/path-key/index.js
532
+ init_cjs_shims();
533
+ function pathKey(options = {}) {
534
+ let {
535
+ env = process.env,
536
+ platform = process.platform
537
+ } = options;
538
+ return platform !== "win32" ? "PATH" : Object.keys(env).reverse().find((key) => key.toUpperCase() === "PATH") || "Path";
539
+ }
540
+
541
+ // ../../node_modules/.pnpm/npm-run-path@5.3.0/node_modules/npm-run-path/index.js
542
+ var npmRunPath = ({
543
+ cwd = process2.cwd(),
544
+ path: pathOption = process2.env[pathKey()],
545
+ preferLocal = !0,
546
+ execPath = process2.execPath,
547
+ addExecPath = !0
548
+ } = {}) => {
549
+ let cwdString = cwd instanceof URL ? fileURLToPath(cwd) : cwd, cwdPath = path.resolve(cwdString), result = [];
550
+ return preferLocal && applyPreferLocal(result, cwdPath), addExecPath && applyExecPath(result, execPath, cwdPath), [...result, pathOption].join(path.delimiter);
551
+ }, applyPreferLocal = (result, cwdPath) => {
552
+ let previous;
553
+ for (; previous !== cwdPath; )
554
+ result.push(path.join(cwdPath, "node_modules/.bin")), previous = cwdPath, cwdPath = path.resolve(cwdPath, "..");
555
+ }, applyExecPath = (result, execPath, cwdPath) => {
556
+ let execPathString = execPath instanceof URL ? fileURLToPath(execPath) : execPath;
557
+ result.push(path.resolve(cwdPath, execPathString, ".."));
558
+ }, npmRunPathEnv = ({ env = process2.env, ...options } = {}) => {
559
+ env = { ...env };
560
+ let pathName = pathKey({ env });
561
+ return options.path = env[pathName], env[pathName] = npmRunPath(options), env;
562
+ };
563
+
564
+ // ../../node_modules/.pnpm/onetime@6.0.0/node_modules/onetime/index.js
565
+ init_cjs_shims();
566
+ var calledFunctions = /* @__PURE__ */ new WeakMap(), onetime = (function_, options = {}) => {
567
+ if (typeof function_ != "function")
568
+ throw new TypeError("Expected a function");
569
+ let returnValue, callCount = 0, functionName = function_.displayName || function_.name || "<anonymous>", onetime2 = function(...arguments_) {
570
+ if (calledFunctions.set(onetime2, ++callCount), callCount === 1)
571
+ returnValue = function_.apply(this, arguments_), function_ = null;
572
+ else if (options.throw === !0)
573
+ throw new Error(`Function \`${functionName}\` can only be called once`);
574
+ return returnValue;
575
+ };
576
+ return mimicFunction(onetime2, function_), calledFunctions.set(onetime2, callCount), onetime2;
577
+ };
578
+ onetime.callCount = (function_) => {
579
+ if (!calledFunctions.has(function_))
580
+ throw new Error(`The given function \`${function_.name}\` is not wrapped by the \`onetime\` package`);
581
+ return calledFunctions.get(function_);
582
+ };
583
+ var onetime_default = onetime;
584
+
585
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/error.js
586
+ init_cjs_shims();
587
+ import process3 from "node:process";
588
+
589
+ // ../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/main.js
590
+ init_cjs_shims();
591
+ import { constants as constants2 } from "node:os";
592
+
593
+ // ../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/realtime.js
594
+ init_cjs_shims();
595
+ var getRealtimeSignals = () => {
596
+ let length = SIGRTMAX - SIGRTMIN + 1;
597
+ return Array.from({ length }, getRealtimeSignal);
598
+ }, getRealtimeSignal = (value, index) => ({
599
+ name: `SIGRT${index + 1}`,
600
+ number: SIGRTMIN + index,
601
+ action: "terminate",
602
+ description: "Application-specific signal (realtime)",
603
+ standard: "posix"
604
+ }), SIGRTMIN = 34, SIGRTMAX = 64;
605
+
606
+ // ../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/signals.js
607
+ init_cjs_shims();
608
+ import { constants } from "node:os";
609
+
610
+ // ../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/core.js
611
+ init_cjs_shims();
612
+ var SIGNALS = [
613
+ {
614
+ name: "SIGHUP",
615
+ number: 1,
616
+ action: "terminate",
617
+ description: "Terminal closed",
618
+ standard: "posix"
619
+ },
620
+ {
621
+ name: "SIGINT",
622
+ number: 2,
623
+ action: "terminate",
624
+ description: "User interruption with CTRL-C",
625
+ standard: "ansi"
626
+ },
627
+ {
628
+ name: "SIGQUIT",
629
+ number: 3,
630
+ action: "core",
631
+ description: "User interruption with CTRL-\\",
632
+ standard: "posix"
633
+ },
634
+ {
635
+ name: "SIGILL",
636
+ number: 4,
637
+ action: "core",
638
+ description: "Invalid machine instruction",
639
+ standard: "ansi"
640
+ },
641
+ {
642
+ name: "SIGTRAP",
643
+ number: 5,
644
+ action: "core",
645
+ description: "Debugger breakpoint",
646
+ standard: "posix"
647
+ },
648
+ {
649
+ name: "SIGABRT",
650
+ number: 6,
651
+ action: "core",
652
+ description: "Aborted",
653
+ standard: "ansi"
654
+ },
655
+ {
656
+ name: "SIGIOT",
657
+ number: 6,
658
+ action: "core",
659
+ description: "Aborted",
660
+ standard: "bsd"
661
+ },
662
+ {
663
+ name: "SIGBUS",
664
+ number: 7,
665
+ action: "core",
666
+ description: "Bus error due to misaligned, non-existing address or paging error",
667
+ standard: "bsd"
668
+ },
669
+ {
670
+ name: "SIGEMT",
671
+ number: 7,
672
+ action: "terminate",
673
+ description: "Command should be emulated but is not implemented",
674
+ standard: "other"
675
+ },
676
+ {
677
+ name: "SIGFPE",
678
+ number: 8,
679
+ action: "core",
680
+ description: "Floating point arithmetic error",
681
+ standard: "ansi"
682
+ },
683
+ {
684
+ name: "SIGKILL",
685
+ number: 9,
686
+ action: "terminate",
687
+ description: "Forced termination",
688
+ standard: "posix",
689
+ forced: !0
690
+ },
691
+ {
692
+ name: "SIGUSR1",
693
+ number: 10,
694
+ action: "terminate",
695
+ description: "Application-specific signal",
696
+ standard: "posix"
697
+ },
698
+ {
699
+ name: "SIGSEGV",
700
+ number: 11,
701
+ action: "core",
702
+ description: "Segmentation fault",
703
+ standard: "ansi"
704
+ },
705
+ {
706
+ name: "SIGUSR2",
707
+ number: 12,
708
+ action: "terminate",
709
+ description: "Application-specific signal",
710
+ standard: "posix"
711
+ },
712
+ {
713
+ name: "SIGPIPE",
714
+ number: 13,
715
+ action: "terminate",
716
+ description: "Broken pipe or socket",
717
+ standard: "posix"
718
+ },
719
+ {
720
+ name: "SIGALRM",
721
+ number: 14,
722
+ action: "terminate",
723
+ description: "Timeout or timer",
724
+ standard: "posix"
725
+ },
726
+ {
727
+ name: "SIGTERM",
728
+ number: 15,
729
+ action: "terminate",
730
+ description: "Termination",
731
+ standard: "ansi"
732
+ },
733
+ {
734
+ name: "SIGSTKFLT",
735
+ number: 16,
736
+ action: "terminate",
737
+ description: "Stack is empty or overflowed",
738
+ standard: "other"
739
+ },
740
+ {
741
+ name: "SIGCHLD",
742
+ number: 17,
743
+ action: "ignore",
744
+ description: "Child process terminated, paused or unpaused",
745
+ standard: "posix"
746
+ },
747
+ {
748
+ name: "SIGCLD",
749
+ number: 17,
750
+ action: "ignore",
751
+ description: "Child process terminated, paused or unpaused",
752
+ standard: "other"
753
+ },
754
+ {
755
+ name: "SIGCONT",
756
+ number: 18,
757
+ action: "unpause",
758
+ description: "Unpaused",
759
+ standard: "posix",
760
+ forced: !0
761
+ },
762
+ {
763
+ name: "SIGSTOP",
764
+ number: 19,
765
+ action: "pause",
766
+ description: "Paused",
767
+ standard: "posix",
768
+ forced: !0
769
+ },
770
+ {
771
+ name: "SIGTSTP",
772
+ number: 20,
773
+ action: "pause",
774
+ description: 'Paused using CTRL-Z or "suspend"',
775
+ standard: "posix"
776
+ },
777
+ {
778
+ name: "SIGTTIN",
779
+ number: 21,
780
+ action: "pause",
781
+ description: "Background process cannot read terminal input",
782
+ standard: "posix"
783
+ },
784
+ {
785
+ name: "SIGBREAK",
786
+ number: 21,
787
+ action: "terminate",
788
+ description: "User interruption with CTRL-BREAK",
789
+ standard: "other"
790
+ },
791
+ {
792
+ name: "SIGTTOU",
793
+ number: 22,
794
+ action: "pause",
795
+ description: "Background process cannot write to terminal output",
796
+ standard: "posix"
797
+ },
798
+ {
799
+ name: "SIGURG",
800
+ number: 23,
801
+ action: "ignore",
802
+ description: "Socket received out-of-band data",
803
+ standard: "bsd"
804
+ },
805
+ {
806
+ name: "SIGXCPU",
807
+ number: 24,
808
+ action: "core",
809
+ description: "Process timed out",
810
+ standard: "bsd"
811
+ },
812
+ {
813
+ name: "SIGXFSZ",
814
+ number: 25,
815
+ action: "core",
816
+ description: "File too big",
817
+ standard: "bsd"
818
+ },
819
+ {
820
+ name: "SIGVTALRM",
821
+ number: 26,
822
+ action: "terminate",
823
+ description: "Timeout or timer",
824
+ standard: "bsd"
825
+ },
826
+ {
827
+ name: "SIGPROF",
828
+ number: 27,
829
+ action: "terminate",
830
+ description: "Timeout or timer",
831
+ standard: "bsd"
832
+ },
833
+ {
834
+ name: "SIGWINCH",
835
+ number: 28,
836
+ action: "ignore",
837
+ description: "Terminal window size changed",
838
+ standard: "bsd"
839
+ },
840
+ {
841
+ name: "SIGIO",
842
+ number: 29,
843
+ action: "terminate",
844
+ description: "I/O is available",
845
+ standard: "other"
846
+ },
847
+ {
848
+ name: "SIGPOLL",
849
+ number: 29,
850
+ action: "terminate",
851
+ description: "Watched event",
852
+ standard: "other"
853
+ },
854
+ {
855
+ name: "SIGINFO",
856
+ number: 29,
857
+ action: "ignore",
858
+ description: "Request for process information",
859
+ standard: "other"
860
+ },
861
+ {
862
+ name: "SIGPWR",
863
+ number: 30,
864
+ action: "terminate",
865
+ description: "Device running out of power",
866
+ standard: "systemv"
867
+ },
868
+ {
869
+ name: "SIGSYS",
870
+ number: 31,
871
+ action: "core",
872
+ description: "Invalid system call",
873
+ standard: "other"
874
+ },
875
+ {
876
+ name: "SIGUNUSED",
877
+ number: 31,
878
+ action: "terminate",
879
+ description: "Invalid system call",
880
+ standard: "other"
881
+ }
882
+ ];
883
+
884
+ // ../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/signals.js
885
+ var getSignals = () => {
886
+ let realtimeSignals = getRealtimeSignals();
887
+ return [...SIGNALS, ...realtimeSignals].map(normalizeSignal);
888
+ }, normalizeSignal = ({
889
+ name,
890
+ number: defaultNumber,
891
+ description,
892
+ action,
893
+ forced = !1,
894
+ standard
895
+ }) => {
896
+ let {
897
+ signals: { [name]: constantSignal }
898
+ } = constants, supported = constantSignal !== void 0;
899
+ return { name, number: supported ? constantSignal : defaultNumber, description, supported, action, forced, standard };
900
+ };
901
+
902
+ // ../../node_modules/.pnpm/human-signals@4.3.1/node_modules/human-signals/build/src/main.js
903
+ var getSignalsByName = () => {
904
+ let signals = getSignals();
905
+ return Object.fromEntries(signals.map(getSignalByName));
906
+ }, getSignalByName = ({
907
+ name,
908
+ number,
909
+ description,
910
+ supported,
911
+ action,
912
+ forced,
913
+ standard
914
+ }) => [name, { name, number, description, supported, action, forced, standard }], signalsByName = getSignalsByName(), getSignalsByNumber = () => {
915
+ let signals = getSignals(), length = 65, signalsA = Array.from({ length }, (value, number) => getSignalByNumber(number, signals));
916
+ return Object.assign({}, ...signalsA);
917
+ }, getSignalByNumber = (number, signals) => {
918
+ let signal = findSignalByNumber(number, signals);
919
+ if (signal === void 0)
920
+ return {};
921
+ let { name, description, supported, action, forced, standard } = signal;
922
+ return {
923
+ [number]: {
924
+ name,
925
+ number,
926
+ description,
927
+ supported,
928
+ action,
929
+ forced,
930
+ standard
931
+ }
932
+ };
933
+ }, findSignalByNumber = (number, signals) => {
934
+ let signal = signals.find(({ name }) => constants2.signals[name] === number);
935
+ return signal !== void 0 ? signal : signals.find((signalA) => signalA.number === number);
936
+ }, signalsByNumber = getSignalsByNumber();
937
+
938
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/error.js
939
+ var getErrorPrefix = ({ timedOut, timeout, errorCode, signal, signalDescription, exitCode, isCanceled }) => timedOut ? `timed out after ${timeout} milliseconds` : isCanceled ? "was canceled" : errorCode !== void 0 ? `failed with ${errorCode}` : signal !== void 0 ? `was killed with ${signal} (${signalDescription})` : exitCode !== void 0 ? `failed with exit code ${exitCode}` : "failed", makeError = ({
940
+ stdout,
941
+ stderr,
942
+ all,
943
+ error,
944
+ signal,
945
+ exitCode,
946
+ command,
947
+ escapedCommand,
948
+ timedOut,
949
+ isCanceled,
950
+ killed,
951
+ parsed: { options: { timeout, cwd = process3.cwd() } }
952
+ }) => {
953
+ exitCode = exitCode === null ? void 0 : exitCode, signal = signal === null ? void 0 : signal;
954
+ let signalDescription = signal === void 0 ? void 0 : signalsByName[signal].description, errorCode = error && error.code, execaMessage = `Command ${getErrorPrefix({ timedOut, timeout, errorCode, signal, signalDescription, exitCode, isCanceled })}: ${command}`, isError = Object.prototype.toString.call(error) === "[object Error]", shortMessage = isError ? `${execaMessage}
955
+ ${error.message}` : execaMessage, message = [shortMessage, stderr, stdout].filter(Boolean).join(`
956
+ `);
957
+ return isError ? (error.originalMessage = error.message, error.message = message) : error = new Error(message), error.shortMessage = shortMessage, error.command = command, error.escapedCommand = escapedCommand, error.exitCode = exitCode, error.signal = signal, error.signalDescription = signalDescription, error.stdout = stdout, error.stderr = stderr, error.cwd = cwd, all !== void 0 && (error.all = all), "bufferedData" in error && delete error.bufferedData, error.failed = !0, error.timedOut = !!timedOut, error.isCanceled = isCanceled, error.killed = killed && !timedOut, error;
958
+ };
959
+
960
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/stdio.js
961
+ init_cjs_shims();
962
+ var aliases = ["stdin", "stdout", "stderr"], hasAlias = (options) => aliases.some((alias) => options[alias] !== void 0), normalizeStdio = (options) => {
963
+ if (!options)
964
+ return;
965
+ let { stdio } = options;
966
+ if (stdio === void 0)
967
+ return aliases.map((alias) => options[alias]);
968
+ if (hasAlias(options))
969
+ throw new Error(`It's not possible to provide \`stdio\` in combination with one of ${aliases.map((alias) => `\`${alias}\``).join(", ")}`);
970
+ if (typeof stdio == "string")
971
+ return stdio;
972
+ if (!Array.isArray(stdio))
973
+ throw new TypeError(`Expected \`stdio\` to be of type \`string\` or \`Array\`, got \`${typeof stdio}\``);
974
+ let length = Math.max(stdio.length, aliases.length);
975
+ return Array.from({ length }, (value, index) => stdio[index]);
976
+ };
977
+
978
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/kill.js
979
+ init_cjs_shims();
980
+ var import_signal_exit = __toESM(require_signal_exit(), 1);
981
+ import os from "node:os";
982
+ var DEFAULT_FORCE_KILL_TIMEOUT = 1e3 * 5, spawnedKill = (kill, signal = "SIGTERM", options = {}) => {
983
+ let killResult = kill(signal);
984
+ return setKillTimeout(kill, signal, options, killResult), killResult;
985
+ }, setKillTimeout = (kill, signal, options, killResult) => {
986
+ if (!shouldForceKill(signal, options, killResult))
987
+ return;
988
+ let timeout = getForceKillAfterTimeout(options), t = setTimeout(() => {
989
+ kill("SIGKILL");
990
+ }, timeout);
991
+ t.unref && t.unref();
992
+ }, shouldForceKill = (signal, { forceKillAfterTimeout }, killResult) => isSigterm(signal) && forceKillAfterTimeout !== !1 && killResult, isSigterm = (signal) => signal === os.constants.signals.SIGTERM || typeof signal == "string" && signal.toUpperCase() === "SIGTERM", getForceKillAfterTimeout = ({ forceKillAfterTimeout = !0 }) => {
993
+ if (forceKillAfterTimeout === !0)
994
+ return DEFAULT_FORCE_KILL_TIMEOUT;
995
+ if (!Number.isFinite(forceKillAfterTimeout) || forceKillAfterTimeout < 0)
996
+ throw new TypeError(`Expected the \`forceKillAfterTimeout\` option to be a non-negative integer, got \`${forceKillAfterTimeout}\` (${typeof forceKillAfterTimeout})`);
997
+ return forceKillAfterTimeout;
998
+ }, spawnedCancel = (spawned, context) => {
999
+ spawned.kill() && (context.isCanceled = !0);
1000
+ }, timeoutKill = (spawned, signal, reject) => {
1001
+ spawned.kill(signal), reject(Object.assign(new Error("Timed out"), { timedOut: !0, signal }));
1002
+ }, setupTimeout = (spawned, { timeout, killSignal = "SIGTERM" }, spawnedPromise) => {
1003
+ if (timeout === 0 || timeout === void 0)
1004
+ return spawnedPromise;
1005
+ let timeoutId, timeoutPromise = new Promise((resolve, reject) => {
1006
+ timeoutId = setTimeout(() => {
1007
+ timeoutKill(spawned, killSignal, reject);
1008
+ }, timeout);
1009
+ }), safeSpawnedPromise = spawnedPromise.finally(() => {
1010
+ clearTimeout(timeoutId);
1011
+ });
1012
+ return Promise.race([timeoutPromise, safeSpawnedPromise]);
1013
+ }, validateTimeout = ({ timeout }) => {
1014
+ if (timeout !== void 0 && (!Number.isFinite(timeout) || timeout < 0))
1015
+ throw new TypeError(`Expected the \`timeout\` option to be a non-negative integer, got \`${timeout}\` (${typeof timeout})`);
1016
+ }, setExitHandler = async (spawned, { cleanup, detached }, timedPromise) => {
1017
+ if (!cleanup || detached)
1018
+ return timedPromise;
1019
+ let removeExitHandler = (0, import_signal_exit.default)(() => {
1020
+ spawned.kill();
1021
+ });
1022
+ return timedPromise.finally(() => {
1023
+ removeExitHandler();
1024
+ });
1025
+ };
1026
+
1027
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/pipe.js
1028
+ init_cjs_shims();
1029
+ import { createWriteStream } from "node:fs";
1030
+ import { ChildProcess } from "node:child_process";
1031
+
1032
+ // ../../node_modules/.pnpm/is-stream@3.0.0/node_modules/is-stream/index.js
1033
+ init_cjs_shims();
1034
+ function isStream(stream) {
1035
+ return stream !== null && typeof stream == "object" && typeof stream.pipe == "function";
1036
+ }
1037
+ function isWritableStream(stream) {
1038
+ return isStream(stream) && stream.writable !== !1 && typeof stream._write == "function" && typeof stream._writableState == "object";
1039
+ }
1040
+
1041
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/pipe.js
1042
+ var isExecaChildProcess = (target) => target instanceof ChildProcess && typeof target.then == "function", pipeToTarget = (spawned, streamName, target) => {
1043
+ if (typeof target == "string")
1044
+ return spawned[streamName].pipe(createWriteStream(target)), spawned;
1045
+ if (isWritableStream(target))
1046
+ return spawned[streamName].pipe(target), spawned;
1047
+ if (!isExecaChildProcess(target))
1048
+ throw new TypeError("The second argument must be a string, a stream or an Execa child process.");
1049
+ if (!isWritableStream(target.stdin))
1050
+ throw new TypeError("The target child process's stdin must be available.");
1051
+ return spawned[streamName].pipe(target.stdin), target;
1052
+ }, addPipeMethods = (spawned) => {
1053
+ spawned.stdout !== null && (spawned.pipeStdout = pipeToTarget.bind(void 0, spawned, "stdout")), spawned.stderr !== null && (spawned.pipeStderr = pipeToTarget.bind(void 0, spawned, "stderr")), spawned.all !== void 0 && (spawned.pipeAll = pipeToTarget.bind(void 0, spawned, "all"));
1054
+ };
1055
+
1056
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/stream.js
1057
+ init_cjs_shims();
1058
+ import { createReadStream, readFileSync } from "node:fs";
1059
+ var import_get_stream = __toESM(require_get_stream(), 1), import_merge_stream = __toESM(require_merge_stream(), 1), validateInputOptions = (input) => {
1060
+ if (input !== void 0)
1061
+ throw new TypeError("The `input` and `inputFile` options cannot be both set.");
1062
+ }, getInputSync = ({ input, inputFile }) => typeof inputFile != "string" ? input : (validateInputOptions(input), readFileSync(inputFile)), handleInputSync = (options) => {
1063
+ let input = getInputSync(options);
1064
+ if (isStream(input))
1065
+ throw new TypeError("The `input` option cannot be a stream in sync mode");
1066
+ return input;
1067
+ }, getInput = ({ input, inputFile }) => typeof inputFile != "string" ? input : (validateInputOptions(input), createReadStream(inputFile)), handleInput = (spawned, options) => {
1068
+ let input = getInput(options);
1069
+ input !== void 0 && (isStream(input) ? input.pipe(spawned.stdin) : spawned.stdin.end(input));
1070
+ }, makeAllStream = (spawned, { all }) => {
1071
+ if (!all || !spawned.stdout && !spawned.stderr)
1072
+ return;
1073
+ let mixed = (0, import_merge_stream.default)();
1074
+ return spawned.stdout && mixed.add(spawned.stdout), spawned.stderr && mixed.add(spawned.stderr), mixed;
1075
+ }, getBufferedData = async (stream, streamPromise) => {
1076
+ if (!(!stream || streamPromise === void 0)) {
1077
+ stream.destroy();
1078
+ try {
1079
+ return await streamPromise;
1080
+ } catch (error) {
1081
+ return error.bufferedData;
1082
+ }
1083
+ }
1084
+ }, getStreamPromise = (stream, { encoding, buffer, maxBuffer }) => {
1085
+ if (!(!stream || !buffer))
1086
+ return encoding ? (0, import_get_stream.default)(stream, { encoding, maxBuffer }) : import_get_stream.default.buffer(stream, { maxBuffer });
1087
+ }, getSpawnedResult = async ({ stdout, stderr, all }, { encoding, buffer, maxBuffer }, processDone) => {
1088
+ let stdoutPromise = getStreamPromise(stdout, { encoding, buffer, maxBuffer }), stderrPromise = getStreamPromise(stderr, { encoding, buffer, maxBuffer }), allPromise = getStreamPromise(all, { encoding, buffer, maxBuffer: maxBuffer * 2 });
1089
+ try {
1090
+ return await Promise.all([processDone, stdoutPromise, stderrPromise, allPromise]);
1091
+ } catch (error) {
1092
+ return Promise.all([
1093
+ { error, signal: error.signal, timedOut: error.timedOut },
1094
+ getBufferedData(stdout, stdoutPromise),
1095
+ getBufferedData(stderr, stderrPromise),
1096
+ getBufferedData(all, allPromise)
1097
+ ]);
1098
+ }
1099
+ };
1100
+
1101
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/promise.js
1102
+ init_cjs_shims();
1103
+ var nativePromisePrototype = (async () => {
1104
+ })().constructor.prototype, descriptors = ["then", "catch", "finally"].map((property) => [
1105
+ property,
1106
+ Reflect.getOwnPropertyDescriptor(nativePromisePrototype, property)
1107
+ ]), mergePromise = (spawned, promise) => {
1108
+ for (let [property, descriptor] of descriptors) {
1109
+ let value = typeof promise == "function" ? (...args) => Reflect.apply(descriptor.value, promise(), args) : descriptor.value.bind(promise);
1110
+ Reflect.defineProperty(spawned, property, { ...descriptor, value });
1111
+ }
1112
+ }, getSpawnedPromise = (spawned) => new Promise((resolve, reject) => {
1113
+ spawned.on("exit", (exitCode, signal) => {
1114
+ resolve({ exitCode, signal });
1115
+ }), spawned.on("error", (error) => {
1116
+ reject(error);
1117
+ }), spawned.stdin && spawned.stdin.on("error", (error) => {
1118
+ reject(error);
1119
+ });
1120
+ });
1121
+
1122
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/command.js
1123
+ init_cjs_shims();
1124
+ import { Buffer as Buffer2 } from "node:buffer";
1125
+ import { ChildProcess as ChildProcess2 } from "node:child_process";
1126
+ var normalizeArgs = (file, args = []) => Array.isArray(args) ? [file, ...args] : [file], NO_ESCAPE_REGEXP = /^[\w.-]+$/, DOUBLE_QUOTES_REGEXP = /"/g, escapeArg = (arg) => typeof arg != "string" || NO_ESCAPE_REGEXP.test(arg) ? arg : `"${arg.replace(DOUBLE_QUOTES_REGEXP, '\\"')}"`, joinCommand = (file, args) => normalizeArgs(file, args).join(" "), getEscapedCommand = (file, args) => normalizeArgs(file, args).map((arg) => escapeArg(arg)).join(" "), SPACES_REGEXP = / +/g;
1127
+ var parseExpression = (expression) => {
1128
+ let typeOfExpression = typeof expression;
1129
+ if (typeOfExpression === "string")
1130
+ return expression;
1131
+ if (typeOfExpression === "number")
1132
+ return String(expression);
1133
+ if (typeOfExpression === "object" && expression !== null && !(expression instanceof ChildProcess2) && "stdout" in expression) {
1134
+ let typeOfStdout = typeof expression.stdout;
1135
+ if (typeOfStdout === "string")
1136
+ return expression.stdout;
1137
+ if (Buffer2.isBuffer(expression.stdout))
1138
+ return expression.stdout.toString();
1139
+ throw new TypeError(`Unexpected "${typeOfStdout}" stdout in template expression`);
1140
+ }
1141
+ throw new TypeError(`Unexpected "${typeOfExpression}" in template expression`);
1142
+ }, concatTokens = (tokens, nextTokens, isNew) => isNew || tokens.length === 0 || nextTokens.length === 0 ? [...tokens, ...nextTokens] : [
1143
+ ...tokens.slice(0, -1),
1144
+ `${tokens[tokens.length - 1]}${nextTokens[0]}`,
1145
+ ...nextTokens.slice(1)
1146
+ ], parseTemplate = ({ templates, expressions, tokens, index, template }) => {
1147
+ let templateString = template ?? templates.raw[index], templateTokens = templateString.split(SPACES_REGEXP).filter(Boolean), newTokens = concatTokens(
1148
+ tokens,
1149
+ templateTokens,
1150
+ templateString.startsWith(" ")
1151
+ );
1152
+ if (index === expressions.length)
1153
+ return newTokens;
1154
+ let expression = expressions[index], expressionTokens = Array.isArray(expression) ? expression.map((expression2) => parseExpression(expression2)) : [parseExpression(expression)];
1155
+ return concatTokens(
1156
+ newTokens,
1157
+ expressionTokens,
1158
+ templateString.endsWith(" ")
1159
+ );
1160
+ }, parseTemplates = (templates, expressions) => {
1161
+ let tokens = [];
1162
+ for (let [index, template] of templates.entries())
1163
+ tokens = parseTemplate({ templates, expressions, tokens, index, template });
1164
+ return tokens;
1165
+ };
1166
+
1167
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/lib/verbose.js
1168
+ init_cjs_shims();
1169
+ import { debuglog } from "node:util";
1170
+ import process4 from "node:process";
1171
+ var verboseDefault = debuglog("execa").enabled, padField = (field, padding) => String(field).padStart(padding, "0"), getTimestamp = () => {
1172
+ let date = /* @__PURE__ */ new Date();
1173
+ return `${padField(date.getHours(), 2)}:${padField(date.getMinutes(), 2)}:${padField(date.getSeconds(), 2)}.${padField(date.getMilliseconds(), 3)}`;
1174
+ }, logCommand = (escapedCommand, { verbose }) => {
1175
+ verbose && process4.stderr.write(`[${getTimestamp()}] ${escapedCommand}
1176
+ `);
1177
+ };
1178
+
1179
+ // ../../node_modules/.pnpm/execa@7.2.0/node_modules/execa/index.js
1180
+ var DEFAULT_MAX_BUFFER = 1e3 * 1e3 * 100, getEnv = ({ env: envOption, extendEnv, preferLocal, localDir, execPath }) => {
1181
+ let env = extendEnv ? { ...process5.env, ...envOption } : envOption;
1182
+ return preferLocal ? npmRunPathEnv({ env, cwd: localDir, execPath }) : env;
1183
+ }, handleArguments = (file, args, options = {}) => {
1184
+ let parsed = import_cross_spawn.default._parse(file, args, options);
1185
+ return file = parsed.command, args = parsed.args, options = parsed.options, options = {
1186
+ maxBuffer: DEFAULT_MAX_BUFFER,
1187
+ buffer: !0,
1188
+ stripFinalNewline: !0,
1189
+ extendEnv: !0,
1190
+ preferLocal: !1,
1191
+ localDir: options.cwd || process5.cwd(),
1192
+ execPath: process5.execPath,
1193
+ encoding: "utf8",
1194
+ reject: !0,
1195
+ cleanup: !0,
1196
+ all: !1,
1197
+ windowsHide: !0,
1198
+ verbose: verboseDefault,
1199
+ ...options
1200
+ }, options.env = getEnv(options), options.stdio = normalizeStdio(options), process5.platform === "win32" && path2.basename(file, ".exe") === "cmd" && args.unshift("/q"), { file, args, options, parsed };
1201
+ }, handleOutput = (options, value, error) => typeof value != "string" && !Buffer3.isBuffer(value) ? error === void 0 ? void 0 : "" : options.stripFinalNewline ? stripFinalNewline(value) : value;
1202
+ function execa(file, args, options) {
1203
+ let parsed = handleArguments(file, args, options), command = joinCommand(file, args), escapedCommand = getEscapedCommand(file, args);
1204
+ logCommand(escapedCommand, parsed.options), validateTimeout(parsed.options);
1205
+ let spawned;
1206
+ try {
1207
+ spawned = childProcess.spawn(parsed.file, parsed.args, parsed.options);
1208
+ } catch (error) {
1209
+ let dummySpawned = new childProcess.ChildProcess(), errorPromise = Promise.reject(makeError({
1210
+ error,
1211
+ stdout: "",
1212
+ stderr: "",
1213
+ all: "",
1214
+ command,
1215
+ escapedCommand,
1216
+ parsed,
1217
+ timedOut: !1,
1218
+ isCanceled: !1,
1219
+ killed: !1
1220
+ }));
1221
+ return mergePromise(dummySpawned, errorPromise), dummySpawned;
1222
+ }
1223
+ let spawnedPromise = getSpawnedPromise(spawned), timedPromise = setupTimeout(spawned, parsed.options, spawnedPromise), processDone = setExitHandler(spawned, parsed.options, timedPromise), context = { isCanceled: !1 };
1224
+ spawned.kill = spawnedKill.bind(null, spawned.kill.bind(spawned)), spawned.cancel = spawnedCancel.bind(null, spawned, context);
1225
+ let handlePromiseOnce = onetime_default(async () => {
1226
+ let [{ error, exitCode, signal, timedOut }, stdoutResult, stderrResult, allResult] = await getSpawnedResult(spawned, parsed.options, processDone), stdout = handleOutput(parsed.options, stdoutResult), stderr = handleOutput(parsed.options, stderrResult), all = handleOutput(parsed.options, allResult);
1227
+ if (error || exitCode !== 0 || signal !== null) {
1228
+ let returnedError = makeError({
1229
+ error,
1230
+ exitCode,
1231
+ signal,
1232
+ stdout,
1233
+ stderr,
1234
+ all,
1235
+ command,
1236
+ escapedCommand,
1237
+ parsed,
1238
+ timedOut,
1239
+ isCanceled: context.isCanceled || (parsed.options.signal ? parsed.options.signal.aborted : !1),
1240
+ killed: spawned.killed
1241
+ });
1242
+ if (!parsed.options.reject)
1243
+ return returnedError;
1244
+ throw returnedError;
1245
+ }
1246
+ return {
1247
+ command,
1248
+ escapedCommand,
1249
+ exitCode: 0,
1250
+ stdout,
1251
+ stderr,
1252
+ all,
1253
+ failed: !1,
1254
+ timedOut: !1,
1255
+ isCanceled: !1,
1256
+ killed: !1
1257
+ };
1258
+ });
1259
+ return handleInput(spawned, parsed.options), spawned.all = makeAllStream(spawned, parsed.options), addPipeMethods(spawned), mergePromise(spawned, handlePromiseOnce), spawned;
1260
+ }
1261
+ function execaSync(file, args, options) {
1262
+ let parsed = handleArguments(file, args, options), command = joinCommand(file, args), escapedCommand = getEscapedCommand(file, args);
1263
+ logCommand(escapedCommand, parsed.options);
1264
+ let input = handleInputSync(parsed.options), result;
1265
+ try {
1266
+ result = childProcess.spawnSync(parsed.file, parsed.args, { ...parsed.options, input });
1267
+ } catch (error) {
1268
+ throw makeError({
1269
+ error,
1270
+ stdout: "",
1271
+ stderr: "",
1272
+ all: "",
1273
+ command,
1274
+ escapedCommand,
1275
+ parsed,
1276
+ timedOut: !1,
1277
+ isCanceled: !1,
1278
+ killed: !1
1279
+ });
1280
+ }
1281
+ let stdout = handleOutput(parsed.options, result.stdout, result.error), stderr = handleOutput(parsed.options, result.stderr, result.error);
1282
+ if (result.error || result.status !== 0 || result.signal !== null) {
1283
+ let error = makeError({
1284
+ stdout,
1285
+ stderr,
1286
+ error: result.error,
1287
+ signal: result.signal,
1288
+ exitCode: result.status,
1289
+ command,
1290
+ escapedCommand,
1291
+ parsed,
1292
+ timedOut: result.error && result.error.code === "ETIMEDOUT",
1293
+ isCanceled: !1,
1294
+ killed: result.signal !== null
1295
+ });
1296
+ if (!parsed.options.reject)
1297
+ return error;
1298
+ throw error;
1299
+ }
1300
+ return {
1301
+ command,
1302
+ escapedCommand,
1303
+ exitCode: 0,
1304
+ stdout,
1305
+ stderr,
1306
+ failed: !1,
1307
+ timedOut: !1,
1308
+ isCanceled: !1,
1309
+ killed: !1
1310
+ };
1311
+ }
1312
+ var normalizeScriptStdin = ({ input, inputFile, stdio }) => input === void 0 && inputFile === void 0 && stdio === void 0 ? { stdin: "inherit" } : {}, normalizeScriptOptions = (options = {}) => ({
1313
+ preferLocal: !0,
1314
+ ...normalizeScriptStdin(options),
1315
+ ...options
1316
+ });
1317
+ function create$(options) {
1318
+ function $2(templatesOrOptions, ...expressions) {
1319
+ if (!Array.isArray(templatesOrOptions))
1320
+ return create$({ ...options, ...templatesOrOptions });
1321
+ let [file, ...args] = parseTemplates(templatesOrOptions, expressions);
1322
+ return execa(file, args, normalizeScriptOptions(options));
1323
+ }
1324
+ return $2.sync = (templates, ...expressions) => {
1325
+ if (!Array.isArray(templates))
1326
+ throw new TypeError("Please use $(options).sync`command` instead of $.sync(options)`command`.");
1327
+ let [file, ...args] = parseTemplates(templates, expressions);
1328
+ return execaSync(file, args, normalizeScriptOptions(options));
1329
+ }, $2;
1330
+ }
1331
+ var $ = create$();
1332
+
1333
+ // ../cli-kit/dist/public/node/os.js
1334
+ import { userInfo as osUserInfo } from "os";
1335
+ async function username(platform = process.platform) {
1336
+ outputDebug(outputContent`Obtaining user name...`);
1337
+ let environmentVariable = getEnvironmentVariable();
1338
+ if (environmentVariable)
1339
+ return environmentVariable;
1340
+ let userInfoUsername = getUsernameFromOsUserInfo();
1341
+ if (userInfoUsername)
1342
+ return userInfoUsername;
1343
+ try {
1344
+ if (platform === "win32") {
1345
+ let { stdout } = await execa("whoami");
1346
+ return cleanWindowsCommand(stdout);
1347
+ }
1348
+ let { stdout: userId } = await execa("id", ["-u"]);
1349
+ try {
1350
+ let { stdout } = await execa("id", ["-un", userId]);
1351
+ return stdout;
1352
+ } catch {
1353
+ }
1354
+ return makeUsernameFromId(userId);
1355
+ } catch {
1356
+ return null;
1357
+ }
1358
+ }
1359
+ var ARCH_MAP = {
1360
+ x64: "amd64",
1361
+ ia32: "386"
1362
+ };
1363
+ function platformAndArch(platform = process.platform, arch = process.arch) {
1364
+ let archString = ARCH_MAP[arch] ?? arch;
1365
+ return { platform: platform.match(/^win.+/) ? "windows" : platform, arch: archString };
1366
+ }
1367
+ function getEnvironmentVariable() {
1368
+ let { env } = process;
1369
+ return env.SUDO_USER || env.C9_USER || env.LOGNAME || env.USER || env.LNAME || env.USERNAME;
1370
+ }
1371
+ function getUsernameFromOsUserInfo() {
1372
+ try {
1373
+ return osUserInfo().username;
1374
+ } catch {
1375
+ return null;
1376
+ }
1377
+ }
1378
+ function cleanWindowsCommand(value) {
1379
+ return value.replace(/^.*\\/, "");
1380
+ }
1381
+ function makeUsernameFromId(userId) {
1382
+ return `no-username-${userId}`;
1383
+ }
1384
+
1385
+ export {
1386
+ require_signal_exit,
1387
+ execa,
1388
+ username,
1389
+ platformAndArch
1390
+ };
1391
+ //# sourceMappingURL=chunk-JMC4PKOZ.js.map