@better-webhook/cli 3.7.0 → 3.9.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/LICENSE +0 -1
- package/dist/dashboard/assets/{index-Dlqdzwyc.js → index-CZZLwai4.js} +8 -8
- package/dist/dashboard/index.html +1 -1
- package/dist/index.cjs +3346 -251
- package/dist/index.d.cts +2 -1
- package/dist/index.d.ts +2 -1
- package/dist/index.js +3395 -277
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,22 +1,3138 @@
|
|
|
1
1
|
#!/usr/bin/env node
|
|
2
|
+
var __create = Object.create;
|
|
3
|
+
var __defProp = Object.defineProperty;
|
|
4
|
+
var __getOwnPropDesc = Object.getOwnPropertyDescriptor;
|
|
5
|
+
var __getOwnPropNames = Object.getOwnPropertyNames;
|
|
6
|
+
var __getProtoOf = Object.getPrototypeOf;
|
|
7
|
+
var __hasOwnProp = Object.prototype.hasOwnProperty;
|
|
8
|
+
var __commonJS = (cb, mod) => function __require() {
|
|
9
|
+
return mod || (0, cb[__getOwnPropNames(cb)[0]])((mod = { exports: {} }).exports, mod), mod.exports;
|
|
10
|
+
};
|
|
11
|
+
var __copyProps = (to, from, except, desc) => {
|
|
12
|
+
if (from && typeof from === "object" || typeof from === "function") {
|
|
13
|
+
for (let key of __getOwnPropNames(from))
|
|
14
|
+
if (!__hasOwnProp.call(to, key) && key !== except)
|
|
15
|
+
__defProp(to, key, { get: () => from[key], enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable });
|
|
16
|
+
}
|
|
17
|
+
return to;
|
|
18
|
+
};
|
|
19
|
+
var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__getProtoOf(mod)) : {}, __copyProps(
|
|
20
|
+
// If the importer is in node compatibility mode or this is not an ESM
|
|
21
|
+
// file that has been converted to a CommonJS file using a Babel-
|
|
22
|
+
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
23
|
+
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
24
|
+
isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target,
|
|
25
|
+
mod
|
|
26
|
+
));
|
|
27
|
+
|
|
28
|
+
// ../../node_modules/.pnpm/cli-spinners@2.9.2/node_modules/cli-spinners/spinners.json
|
|
29
|
+
var require_spinners = __commonJS({
|
|
30
|
+
"../../node_modules/.pnpm/cli-spinners@2.9.2/node_modules/cli-spinners/spinners.json"(exports, module) {
|
|
31
|
+
module.exports = {
|
|
32
|
+
dots: {
|
|
33
|
+
interval: 80,
|
|
34
|
+
frames: [
|
|
35
|
+
"\u280B",
|
|
36
|
+
"\u2819",
|
|
37
|
+
"\u2839",
|
|
38
|
+
"\u2838",
|
|
39
|
+
"\u283C",
|
|
40
|
+
"\u2834",
|
|
41
|
+
"\u2826",
|
|
42
|
+
"\u2827",
|
|
43
|
+
"\u2807",
|
|
44
|
+
"\u280F"
|
|
45
|
+
]
|
|
46
|
+
},
|
|
47
|
+
dots2: {
|
|
48
|
+
interval: 80,
|
|
49
|
+
frames: [
|
|
50
|
+
"\u28FE",
|
|
51
|
+
"\u28FD",
|
|
52
|
+
"\u28FB",
|
|
53
|
+
"\u28BF",
|
|
54
|
+
"\u287F",
|
|
55
|
+
"\u28DF",
|
|
56
|
+
"\u28EF",
|
|
57
|
+
"\u28F7"
|
|
58
|
+
]
|
|
59
|
+
},
|
|
60
|
+
dots3: {
|
|
61
|
+
interval: 80,
|
|
62
|
+
frames: [
|
|
63
|
+
"\u280B",
|
|
64
|
+
"\u2819",
|
|
65
|
+
"\u281A",
|
|
66
|
+
"\u281E",
|
|
67
|
+
"\u2816",
|
|
68
|
+
"\u2826",
|
|
69
|
+
"\u2834",
|
|
70
|
+
"\u2832",
|
|
71
|
+
"\u2833",
|
|
72
|
+
"\u2813"
|
|
73
|
+
]
|
|
74
|
+
},
|
|
75
|
+
dots4: {
|
|
76
|
+
interval: 80,
|
|
77
|
+
frames: [
|
|
78
|
+
"\u2804",
|
|
79
|
+
"\u2806",
|
|
80
|
+
"\u2807",
|
|
81
|
+
"\u280B",
|
|
82
|
+
"\u2819",
|
|
83
|
+
"\u2838",
|
|
84
|
+
"\u2830",
|
|
85
|
+
"\u2820",
|
|
86
|
+
"\u2830",
|
|
87
|
+
"\u2838",
|
|
88
|
+
"\u2819",
|
|
89
|
+
"\u280B",
|
|
90
|
+
"\u2807",
|
|
91
|
+
"\u2806"
|
|
92
|
+
]
|
|
93
|
+
},
|
|
94
|
+
dots5: {
|
|
95
|
+
interval: 80,
|
|
96
|
+
frames: [
|
|
97
|
+
"\u280B",
|
|
98
|
+
"\u2819",
|
|
99
|
+
"\u281A",
|
|
100
|
+
"\u2812",
|
|
101
|
+
"\u2802",
|
|
102
|
+
"\u2802",
|
|
103
|
+
"\u2812",
|
|
104
|
+
"\u2832",
|
|
105
|
+
"\u2834",
|
|
106
|
+
"\u2826",
|
|
107
|
+
"\u2816",
|
|
108
|
+
"\u2812",
|
|
109
|
+
"\u2810",
|
|
110
|
+
"\u2810",
|
|
111
|
+
"\u2812",
|
|
112
|
+
"\u2813",
|
|
113
|
+
"\u280B"
|
|
114
|
+
]
|
|
115
|
+
},
|
|
116
|
+
dots6: {
|
|
117
|
+
interval: 80,
|
|
118
|
+
frames: [
|
|
119
|
+
"\u2801",
|
|
120
|
+
"\u2809",
|
|
121
|
+
"\u2819",
|
|
122
|
+
"\u281A",
|
|
123
|
+
"\u2812",
|
|
124
|
+
"\u2802",
|
|
125
|
+
"\u2802",
|
|
126
|
+
"\u2812",
|
|
127
|
+
"\u2832",
|
|
128
|
+
"\u2834",
|
|
129
|
+
"\u2824",
|
|
130
|
+
"\u2804",
|
|
131
|
+
"\u2804",
|
|
132
|
+
"\u2824",
|
|
133
|
+
"\u2834",
|
|
134
|
+
"\u2832",
|
|
135
|
+
"\u2812",
|
|
136
|
+
"\u2802",
|
|
137
|
+
"\u2802",
|
|
138
|
+
"\u2812",
|
|
139
|
+
"\u281A",
|
|
140
|
+
"\u2819",
|
|
141
|
+
"\u2809",
|
|
142
|
+
"\u2801"
|
|
143
|
+
]
|
|
144
|
+
},
|
|
145
|
+
dots7: {
|
|
146
|
+
interval: 80,
|
|
147
|
+
frames: [
|
|
148
|
+
"\u2808",
|
|
149
|
+
"\u2809",
|
|
150
|
+
"\u280B",
|
|
151
|
+
"\u2813",
|
|
152
|
+
"\u2812",
|
|
153
|
+
"\u2810",
|
|
154
|
+
"\u2810",
|
|
155
|
+
"\u2812",
|
|
156
|
+
"\u2816",
|
|
157
|
+
"\u2826",
|
|
158
|
+
"\u2824",
|
|
159
|
+
"\u2820",
|
|
160
|
+
"\u2820",
|
|
161
|
+
"\u2824",
|
|
162
|
+
"\u2826",
|
|
163
|
+
"\u2816",
|
|
164
|
+
"\u2812",
|
|
165
|
+
"\u2810",
|
|
166
|
+
"\u2810",
|
|
167
|
+
"\u2812",
|
|
168
|
+
"\u2813",
|
|
169
|
+
"\u280B",
|
|
170
|
+
"\u2809",
|
|
171
|
+
"\u2808"
|
|
172
|
+
]
|
|
173
|
+
},
|
|
174
|
+
dots8: {
|
|
175
|
+
interval: 80,
|
|
176
|
+
frames: [
|
|
177
|
+
"\u2801",
|
|
178
|
+
"\u2801",
|
|
179
|
+
"\u2809",
|
|
180
|
+
"\u2819",
|
|
181
|
+
"\u281A",
|
|
182
|
+
"\u2812",
|
|
183
|
+
"\u2802",
|
|
184
|
+
"\u2802",
|
|
185
|
+
"\u2812",
|
|
186
|
+
"\u2832",
|
|
187
|
+
"\u2834",
|
|
188
|
+
"\u2824",
|
|
189
|
+
"\u2804",
|
|
190
|
+
"\u2804",
|
|
191
|
+
"\u2824",
|
|
192
|
+
"\u2820",
|
|
193
|
+
"\u2820",
|
|
194
|
+
"\u2824",
|
|
195
|
+
"\u2826",
|
|
196
|
+
"\u2816",
|
|
197
|
+
"\u2812",
|
|
198
|
+
"\u2810",
|
|
199
|
+
"\u2810",
|
|
200
|
+
"\u2812",
|
|
201
|
+
"\u2813",
|
|
202
|
+
"\u280B",
|
|
203
|
+
"\u2809",
|
|
204
|
+
"\u2808",
|
|
205
|
+
"\u2808"
|
|
206
|
+
]
|
|
207
|
+
},
|
|
208
|
+
dots9: {
|
|
209
|
+
interval: 80,
|
|
210
|
+
frames: [
|
|
211
|
+
"\u28B9",
|
|
212
|
+
"\u28BA",
|
|
213
|
+
"\u28BC",
|
|
214
|
+
"\u28F8",
|
|
215
|
+
"\u28C7",
|
|
216
|
+
"\u2867",
|
|
217
|
+
"\u2857",
|
|
218
|
+
"\u284F"
|
|
219
|
+
]
|
|
220
|
+
},
|
|
221
|
+
dots10: {
|
|
222
|
+
interval: 80,
|
|
223
|
+
frames: [
|
|
224
|
+
"\u2884",
|
|
225
|
+
"\u2882",
|
|
226
|
+
"\u2881",
|
|
227
|
+
"\u2841",
|
|
228
|
+
"\u2848",
|
|
229
|
+
"\u2850",
|
|
230
|
+
"\u2860"
|
|
231
|
+
]
|
|
232
|
+
},
|
|
233
|
+
dots11: {
|
|
234
|
+
interval: 100,
|
|
235
|
+
frames: [
|
|
236
|
+
"\u2801",
|
|
237
|
+
"\u2802",
|
|
238
|
+
"\u2804",
|
|
239
|
+
"\u2840",
|
|
240
|
+
"\u2880",
|
|
241
|
+
"\u2820",
|
|
242
|
+
"\u2810",
|
|
243
|
+
"\u2808"
|
|
244
|
+
]
|
|
245
|
+
},
|
|
246
|
+
dots12: {
|
|
247
|
+
interval: 80,
|
|
248
|
+
frames: [
|
|
249
|
+
"\u2880\u2800",
|
|
250
|
+
"\u2840\u2800",
|
|
251
|
+
"\u2804\u2800",
|
|
252
|
+
"\u2882\u2800",
|
|
253
|
+
"\u2842\u2800",
|
|
254
|
+
"\u2805\u2800",
|
|
255
|
+
"\u2883\u2800",
|
|
256
|
+
"\u2843\u2800",
|
|
257
|
+
"\u280D\u2800",
|
|
258
|
+
"\u288B\u2800",
|
|
259
|
+
"\u284B\u2800",
|
|
260
|
+
"\u280D\u2801",
|
|
261
|
+
"\u288B\u2801",
|
|
262
|
+
"\u284B\u2801",
|
|
263
|
+
"\u280D\u2809",
|
|
264
|
+
"\u280B\u2809",
|
|
265
|
+
"\u280B\u2809",
|
|
266
|
+
"\u2809\u2819",
|
|
267
|
+
"\u2809\u2819",
|
|
268
|
+
"\u2809\u2829",
|
|
269
|
+
"\u2808\u2899",
|
|
270
|
+
"\u2808\u2859",
|
|
271
|
+
"\u2888\u2829",
|
|
272
|
+
"\u2840\u2899",
|
|
273
|
+
"\u2804\u2859",
|
|
274
|
+
"\u2882\u2829",
|
|
275
|
+
"\u2842\u2898",
|
|
276
|
+
"\u2805\u2858",
|
|
277
|
+
"\u2883\u2828",
|
|
278
|
+
"\u2843\u2890",
|
|
279
|
+
"\u280D\u2850",
|
|
280
|
+
"\u288B\u2820",
|
|
281
|
+
"\u284B\u2880",
|
|
282
|
+
"\u280D\u2841",
|
|
283
|
+
"\u288B\u2801",
|
|
284
|
+
"\u284B\u2801",
|
|
285
|
+
"\u280D\u2809",
|
|
286
|
+
"\u280B\u2809",
|
|
287
|
+
"\u280B\u2809",
|
|
288
|
+
"\u2809\u2819",
|
|
289
|
+
"\u2809\u2819",
|
|
290
|
+
"\u2809\u2829",
|
|
291
|
+
"\u2808\u2899",
|
|
292
|
+
"\u2808\u2859",
|
|
293
|
+
"\u2808\u2829",
|
|
294
|
+
"\u2800\u2899",
|
|
295
|
+
"\u2800\u2859",
|
|
296
|
+
"\u2800\u2829",
|
|
297
|
+
"\u2800\u2898",
|
|
298
|
+
"\u2800\u2858",
|
|
299
|
+
"\u2800\u2828",
|
|
300
|
+
"\u2800\u2890",
|
|
301
|
+
"\u2800\u2850",
|
|
302
|
+
"\u2800\u2820",
|
|
303
|
+
"\u2800\u2880",
|
|
304
|
+
"\u2800\u2840"
|
|
305
|
+
]
|
|
306
|
+
},
|
|
307
|
+
dots13: {
|
|
308
|
+
interval: 80,
|
|
309
|
+
frames: [
|
|
310
|
+
"\u28FC",
|
|
311
|
+
"\u28F9",
|
|
312
|
+
"\u28BB",
|
|
313
|
+
"\u283F",
|
|
314
|
+
"\u285F",
|
|
315
|
+
"\u28CF",
|
|
316
|
+
"\u28E7",
|
|
317
|
+
"\u28F6"
|
|
318
|
+
]
|
|
319
|
+
},
|
|
320
|
+
dots8Bit: {
|
|
321
|
+
interval: 80,
|
|
322
|
+
frames: [
|
|
323
|
+
"\u2800",
|
|
324
|
+
"\u2801",
|
|
325
|
+
"\u2802",
|
|
326
|
+
"\u2803",
|
|
327
|
+
"\u2804",
|
|
328
|
+
"\u2805",
|
|
329
|
+
"\u2806",
|
|
330
|
+
"\u2807",
|
|
331
|
+
"\u2840",
|
|
332
|
+
"\u2841",
|
|
333
|
+
"\u2842",
|
|
334
|
+
"\u2843",
|
|
335
|
+
"\u2844",
|
|
336
|
+
"\u2845",
|
|
337
|
+
"\u2846",
|
|
338
|
+
"\u2847",
|
|
339
|
+
"\u2808",
|
|
340
|
+
"\u2809",
|
|
341
|
+
"\u280A",
|
|
342
|
+
"\u280B",
|
|
343
|
+
"\u280C",
|
|
344
|
+
"\u280D",
|
|
345
|
+
"\u280E",
|
|
346
|
+
"\u280F",
|
|
347
|
+
"\u2848",
|
|
348
|
+
"\u2849",
|
|
349
|
+
"\u284A",
|
|
350
|
+
"\u284B",
|
|
351
|
+
"\u284C",
|
|
352
|
+
"\u284D",
|
|
353
|
+
"\u284E",
|
|
354
|
+
"\u284F",
|
|
355
|
+
"\u2810",
|
|
356
|
+
"\u2811",
|
|
357
|
+
"\u2812",
|
|
358
|
+
"\u2813",
|
|
359
|
+
"\u2814",
|
|
360
|
+
"\u2815",
|
|
361
|
+
"\u2816",
|
|
362
|
+
"\u2817",
|
|
363
|
+
"\u2850",
|
|
364
|
+
"\u2851",
|
|
365
|
+
"\u2852",
|
|
366
|
+
"\u2853",
|
|
367
|
+
"\u2854",
|
|
368
|
+
"\u2855",
|
|
369
|
+
"\u2856",
|
|
370
|
+
"\u2857",
|
|
371
|
+
"\u2818",
|
|
372
|
+
"\u2819",
|
|
373
|
+
"\u281A",
|
|
374
|
+
"\u281B",
|
|
375
|
+
"\u281C",
|
|
376
|
+
"\u281D",
|
|
377
|
+
"\u281E",
|
|
378
|
+
"\u281F",
|
|
379
|
+
"\u2858",
|
|
380
|
+
"\u2859",
|
|
381
|
+
"\u285A",
|
|
382
|
+
"\u285B",
|
|
383
|
+
"\u285C",
|
|
384
|
+
"\u285D",
|
|
385
|
+
"\u285E",
|
|
386
|
+
"\u285F",
|
|
387
|
+
"\u2820",
|
|
388
|
+
"\u2821",
|
|
389
|
+
"\u2822",
|
|
390
|
+
"\u2823",
|
|
391
|
+
"\u2824",
|
|
392
|
+
"\u2825",
|
|
393
|
+
"\u2826",
|
|
394
|
+
"\u2827",
|
|
395
|
+
"\u2860",
|
|
396
|
+
"\u2861",
|
|
397
|
+
"\u2862",
|
|
398
|
+
"\u2863",
|
|
399
|
+
"\u2864",
|
|
400
|
+
"\u2865",
|
|
401
|
+
"\u2866",
|
|
402
|
+
"\u2867",
|
|
403
|
+
"\u2828",
|
|
404
|
+
"\u2829",
|
|
405
|
+
"\u282A",
|
|
406
|
+
"\u282B",
|
|
407
|
+
"\u282C",
|
|
408
|
+
"\u282D",
|
|
409
|
+
"\u282E",
|
|
410
|
+
"\u282F",
|
|
411
|
+
"\u2868",
|
|
412
|
+
"\u2869",
|
|
413
|
+
"\u286A",
|
|
414
|
+
"\u286B",
|
|
415
|
+
"\u286C",
|
|
416
|
+
"\u286D",
|
|
417
|
+
"\u286E",
|
|
418
|
+
"\u286F",
|
|
419
|
+
"\u2830",
|
|
420
|
+
"\u2831",
|
|
421
|
+
"\u2832",
|
|
422
|
+
"\u2833",
|
|
423
|
+
"\u2834",
|
|
424
|
+
"\u2835",
|
|
425
|
+
"\u2836",
|
|
426
|
+
"\u2837",
|
|
427
|
+
"\u2870",
|
|
428
|
+
"\u2871",
|
|
429
|
+
"\u2872",
|
|
430
|
+
"\u2873",
|
|
431
|
+
"\u2874",
|
|
432
|
+
"\u2875",
|
|
433
|
+
"\u2876",
|
|
434
|
+
"\u2877",
|
|
435
|
+
"\u2838",
|
|
436
|
+
"\u2839",
|
|
437
|
+
"\u283A",
|
|
438
|
+
"\u283B",
|
|
439
|
+
"\u283C",
|
|
440
|
+
"\u283D",
|
|
441
|
+
"\u283E",
|
|
442
|
+
"\u283F",
|
|
443
|
+
"\u2878",
|
|
444
|
+
"\u2879",
|
|
445
|
+
"\u287A",
|
|
446
|
+
"\u287B",
|
|
447
|
+
"\u287C",
|
|
448
|
+
"\u287D",
|
|
449
|
+
"\u287E",
|
|
450
|
+
"\u287F",
|
|
451
|
+
"\u2880",
|
|
452
|
+
"\u2881",
|
|
453
|
+
"\u2882",
|
|
454
|
+
"\u2883",
|
|
455
|
+
"\u2884",
|
|
456
|
+
"\u2885",
|
|
457
|
+
"\u2886",
|
|
458
|
+
"\u2887",
|
|
459
|
+
"\u28C0",
|
|
460
|
+
"\u28C1",
|
|
461
|
+
"\u28C2",
|
|
462
|
+
"\u28C3",
|
|
463
|
+
"\u28C4",
|
|
464
|
+
"\u28C5",
|
|
465
|
+
"\u28C6",
|
|
466
|
+
"\u28C7",
|
|
467
|
+
"\u2888",
|
|
468
|
+
"\u2889",
|
|
469
|
+
"\u288A",
|
|
470
|
+
"\u288B",
|
|
471
|
+
"\u288C",
|
|
472
|
+
"\u288D",
|
|
473
|
+
"\u288E",
|
|
474
|
+
"\u288F",
|
|
475
|
+
"\u28C8",
|
|
476
|
+
"\u28C9",
|
|
477
|
+
"\u28CA",
|
|
478
|
+
"\u28CB",
|
|
479
|
+
"\u28CC",
|
|
480
|
+
"\u28CD",
|
|
481
|
+
"\u28CE",
|
|
482
|
+
"\u28CF",
|
|
483
|
+
"\u2890",
|
|
484
|
+
"\u2891",
|
|
485
|
+
"\u2892",
|
|
486
|
+
"\u2893",
|
|
487
|
+
"\u2894",
|
|
488
|
+
"\u2895",
|
|
489
|
+
"\u2896",
|
|
490
|
+
"\u2897",
|
|
491
|
+
"\u28D0",
|
|
492
|
+
"\u28D1",
|
|
493
|
+
"\u28D2",
|
|
494
|
+
"\u28D3",
|
|
495
|
+
"\u28D4",
|
|
496
|
+
"\u28D5",
|
|
497
|
+
"\u28D6",
|
|
498
|
+
"\u28D7",
|
|
499
|
+
"\u2898",
|
|
500
|
+
"\u2899",
|
|
501
|
+
"\u289A",
|
|
502
|
+
"\u289B",
|
|
503
|
+
"\u289C",
|
|
504
|
+
"\u289D",
|
|
505
|
+
"\u289E",
|
|
506
|
+
"\u289F",
|
|
507
|
+
"\u28D8",
|
|
508
|
+
"\u28D9",
|
|
509
|
+
"\u28DA",
|
|
510
|
+
"\u28DB",
|
|
511
|
+
"\u28DC",
|
|
512
|
+
"\u28DD",
|
|
513
|
+
"\u28DE",
|
|
514
|
+
"\u28DF",
|
|
515
|
+
"\u28A0",
|
|
516
|
+
"\u28A1",
|
|
517
|
+
"\u28A2",
|
|
518
|
+
"\u28A3",
|
|
519
|
+
"\u28A4",
|
|
520
|
+
"\u28A5",
|
|
521
|
+
"\u28A6",
|
|
522
|
+
"\u28A7",
|
|
523
|
+
"\u28E0",
|
|
524
|
+
"\u28E1",
|
|
525
|
+
"\u28E2",
|
|
526
|
+
"\u28E3",
|
|
527
|
+
"\u28E4",
|
|
528
|
+
"\u28E5",
|
|
529
|
+
"\u28E6",
|
|
530
|
+
"\u28E7",
|
|
531
|
+
"\u28A8",
|
|
532
|
+
"\u28A9",
|
|
533
|
+
"\u28AA",
|
|
534
|
+
"\u28AB",
|
|
535
|
+
"\u28AC",
|
|
536
|
+
"\u28AD",
|
|
537
|
+
"\u28AE",
|
|
538
|
+
"\u28AF",
|
|
539
|
+
"\u28E8",
|
|
540
|
+
"\u28E9",
|
|
541
|
+
"\u28EA",
|
|
542
|
+
"\u28EB",
|
|
543
|
+
"\u28EC",
|
|
544
|
+
"\u28ED",
|
|
545
|
+
"\u28EE",
|
|
546
|
+
"\u28EF",
|
|
547
|
+
"\u28B0",
|
|
548
|
+
"\u28B1",
|
|
549
|
+
"\u28B2",
|
|
550
|
+
"\u28B3",
|
|
551
|
+
"\u28B4",
|
|
552
|
+
"\u28B5",
|
|
553
|
+
"\u28B6",
|
|
554
|
+
"\u28B7",
|
|
555
|
+
"\u28F0",
|
|
556
|
+
"\u28F1",
|
|
557
|
+
"\u28F2",
|
|
558
|
+
"\u28F3",
|
|
559
|
+
"\u28F4",
|
|
560
|
+
"\u28F5",
|
|
561
|
+
"\u28F6",
|
|
562
|
+
"\u28F7",
|
|
563
|
+
"\u28B8",
|
|
564
|
+
"\u28B9",
|
|
565
|
+
"\u28BA",
|
|
566
|
+
"\u28BB",
|
|
567
|
+
"\u28BC",
|
|
568
|
+
"\u28BD",
|
|
569
|
+
"\u28BE",
|
|
570
|
+
"\u28BF",
|
|
571
|
+
"\u28F8",
|
|
572
|
+
"\u28F9",
|
|
573
|
+
"\u28FA",
|
|
574
|
+
"\u28FB",
|
|
575
|
+
"\u28FC",
|
|
576
|
+
"\u28FD",
|
|
577
|
+
"\u28FE",
|
|
578
|
+
"\u28FF"
|
|
579
|
+
]
|
|
580
|
+
},
|
|
581
|
+
sand: {
|
|
582
|
+
interval: 80,
|
|
583
|
+
frames: [
|
|
584
|
+
"\u2801",
|
|
585
|
+
"\u2802",
|
|
586
|
+
"\u2804",
|
|
587
|
+
"\u2840",
|
|
588
|
+
"\u2848",
|
|
589
|
+
"\u2850",
|
|
590
|
+
"\u2860",
|
|
591
|
+
"\u28C0",
|
|
592
|
+
"\u28C1",
|
|
593
|
+
"\u28C2",
|
|
594
|
+
"\u28C4",
|
|
595
|
+
"\u28CC",
|
|
596
|
+
"\u28D4",
|
|
597
|
+
"\u28E4",
|
|
598
|
+
"\u28E5",
|
|
599
|
+
"\u28E6",
|
|
600
|
+
"\u28EE",
|
|
601
|
+
"\u28F6",
|
|
602
|
+
"\u28F7",
|
|
603
|
+
"\u28FF",
|
|
604
|
+
"\u287F",
|
|
605
|
+
"\u283F",
|
|
606
|
+
"\u289F",
|
|
607
|
+
"\u281F",
|
|
608
|
+
"\u285B",
|
|
609
|
+
"\u281B",
|
|
610
|
+
"\u282B",
|
|
611
|
+
"\u288B",
|
|
612
|
+
"\u280B",
|
|
613
|
+
"\u280D",
|
|
614
|
+
"\u2849",
|
|
615
|
+
"\u2809",
|
|
616
|
+
"\u2811",
|
|
617
|
+
"\u2821",
|
|
618
|
+
"\u2881"
|
|
619
|
+
]
|
|
620
|
+
},
|
|
621
|
+
line: {
|
|
622
|
+
interval: 130,
|
|
623
|
+
frames: [
|
|
624
|
+
"-",
|
|
625
|
+
"\\",
|
|
626
|
+
"|",
|
|
627
|
+
"/"
|
|
628
|
+
]
|
|
629
|
+
},
|
|
630
|
+
line2: {
|
|
631
|
+
interval: 100,
|
|
632
|
+
frames: [
|
|
633
|
+
"\u2802",
|
|
634
|
+
"-",
|
|
635
|
+
"\u2013",
|
|
636
|
+
"\u2014",
|
|
637
|
+
"\u2013",
|
|
638
|
+
"-"
|
|
639
|
+
]
|
|
640
|
+
},
|
|
641
|
+
pipe: {
|
|
642
|
+
interval: 100,
|
|
643
|
+
frames: [
|
|
644
|
+
"\u2524",
|
|
645
|
+
"\u2518",
|
|
646
|
+
"\u2534",
|
|
647
|
+
"\u2514",
|
|
648
|
+
"\u251C",
|
|
649
|
+
"\u250C",
|
|
650
|
+
"\u252C",
|
|
651
|
+
"\u2510"
|
|
652
|
+
]
|
|
653
|
+
},
|
|
654
|
+
simpleDots: {
|
|
655
|
+
interval: 400,
|
|
656
|
+
frames: [
|
|
657
|
+
". ",
|
|
658
|
+
".. ",
|
|
659
|
+
"...",
|
|
660
|
+
" "
|
|
661
|
+
]
|
|
662
|
+
},
|
|
663
|
+
simpleDotsScrolling: {
|
|
664
|
+
interval: 200,
|
|
665
|
+
frames: [
|
|
666
|
+
". ",
|
|
667
|
+
".. ",
|
|
668
|
+
"...",
|
|
669
|
+
" ..",
|
|
670
|
+
" .",
|
|
671
|
+
" "
|
|
672
|
+
]
|
|
673
|
+
},
|
|
674
|
+
star: {
|
|
675
|
+
interval: 70,
|
|
676
|
+
frames: [
|
|
677
|
+
"\u2736",
|
|
678
|
+
"\u2738",
|
|
679
|
+
"\u2739",
|
|
680
|
+
"\u273A",
|
|
681
|
+
"\u2739",
|
|
682
|
+
"\u2737"
|
|
683
|
+
]
|
|
684
|
+
},
|
|
685
|
+
star2: {
|
|
686
|
+
interval: 80,
|
|
687
|
+
frames: [
|
|
688
|
+
"+",
|
|
689
|
+
"x",
|
|
690
|
+
"*"
|
|
691
|
+
]
|
|
692
|
+
},
|
|
693
|
+
flip: {
|
|
694
|
+
interval: 70,
|
|
695
|
+
frames: [
|
|
696
|
+
"_",
|
|
697
|
+
"_",
|
|
698
|
+
"_",
|
|
699
|
+
"-",
|
|
700
|
+
"`",
|
|
701
|
+
"`",
|
|
702
|
+
"'",
|
|
703
|
+
"\xB4",
|
|
704
|
+
"-",
|
|
705
|
+
"_",
|
|
706
|
+
"_",
|
|
707
|
+
"_"
|
|
708
|
+
]
|
|
709
|
+
},
|
|
710
|
+
hamburger: {
|
|
711
|
+
interval: 100,
|
|
712
|
+
frames: [
|
|
713
|
+
"\u2631",
|
|
714
|
+
"\u2632",
|
|
715
|
+
"\u2634"
|
|
716
|
+
]
|
|
717
|
+
},
|
|
718
|
+
growVertical: {
|
|
719
|
+
interval: 120,
|
|
720
|
+
frames: [
|
|
721
|
+
"\u2581",
|
|
722
|
+
"\u2583",
|
|
723
|
+
"\u2584",
|
|
724
|
+
"\u2585",
|
|
725
|
+
"\u2586",
|
|
726
|
+
"\u2587",
|
|
727
|
+
"\u2586",
|
|
728
|
+
"\u2585",
|
|
729
|
+
"\u2584",
|
|
730
|
+
"\u2583"
|
|
731
|
+
]
|
|
732
|
+
},
|
|
733
|
+
growHorizontal: {
|
|
734
|
+
interval: 120,
|
|
735
|
+
frames: [
|
|
736
|
+
"\u258F",
|
|
737
|
+
"\u258E",
|
|
738
|
+
"\u258D",
|
|
739
|
+
"\u258C",
|
|
740
|
+
"\u258B",
|
|
741
|
+
"\u258A",
|
|
742
|
+
"\u2589",
|
|
743
|
+
"\u258A",
|
|
744
|
+
"\u258B",
|
|
745
|
+
"\u258C",
|
|
746
|
+
"\u258D",
|
|
747
|
+
"\u258E"
|
|
748
|
+
]
|
|
749
|
+
},
|
|
750
|
+
balloon: {
|
|
751
|
+
interval: 140,
|
|
752
|
+
frames: [
|
|
753
|
+
" ",
|
|
754
|
+
".",
|
|
755
|
+
"o",
|
|
756
|
+
"O",
|
|
757
|
+
"@",
|
|
758
|
+
"*",
|
|
759
|
+
" "
|
|
760
|
+
]
|
|
761
|
+
},
|
|
762
|
+
balloon2: {
|
|
763
|
+
interval: 120,
|
|
764
|
+
frames: [
|
|
765
|
+
".",
|
|
766
|
+
"o",
|
|
767
|
+
"O",
|
|
768
|
+
"\xB0",
|
|
769
|
+
"O",
|
|
770
|
+
"o",
|
|
771
|
+
"."
|
|
772
|
+
]
|
|
773
|
+
},
|
|
774
|
+
noise: {
|
|
775
|
+
interval: 100,
|
|
776
|
+
frames: [
|
|
777
|
+
"\u2593",
|
|
778
|
+
"\u2592",
|
|
779
|
+
"\u2591"
|
|
780
|
+
]
|
|
781
|
+
},
|
|
782
|
+
bounce: {
|
|
783
|
+
interval: 120,
|
|
784
|
+
frames: [
|
|
785
|
+
"\u2801",
|
|
786
|
+
"\u2802",
|
|
787
|
+
"\u2804",
|
|
788
|
+
"\u2802"
|
|
789
|
+
]
|
|
790
|
+
},
|
|
791
|
+
boxBounce: {
|
|
792
|
+
interval: 120,
|
|
793
|
+
frames: [
|
|
794
|
+
"\u2596",
|
|
795
|
+
"\u2598",
|
|
796
|
+
"\u259D",
|
|
797
|
+
"\u2597"
|
|
798
|
+
]
|
|
799
|
+
},
|
|
800
|
+
boxBounce2: {
|
|
801
|
+
interval: 100,
|
|
802
|
+
frames: [
|
|
803
|
+
"\u258C",
|
|
804
|
+
"\u2580",
|
|
805
|
+
"\u2590",
|
|
806
|
+
"\u2584"
|
|
807
|
+
]
|
|
808
|
+
},
|
|
809
|
+
triangle: {
|
|
810
|
+
interval: 50,
|
|
811
|
+
frames: [
|
|
812
|
+
"\u25E2",
|
|
813
|
+
"\u25E3",
|
|
814
|
+
"\u25E4",
|
|
815
|
+
"\u25E5"
|
|
816
|
+
]
|
|
817
|
+
},
|
|
818
|
+
binary: {
|
|
819
|
+
interval: 80,
|
|
820
|
+
frames: [
|
|
821
|
+
"010010",
|
|
822
|
+
"001100",
|
|
823
|
+
"100101",
|
|
824
|
+
"111010",
|
|
825
|
+
"111101",
|
|
826
|
+
"010111",
|
|
827
|
+
"101011",
|
|
828
|
+
"111000",
|
|
829
|
+
"110011",
|
|
830
|
+
"110101"
|
|
831
|
+
]
|
|
832
|
+
},
|
|
833
|
+
arc: {
|
|
834
|
+
interval: 100,
|
|
835
|
+
frames: [
|
|
836
|
+
"\u25DC",
|
|
837
|
+
"\u25E0",
|
|
838
|
+
"\u25DD",
|
|
839
|
+
"\u25DE",
|
|
840
|
+
"\u25E1",
|
|
841
|
+
"\u25DF"
|
|
842
|
+
]
|
|
843
|
+
},
|
|
844
|
+
circle: {
|
|
845
|
+
interval: 120,
|
|
846
|
+
frames: [
|
|
847
|
+
"\u25E1",
|
|
848
|
+
"\u2299",
|
|
849
|
+
"\u25E0"
|
|
850
|
+
]
|
|
851
|
+
},
|
|
852
|
+
squareCorners: {
|
|
853
|
+
interval: 180,
|
|
854
|
+
frames: [
|
|
855
|
+
"\u25F0",
|
|
856
|
+
"\u25F3",
|
|
857
|
+
"\u25F2",
|
|
858
|
+
"\u25F1"
|
|
859
|
+
]
|
|
860
|
+
},
|
|
861
|
+
circleQuarters: {
|
|
862
|
+
interval: 120,
|
|
863
|
+
frames: [
|
|
864
|
+
"\u25F4",
|
|
865
|
+
"\u25F7",
|
|
866
|
+
"\u25F6",
|
|
867
|
+
"\u25F5"
|
|
868
|
+
]
|
|
869
|
+
},
|
|
870
|
+
circleHalves: {
|
|
871
|
+
interval: 50,
|
|
872
|
+
frames: [
|
|
873
|
+
"\u25D0",
|
|
874
|
+
"\u25D3",
|
|
875
|
+
"\u25D1",
|
|
876
|
+
"\u25D2"
|
|
877
|
+
]
|
|
878
|
+
},
|
|
879
|
+
squish: {
|
|
880
|
+
interval: 100,
|
|
881
|
+
frames: [
|
|
882
|
+
"\u256B",
|
|
883
|
+
"\u256A"
|
|
884
|
+
]
|
|
885
|
+
},
|
|
886
|
+
toggle: {
|
|
887
|
+
interval: 250,
|
|
888
|
+
frames: [
|
|
889
|
+
"\u22B6",
|
|
890
|
+
"\u22B7"
|
|
891
|
+
]
|
|
892
|
+
},
|
|
893
|
+
toggle2: {
|
|
894
|
+
interval: 80,
|
|
895
|
+
frames: [
|
|
896
|
+
"\u25AB",
|
|
897
|
+
"\u25AA"
|
|
898
|
+
]
|
|
899
|
+
},
|
|
900
|
+
toggle3: {
|
|
901
|
+
interval: 120,
|
|
902
|
+
frames: [
|
|
903
|
+
"\u25A1",
|
|
904
|
+
"\u25A0"
|
|
905
|
+
]
|
|
906
|
+
},
|
|
907
|
+
toggle4: {
|
|
908
|
+
interval: 100,
|
|
909
|
+
frames: [
|
|
910
|
+
"\u25A0",
|
|
911
|
+
"\u25A1",
|
|
912
|
+
"\u25AA",
|
|
913
|
+
"\u25AB"
|
|
914
|
+
]
|
|
915
|
+
},
|
|
916
|
+
toggle5: {
|
|
917
|
+
interval: 100,
|
|
918
|
+
frames: [
|
|
919
|
+
"\u25AE",
|
|
920
|
+
"\u25AF"
|
|
921
|
+
]
|
|
922
|
+
},
|
|
923
|
+
toggle6: {
|
|
924
|
+
interval: 300,
|
|
925
|
+
frames: [
|
|
926
|
+
"\u101D",
|
|
927
|
+
"\u1040"
|
|
928
|
+
]
|
|
929
|
+
},
|
|
930
|
+
toggle7: {
|
|
931
|
+
interval: 80,
|
|
932
|
+
frames: [
|
|
933
|
+
"\u29BE",
|
|
934
|
+
"\u29BF"
|
|
935
|
+
]
|
|
936
|
+
},
|
|
937
|
+
toggle8: {
|
|
938
|
+
interval: 100,
|
|
939
|
+
frames: [
|
|
940
|
+
"\u25CD",
|
|
941
|
+
"\u25CC"
|
|
942
|
+
]
|
|
943
|
+
},
|
|
944
|
+
toggle9: {
|
|
945
|
+
interval: 100,
|
|
946
|
+
frames: [
|
|
947
|
+
"\u25C9",
|
|
948
|
+
"\u25CE"
|
|
949
|
+
]
|
|
950
|
+
},
|
|
951
|
+
toggle10: {
|
|
952
|
+
interval: 100,
|
|
953
|
+
frames: [
|
|
954
|
+
"\u3282",
|
|
955
|
+
"\u3280",
|
|
956
|
+
"\u3281"
|
|
957
|
+
]
|
|
958
|
+
},
|
|
959
|
+
toggle11: {
|
|
960
|
+
interval: 50,
|
|
961
|
+
frames: [
|
|
962
|
+
"\u29C7",
|
|
963
|
+
"\u29C6"
|
|
964
|
+
]
|
|
965
|
+
},
|
|
966
|
+
toggle12: {
|
|
967
|
+
interval: 120,
|
|
968
|
+
frames: [
|
|
969
|
+
"\u2617",
|
|
970
|
+
"\u2616"
|
|
971
|
+
]
|
|
972
|
+
},
|
|
973
|
+
toggle13: {
|
|
974
|
+
interval: 80,
|
|
975
|
+
frames: [
|
|
976
|
+
"=",
|
|
977
|
+
"*",
|
|
978
|
+
"-"
|
|
979
|
+
]
|
|
980
|
+
},
|
|
981
|
+
arrow: {
|
|
982
|
+
interval: 100,
|
|
983
|
+
frames: [
|
|
984
|
+
"\u2190",
|
|
985
|
+
"\u2196",
|
|
986
|
+
"\u2191",
|
|
987
|
+
"\u2197",
|
|
988
|
+
"\u2192",
|
|
989
|
+
"\u2198",
|
|
990
|
+
"\u2193",
|
|
991
|
+
"\u2199"
|
|
992
|
+
]
|
|
993
|
+
},
|
|
994
|
+
arrow2: {
|
|
995
|
+
interval: 80,
|
|
996
|
+
frames: [
|
|
997
|
+
"\u2B06\uFE0F ",
|
|
998
|
+
"\u2197\uFE0F ",
|
|
999
|
+
"\u27A1\uFE0F ",
|
|
1000
|
+
"\u2198\uFE0F ",
|
|
1001
|
+
"\u2B07\uFE0F ",
|
|
1002
|
+
"\u2199\uFE0F ",
|
|
1003
|
+
"\u2B05\uFE0F ",
|
|
1004
|
+
"\u2196\uFE0F "
|
|
1005
|
+
]
|
|
1006
|
+
},
|
|
1007
|
+
arrow3: {
|
|
1008
|
+
interval: 120,
|
|
1009
|
+
frames: [
|
|
1010
|
+
"\u25B9\u25B9\u25B9\u25B9\u25B9",
|
|
1011
|
+
"\u25B8\u25B9\u25B9\u25B9\u25B9",
|
|
1012
|
+
"\u25B9\u25B8\u25B9\u25B9\u25B9",
|
|
1013
|
+
"\u25B9\u25B9\u25B8\u25B9\u25B9",
|
|
1014
|
+
"\u25B9\u25B9\u25B9\u25B8\u25B9",
|
|
1015
|
+
"\u25B9\u25B9\u25B9\u25B9\u25B8"
|
|
1016
|
+
]
|
|
1017
|
+
},
|
|
1018
|
+
bouncingBar: {
|
|
1019
|
+
interval: 80,
|
|
1020
|
+
frames: [
|
|
1021
|
+
"[ ]",
|
|
1022
|
+
"[= ]",
|
|
1023
|
+
"[== ]",
|
|
1024
|
+
"[=== ]",
|
|
1025
|
+
"[====]",
|
|
1026
|
+
"[ ===]",
|
|
1027
|
+
"[ ==]",
|
|
1028
|
+
"[ =]",
|
|
1029
|
+
"[ ]",
|
|
1030
|
+
"[ =]",
|
|
1031
|
+
"[ ==]",
|
|
1032
|
+
"[ ===]",
|
|
1033
|
+
"[====]",
|
|
1034
|
+
"[=== ]",
|
|
1035
|
+
"[== ]",
|
|
1036
|
+
"[= ]"
|
|
1037
|
+
]
|
|
1038
|
+
},
|
|
1039
|
+
bouncingBall: {
|
|
1040
|
+
interval: 80,
|
|
1041
|
+
frames: [
|
|
1042
|
+
"( \u25CF )",
|
|
1043
|
+
"( \u25CF )",
|
|
1044
|
+
"( \u25CF )",
|
|
1045
|
+
"( \u25CF )",
|
|
1046
|
+
"( \u25CF)",
|
|
1047
|
+
"( \u25CF )",
|
|
1048
|
+
"( \u25CF )",
|
|
1049
|
+
"( \u25CF )",
|
|
1050
|
+
"( \u25CF )",
|
|
1051
|
+
"(\u25CF )"
|
|
1052
|
+
]
|
|
1053
|
+
},
|
|
1054
|
+
smiley: {
|
|
1055
|
+
interval: 200,
|
|
1056
|
+
frames: [
|
|
1057
|
+
"\u{1F604} ",
|
|
1058
|
+
"\u{1F61D} "
|
|
1059
|
+
]
|
|
1060
|
+
},
|
|
1061
|
+
monkey: {
|
|
1062
|
+
interval: 300,
|
|
1063
|
+
frames: [
|
|
1064
|
+
"\u{1F648} ",
|
|
1065
|
+
"\u{1F648} ",
|
|
1066
|
+
"\u{1F649} ",
|
|
1067
|
+
"\u{1F64A} "
|
|
1068
|
+
]
|
|
1069
|
+
},
|
|
1070
|
+
hearts: {
|
|
1071
|
+
interval: 100,
|
|
1072
|
+
frames: [
|
|
1073
|
+
"\u{1F49B} ",
|
|
1074
|
+
"\u{1F499} ",
|
|
1075
|
+
"\u{1F49C} ",
|
|
1076
|
+
"\u{1F49A} ",
|
|
1077
|
+
"\u2764\uFE0F "
|
|
1078
|
+
]
|
|
1079
|
+
},
|
|
1080
|
+
clock: {
|
|
1081
|
+
interval: 100,
|
|
1082
|
+
frames: [
|
|
1083
|
+
"\u{1F55B} ",
|
|
1084
|
+
"\u{1F550} ",
|
|
1085
|
+
"\u{1F551} ",
|
|
1086
|
+
"\u{1F552} ",
|
|
1087
|
+
"\u{1F553} ",
|
|
1088
|
+
"\u{1F554} ",
|
|
1089
|
+
"\u{1F555} ",
|
|
1090
|
+
"\u{1F556} ",
|
|
1091
|
+
"\u{1F557} ",
|
|
1092
|
+
"\u{1F558} ",
|
|
1093
|
+
"\u{1F559} ",
|
|
1094
|
+
"\u{1F55A} "
|
|
1095
|
+
]
|
|
1096
|
+
},
|
|
1097
|
+
earth: {
|
|
1098
|
+
interval: 180,
|
|
1099
|
+
frames: [
|
|
1100
|
+
"\u{1F30D} ",
|
|
1101
|
+
"\u{1F30E} ",
|
|
1102
|
+
"\u{1F30F} "
|
|
1103
|
+
]
|
|
1104
|
+
},
|
|
1105
|
+
material: {
|
|
1106
|
+
interval: 17,
|
|
1107
|
+
frames: [
|
|
1108
|
+
"\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1109
|
+
"\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1110
|
+
"\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1111
|
+
"\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1112
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1113
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1114
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1115
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1116
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1117
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1118
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1119
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1120
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1121
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1122
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1123
|
+
"\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581",
|
|
1124
|
+
"\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581",
|
|
1125
|
+
"\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581",
|
|
1126
|
+
"\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581",
|
|
1127
|
+
"\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581",
|
|
1128
|
+
"\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581",
|
|
1129
|
+
"\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581",
|
|
1130
|
+
"\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581",
|
|
1131
|
+
"\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581",
|
|
1132
|
+
"\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581",
|
|
1133
|
+
"\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581",
|
|
1134
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1135
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1136
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1137
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1138
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1139
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1140
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1141
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1142
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1143
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1144
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1145
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1146
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1147
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588",
|
|
1148
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588",
|
|
1149
|
+
"\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588",
|
|
1150
|
+
"\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588",
|
|
1151
|
+
"\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588",
|
|
1152
|
+
"\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588",
|
|
1153
|
+
"\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588",
|
|
1154
|
+
"\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588",
|
|
1155
|
+
"\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588",
|
|
1156
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588",
|
|
1157
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1158
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1159
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1160
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1161
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1162
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1163
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1164
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1165
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1166
|
+
"\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1167
|
+
"\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581",
|
|
1168
|
+
"\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581\u2581",
|
|
1169
|
+
"\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581\u2581",
|
|
1170
|
+
"\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581",
|
|
1171
|
+
"\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581",
|
|
1172
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581",
|
|
1173
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581",
|
|
1174
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581\u2581",
|
|
1175
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581",
|
|
1176
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581\u2581",
|
|
1177
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581",
|
|
1178
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581",
|
|
1179
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581",
|
|
1180
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581",
|
|
1181
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588\u2581",
|
|
1182
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1183
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588\u2588\u2588",
|
|
1184
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588\u2588",
|
|
1185
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588",
|
|
1186
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588",
|
|
1187
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588\u2588",
|
|
1188
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588",
|
|
1189
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588\u2588",
|
|
1190
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588",
|
|
1191
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588",
|
|
1192
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588\u2588",
|
|
1193
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588",
|
|
1194
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588",
|
|
1195
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2588",
|
|
1196
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1197
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1198
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581",
|
|
1199
|
+
"\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581\u2581"
|
|
1200
|
+
]
|
|
1201
|
+
},
|
|
1202
|
+
moon: {
|
|
1203
|
+
interval: 80,
|
|
1204
|
+
frames: [
|
|
1205
|
+
"\u{1F311} ",
|
|
1206
|
+
"\u{1F312} ",
|
|
1207
|
+
"\u{1F313} ",
|
|
1208
|
+
"\u{1F314} ",
|
|
1209
|
+
"\u{1F315} ",
|
|
1210
|
+
"\u{1F316} ",
|
|
1211
|
+
"\u{1F317} ",
|
|
1212
|
+
"\u{1F318} "
|
|
1213
|
+
]
|
|
1214
|
+
},
|
|
1215
|
+
runner: {
|
|
1216
|
+
interval: 140,
|
|
1217
|
+
frames: [
|
|
1218
|
+
"\u{1F6B6} ",
|
|
1219
|
+
"\u{1F3C3} "
|
|
1220
|
+
]
|
|
1221
|
+
},
|
|
1222
|
+
pong: {
|
|
1223
|
+
interval: 80,
|
|
1224
|
+
frames: [
|
|
1225
|
+
"\u2590\u2802 \u258C",
|
|
1226
|
+
"\u2590\u2808 \u258C",
|
|
1227
|
+
"\u2590 \u2802 \u258C",
|
|
1228
|
+
"\u2590 \u2820 \u258C",
|
|
1229
|
+
"\u2590 \u2840 \u258C",
|
|
1230
|
+
"\u2590 \u2820 \u258C",
|
|
1231
|
+
"\u2590 \u2802 \u258C",
|
|
1232
|
+
"\u2590 \u2808 \u258C",
|
|
1233
|
+
"\u2590 \u2802 \u258C",
|
|
1234
|
+
"\u2590 \u2820 \u258C",
|
|
1235
|
+
"\u2590 \u2840 \u258C",
|
|
1236
|
+
"\u2590 \u2820 \u258C",
|
|
1237
|
+
"\u2590 \u2802 \u258C",
|
|
1238
|
+
"\u2590 \u2808 \u258C",
|
|
1239
|
+
"\u2590 \u2802\u258C",
|
|
1240
|
+
"\u2590 \u2820\u258C",
|
|
1241
|
+
"\u2590 \u2840\u258C",
|
|
1242
|
+
"\u2590 \u2820 \u258C",
|
|
1243
|
+
"\u2590 \u2802 \u258C",
|
|
1244
|
+
"\u2590 \u2808 \u258C",
|
|
1245
|
+
"\u2590 \u2802 \u258C",
|
|
1246
|
+
"\u2590 \u2820 \u258C",
|
|
1247
|
+
"\u2590 \u2840 \u258C",
|
|
1248
|
+
"\u2590 \u2820 \u258C",
|
|
1249
|
+
"\u2590 \u2802 \u258C",
|
|
1250
|
+
"\u2590 \u2808 \u258C",
|
|
1251
|
+
"\u2590 \u2802 \u258C",
|
|
1252
|
+
"\u2590 \u2820 \u258C",
|
|
1253
|
+
"\u2590 \u2840 \u258C",
|
|
1254
|
+
"\u2590\u2820 \u258C"
|
|
1255
|
+
]
|
|
1256
|
+
},
|
|
1257
|
+
shark: {
|
|
1258
|
+
interval: 120,
|
|
1259
|
+
frames: [
|
|
1260
|
+
"\u2590|\\____________\u258C",
|
|
1261
|
+
"\u2590_|\\___________\u258C",
|
|
1262
|
+
"\u2590__|\\__________\u258C",
|
|
1263
|
+
"\u2590___|\\_________\u258C",
|
|
1264
|
+
"\u2590____|\\________\u258C",
|
|
1265
|
+
"\u2590_____|\\_______\u258C",
|
|
1266
|
+
"\u2590______|\\______\u258C",
|
|
1267
|
+
"\u2590_______|\\_____\u258C",
|
|
1268
|
+
"\u2590________|\\____\u258C",
|
|
1269
|
+
"\u2590_________|\\___\u258C",
|
|
1270
|
+
"\u2590__________|\\__\u258C",
|
|
1271
|
+
"\u2590___________|\\_\u258C",
|
|
1272
|
+
"\u2590____________|\\\u258C",
|
|
1273
|
+
"\u2590____________/|\u258C",
|
|
1274
|
+
"\u2590___________/|_\u258C",
|
|
1275
|
+
"\u2590__________/|__\u258C",
|
|
1276
|
+
"\u2590_________/|___\u258C",
|
|
1277
|
+
"\u2590________/|____\u258C",
|
|
1278
|
+
"\u2590_______/|_____\u258C",
|
|
1279
|
+
"\u2590______/|______\u258C",
|
|
1280
|
+
"\u2590_____/|_______\u258C",
|
|
1281
|
+
"\u2590____/|________\u258C",
|
|
1282
|
+
"\u2590___/|_________\u258C",
|
|
1283
|
+
"\u2590__/|__________\u258C",
|
|
1284
|
+
"\u2590_/|___________\u258C",
|
|
1285
|
+
"\u2590/|____________\u258C"
|
|
1286
|
+
]
|
|
1287
|
+
},
|
|
1288
|
+
dqpb: {
|
|
1289
|
+
interval: 100,
|
|
1290
|
+
frames: [
|
|
1291
|
+
"d",
|
|
1292
|
+
"q",
|
|
1293
|
+
"p",
|
|
1294
|
+
"b"
|
|
1295
|
+
]
|
|
1296
|
+
},
|
|
1297
|
+
weather: {
|
|
1298
|
+
interval: 100,
|
|
1299
|
+
frames: [
|
|
1300
|
+
"\u2600\uFE0F ",
|
|
1301
|
+
"\u2600\uFE0F ",
|
|
1302
|
+
"\u2600\uFE0F ",
|
|
1303
|
+
"\u{1F324} ",
|
|
1304
|
+
"\u26C5\uFE0F ",
|
|
1305
|
+
"\u{1F325} ",
|
|
1306
|
+
"\u2601\uFE0F ",
|
|
1307
|
+
"\u{1F327} ",
|
|
1308
|
+
"\u{1F328} ",
|
|
1309
|
+
"\u{1F327} ",
|
|
1310
|
+
"\u{1F328} ",
|
|
1311
|
+
"\u{1F327} ",
|
|
1312
|
+
"\u{1F328} ",
|
|
1313
|
+
"\u26C8 ",
|
|
1314
|
+
"\u{1F328} ",
|
|
1315
|
+
"\u{1F327} ",
|
|
1316
|
+
"\u{1F328} ",
|
|
1317
|
+
"\u2601\uFE0F ",
|
|
1318
|
+
"\u{1F325} ",
|
|
1319
|
+
"\u26C5\uFE0F ",
|
|
1320
|
+
"\u{1F324} ",
|
|
1321
|
+
"\u2600\uFE0F ",
|
|
1322
|
+
"\u2600\uFE0F "
|
|
1323
|
+
]
|
|
1324
|
+
},
|
|
1325
|
+
christmas: {
|
|
1326
|
+
interval: 400,
|
|
1327
|
+
frames: [
|
|
1328
|
+
"\u{1F332}",
|
|
1329
|
+
"\u{1F384}"
|
|
1330
|
+
]
|
|
1331
|
+
},
|
|
1332
|
+
grenade: {
|
|
1333
|
+
interval: 80,
|
|
1334
|
+
frames: [
|
|
1335
|
+
"\u060C ",
|
|
1336
|
+
"\u2032 ",
|
|
1337
|
+
" \xB4 ",
|
|
1338
|
+
" \u203E ",
|
|
1339
|
+
" \u2E0C",
|
|
1340
|
+
" \u2E0A",
|
|
1341
|
+
" |",
|
|
1342
|
+
" \u204E",
|
|
1343
|
+
" \u2055",
|
|
1344
|
+
" \u0DF4 ",
|
|
1345
|
+
" \u2053",
|
|
1346
|
+
" ",
|
|
1347
|
+
" ",
|
|
1348
|
+
" "
|
|
1349
|
+
]
|
|
1350
|
+
},
|
|
1351
|
+
point: {
|
|
1352
|
+
interval: 125,
|
|
1353
|
+
frames: [
|
|
1354
|
+
"\u2219\u2219\u2219",
|
|
1355
|
+
"\u25CF\u2219\u2219",
|
|
1356
|
+
"\u2219\u25CF\u2219",
|
|
1357
|
+
"\u2219\u2219\u25CF",
|
|
1358
|
+
"\u2219\u2219\u2219"
|
|
1359
|
+
]
|
|
1360
|
+
},
|
|
1361
|
+
layer: {
|
|
1362
|
+
interval: 150,
|
|
1363
|
+
frames: [
|
|
1364
|
+
"-",
|
|
1365
|
+
"=",
|
|
1366
|
+
"\u2261"
|
|
1367
|
+
]
|
|
1368
|
+
},
|
|
1369
|
+
betaWave: {
|
|
1370
|
+
interval: 80,
|
|
1371
|
+
frames: [
|
|
1372
|
+
"\u03C1\u03B2\u03B2\u03B2\u03B2\u03B2\u03B2",
|
|
1373
|
+
"\u03B2\u03C1\u03B2\u03B2\u03B2\u03B2\u03B2",
|
|
1374
|
+
"\u03B2\u03B2\u03C1\u03B2\u03B2\u03B2\u03B2",
|
|
1375
|
+
"\u03B2\u03B2\u03B2\u03C1\u03B2\u03B2\u03B2",
|
|
1376
|
+
"\u03B2\u03B2\u03B2\u03B2\u03C1\u03B2\u03B2",
|
|
1377
|
+
"\u03B2\u03B2\u03B2\u03B2\u03B2\u03C1\u03B2",
|
|
1378
|
+
"\u03B2\u03B2\u03B2\u03B2\u03B2\u03B2\u03C1"
|
|
1379
|
+
]
|
|
1380
|
+
},
|
|
1381
|
+
fingerDance: {
|
|
1382
|
+
interval: 160,
|
|
1383
|
+
frames: [
|
|
1384
|
+
"\u{1F918} ",
|
|
1385
|
+
"\u{1F91F} ",
|
|
1386
|
+
"\u{1F596} ",
|
|
1387
|
+
"\u270B ",
|
|
1388
|
+
"\u{1F91A} ",
|
|
1389
|
+
"\u{1F446} "
|
|
1390
|
+
]
|
|
1391
|
+
},
|
|
1392
|
+
fistBump: {
|
|
1393
|
+
interval: 80,
|
|
1394
|
+
frames: [
|
|
1395
|
+
"\u{1F91C}\u3000\u3000\u3000\u3000\u{1F91B} ",
|
|
1396
|
+
"\u{1F91C}\u3000\u3000\u3000\u3000\u{1F91B} ",
|
|
1397
|
+
"\u{1F91C}\u3000\u3000\u3000\u3000\u{1F91B} ",
|
|
1398
|
+
"\u3000\u{1F91C}\u3000\u3000\u{1F91B}\u3000 ",
|
|
1399
|
+
"\u3000\u3000\u{1F91C}\u{1F91B}\u3000\u3000 ",
|
|
1400
|
+
"\u3000\u{1F91C}\u2728\u{1F91B}\u3000\u3000 ",
|
|
1401
|
+
"\u{1F91C}\u3000\u2728\u3000\u{1F91B}\u3000 "
|
|
1402
|
+
]
|
|
1403
|
+
},
|
|
1404
|
+
soccerHeader: {
|
|
1405
|
+
interval: 80,
|
|
1406
|
+
frames: [
|
|
1407
|
+
" \u{1F9D1}\u26BD\uFE0F \u{1F9D1} ",
|
|
1408
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1409
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1410
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1411
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1412
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1413
|
+
"\u{1F9D1} \u26BD\uFE0F\u{1F9D1} ",
|
|
1414
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1415
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1416
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1417
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} ",
|
|
1418
|
+
"\u{1F9D1} \u26BD\uFE0F \u{1F9D1} "
|
|
1419
|
+
]
|
|
1420
|
+
},
|
|
1421
|
+
mindblown: {
|
|
1422
|
+
interval: 160,
|
|
1423
|
+
frames: [
|
|
1424
|
+
"\u{1F610} ",
|
|
1425
|
+
"\u{1F610} ",
|
|
1426
|
+
"\u{1F62E} ",
|
|
1427
|
+
"\u{1F62E} ",
|
|
1428
|
+
"\u{1F626} ",
|
|
1429
|
+
"\u{1F626} ",
|
|
1430
|
+
"\u{1F627} ",
|
|
1431
|
+
"\u{1F627} ",
|
|
1432
|
+
"\u{1F92F} ",
|
|
1433
|
+
"\u{1F4A5} ",
|
|
1434
|
+
"\u2728 ",
|
|
1435
|
+
"\u3000 ",
|
|
1436
|
+
"\u3000 ",
|
|
1437
|
+
"\u3000 "
|
|
1438
|
+
]
|
|
1439
|
+
},
|
|
1440
|
+
speaker: {
|
|
1441
|
+
interval: 160,
|
|
1442
|
+
frames: [
|
|
1443
|
+
"\u{1F508} ",
|
|
1444
|
+
"\u{1F509} ",
|
|
1445
|
+
"\u{1F50A} ",
|
|
1446
|
+
"\u{1F509} "
|
|
1447
|
+
]
|
|
1448
|
+
},
|
|
1449
|
+
orangePulse: {
|
|
1450
|
+
interval: 100,
|
|
1451
|
+
frames: [
|
|
1452
|
+
"\u{1F538} ",
|
|
1453
|
+
"\u{1F536} ",
|
|
1454
|
+
"\u{1F7E0} ",
|
|
1455
|
+
"\u{1F7E0} ",
|
|
1456
|
+
"\u{1F536} "
|
|
1457
|
+
]
|
|
1458
|
+
},
|
|
1459
|
+
bluePulse: {
|
|
1460
|
+
interval: 100,
|
|
1461
|
+
frames: [
|
|
1462
|
+
"\u{1F539} ",
|
|
1463
|
+
"\u{1F537} ",
|
|
1464
|
+
"\u{1F535} ",
|
|
1465
|
+
"\u{1F535} ",
|
|
1466
|
+
"\u{1F537} "
|
|
1467
|
+
]
|
|
1468
|
+
},
|
|
1469
|
+
orangeBluePulse: {
|
|
1470
|
+
interval: 100,
|
|
1471
|
+
frames: [
|
|
1472
|
+
"\u{1F538} ",
|
|
1473
|
+
"\u{1F536} ",
|
|
1474
|
+
"\u{1F7E0} ",
|
|
1475
|
+
"\u{1F7E0} ",
|
|
1476
|
+
"\u{1F536} ",
|
|
1477
|
+
"\u{1F539} ",
|
|
1478
|
+
"\u{1F537} ",
|
|
1479
|
+
"\u{1F535} ",
|
|
1480
|
+
"\u{1F535} ",
|
|
1481
|
+
"\u{1F537} "
|
|
1482
|
+
]
|
|
1483
|
+
},
|
|
1484
|
+
timeTravel: {
|
|
1485
|
+
interval: 100,
|
|
1486
|
+
frames: [
|
|
1487
|
+
"\u{1F55B} ",
|
|
1488
|
+
"\u{1F55A} ",
|
|
1489
|
+
"\u{1F559} ",
|
|
1490
|
+
"\u{1F558} ",
|
|
1491
|
+
"\u{1F557} ",
|
|
1492
|
+
"\u{1F556} ",
|
|
1493
|
+
"\u{1F555} ",
|
|
1494
|
+
"\u{1F554} ",
|
|
1495
|
+
"\u{1F553} ",
|
|
1496
|
+
"\u{1F552} ",
|
|
1497
|
+
"\u{1F551} ",
|
|
1498
|
+
"\u{1F550} "
|
|
1499
|
+
]
|
|
1500
|
+
},
|
|
1501
|
+
aesthetic: {
|
|
1502
|
+
interval: 80,
|
|
1503
|
+
frames: [
|
|
1504
|
+
"\u25B0\u25B1\u25B1\u25B1\u25B1\u25B1\u25B1",
|
|
1505
|
+
"\u25B0\u25B0\u25B1\u25B1\u25B1\u25B1\u25B1",
|
|
1506
|
+
"\u25B0\u25B0\u25B0\u25B1\u25B1\u25B1\u25B1",
|
|
1507
|
+
"\u25B0\u25B0\u25B0\u25B0\u25B1\u25B1\u25B1",
|
|
1508
|
+
"\u25B0\u25B0\u25B0\u25B0\u25B0\u25B1\u25B1",
|
|
1509
|
+
"\u25B0\u25B0\u25B0\u25B0\u25B0\u25B0\u25B1",
|
|
1510
|
+
"\u25B0\u25B0\u25B0\u25B0\u25B0\u25B0\u25B0",
|
|
1511
|
+
"\u25B0\u25B1\u25B1\u25B1\u25B1\u25B1\u25B1"
|
|
1512
|
+
]
|
|
1513
|
+
},
|
|
1514
|
+
dwarfFortress: {
|
|
1515
|
+
interval: 80,
|
|
1516
|
+
frames: [
|
|
1517
|
+
" \u2588\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1518
|
+
"\u263A\u2588\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1519
|
+
"\u263A\u2588\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1520
|
+
"\u263A\u2593\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1521
|
+
"\u263A\u2593\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1522
|
+
"\u263A\u2592\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1523
|
+
"\u263A\u2592\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1524
|
+
"\u263A\u2591\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1525
|
+
"\u263A\u2591\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1526
|
+
"\u263A \u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1527
|
+
" \u263A\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1528
|
+
" \u263A\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1529
|
+
" \u263A\u2593\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1530
|
+
" \u263A\u2593\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1531
|
+
" \u263A\u2592\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1532
|
+
" \u263A\u2592\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1533
|
+
" \u263A\u2591\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1534
|
+
" \u263A\u2591\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1535
|
+
" \u263A \u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1536
|
+
" \u263A\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1537
|
+
" \u263A\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1538
|
+
" \u263A\u2593\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1539
|
+
" \u263A\u2593\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1540
|
+
" \u263A\u2592\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1541
|
+
" \u263A\u2592\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1542
|
+
" \u263A\u2591\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1543
|
+
" \u263A\u2591\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1544
|
+
" \u263A \u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1545
|
+
" \u263A\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1546
|
+
" \u263A\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1547
|
+
" \u263A\u2593\u2588\u2588\xA3\xA3\xA3 ",
|
|
1548
|
+
" \u263A\u2593\u2588\u2588\xA3\xA3\xA3 ",
|
|
1549
|
+
" \u263A\u2592\u2588\u2588\xA3\xA3\xA3 ",
|
|
1550
|
+
" \u263A\u2592\u2588\u2588\xA3\xA3\xA3 ",
|
|
1551
|
+
" \u263A\u2591\u2588\u2588\xA3\xA3\xA3 ",
|
|
1552
|
+
" \u263A\u2591\u2588\u2588\xA3\xA3\xA3 ",
|
|
1553
|
+
" \u263A \u2588\u2588\xA3\xA3\xA3 ",
|
|
1554
|
+
" \u263A\u2588\u2588\xA3\xA3\xA3 ",
|
|
1555
|
+
" \u263A\u2588\u2588\xA3\xA3\xA3 ",
|
|
1556
|
+
" \u263A\u2593\u2588\xA3\xA3\xA3 ",
|
|
1557
|
+
" \u263A\u2593\u2588\xA3\xA3\xA3 ",
|
|
1558
|
+
" \u263A\u2592\u2588\xA3\xA3\xA3 ",
|
|
1559
|
+
" \u263A\u2592\u2588\xA3\xA3\xA3 ",
|
|
1560
|
+
" \u263A\u2591\u2588\xA3\xA3\xA3 ",
|
|
1561
|
+
" \u263A\u2591\u2588\xA3\xA3\xA3 ",
|
|
1562
|
+
" \u263A \u2588\xA3\xA3\xA3 ",
|
|
1563
|
+
" \u263A\u2588\xA3\xA3\xA3 ",
|
|
1564
|
+
" \u263A\u2588\xA3\xA3\xA3 ",
|
|
1565
|
+
" \u263A\u2593\xA3\xA3\xA3 ",
|
|
1566
|
+
" \u263A\u2593\xA3\xA3\xA3 ",
|
|
1567
|
+
" \u263A\u2592\xA3\xA3\xA3 ",
|
|
1568
|
+
" \u263A\u2592\xA3\xA3\xA3 ",
|
|
1569
|
+
" \u263A\u2591\xA3\xA3\xA3 ",
|
|
1570
|
+
" \u263A\u2591\xA3\xA3\xA3 ",
|
|
1571
|
+
" \u263A \xA3\xA3\xA3 ",
|
|
1572
|
+
" \u263A\xA3\xA3\xA3 ",
|
|
1573
|
+
" \u263A\xA3\xA3\xA3 ",
|
|
1574
|
+
" \u263A\u2593\xA3\xA3 ",
|
|
1575
|
+
" \u263A\u2593\xA3\xA3 ",
|
|
1576
|
+
" \u263A\u2592\xA3\xA3 ",
|
|
1577
|
+
" \u263A\u2592\xA3\xA3 ",
|
|
1578
|
+
" \u263A\u2591\xA3\xA3 ",
|
|
1579
|
+
" \u263A\u2591\xA3\xA3 ",
|
|
1580
|
+
" \u263A \xA3\xA3 ",
|
|
1581
|
+
" \u263A\xA3\xA3 ",
|
|
1582
|
+
" \u263A\xA3\xA3 ",
|
|
1583
|
+
" \u263A\u2593\xA3 ",
|
|
1584
|
+
" \u263A\u2593\xA3 ",
|
|
1585
|
+
" \u263A\u2592\xA3 ",
|
|
1586
|
+
" \u263A\u2592\xA3 ",
|
|
1587
|
+
" \u263A\u2591\xA3 ",
|
|
1588
|
+
" \u263A\u2591\xA3 ",
|
|
1589
|
+
" \u263A \xA3 ",
|
|
1590
|
+
" \u263A\xA3 ",
|
|
1591
|
+
" \u263A\xA3 ",
|
|
1592
|
+
" \u263A\u2593 ",
|
|
1593
|
+
" \u263A\u2593 ",
|
|
1594
|
+
" \u263A\u2592 ",
|
|
1595
|
+
" \u263A\u2592 ",
|
|
1596
|
+
" \u263A\u2591 ",
|
|
1597
|
+
" \u263A\u2591 ",
|
|
1598
|
+
" \u263A ",
|
|
1599
|
+
" \u263A &",
|
|
1600
|
+
" \u263A \u263C&",
|
|
1601
|
+
" \u263A \u263C &",
|
|
1602
|
+
" \u263A\u263C &",
|
|
1603
|
+
" \u263A\u263C & ",
|
|
1604
|
+
" \u203C & ",
|
|
1605
|
+
" \u263A & ",
|
|
1606
|
+
" \u203C & ",
|
|
1607
|
+
" \u263A & ",
|
|
1608
|
+
" \u203C & ",
|
|
1609
|
+
" \u263A & ",
|
|
1610
|
+
"\u203C & ",
|
|
1611
|
+
" & ",
|
|
1612
|
+
" & ",
|
|
1613
|
+
" & \u2591 ",
|
|
1614
|
+
" & \u2592 ",
|
|
1615
|
+
" & \u2593 ",
|
|
1616
|
+
" & \xA3 ",
|
|
1617
|
+
" & \u2591\xA3 ",
|
|
1618
|
+
" & \u2592\xA3 ",
|
|
1619
|
+
" & \u2593\xA3 ",
|
|
1620
|
+
" & \xA3\xA3 ",
|
|
1621
|
+
" & \u2591\xA3\xA3 ",
|
|
1622
|
+
" & \u2592\xA3\xA3 ",
|
|
1623
|
+
"& \u2593\xA3\xA3 ",
|
|
1624
|
+
"& \xA3\xA3\xA3 ",
|
|
1625
|
+
" \u2591\xA3\xA3\xA3 ",
|
|
1626
|
+
" \u2592\xA3\xA3\xA3 ",
|
|
1627
|
+
" \u2593\xA3\xA3\xA3 ",
|
|
1628
|
+
" \u2588\xA3\xA3\xA3 ",
|
|
1629
|
+
" \u2591\u2588\xA3\xA3\xA3 ",
|
|
1630
|
+
" \u2592\u2588\xA3\xA3\xA3 ",
|
|
1631
|
+
" \u2593\u2588\xA3\xA3\xA3 ",
|
|
1632
|
+
" \u2588\u2588\xA3\xA3\xA3 ",
|
|
1633
|
+
" \u2591\u2588\u2588\xA3\xA3\xA3 ",
|
|
1634
|
+
" \u2592\u2588\u2588\xA3\xA3\xA3 ",
|
|
1635
|
+
" \u2593\u2588\u2588\xA3\xA3\xA3 ",
|
|
1636
|
+
" \u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1637
|
+
" \u2591\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1638
|
+
" \u2592\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1639
|
+
" \u2593\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1640
|
+
" \u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1641
|
+
" \u2591\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1642
|
+
" \u2592\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1643
|
+
" \u2593\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1644
|
+
" \u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1645
|
+
" \u2591\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1646
|
+
" \u2592\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1647
|
+
" \u2593\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1648
|
+
" \u2588\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 ",
|
|
1649
|
+
" \u2588\u2588\u2588\u2588\u2588\u2588\xA3\xA3\xA3 "
|
|
1650
|
+
]
|
|
1651
|
+
}
|
|
1652
|
+
};
|
|
1653
|
+
}
|
|
1654
|
+
});
|
|
1655
|
+
|
|
1656
|
+
// ../../node_modules/.pnpm/cli-spinners@2.9.2/node_modules/cli-spinners/index.js
|
|
1657
|
+
var require_cli_spinners = __commonJS({
|
|
1658
|
+
"../../node_modules/.pnpm/cli-spinners@2.9.2/node_modules/cli-spinners/index.js"(exports, module) {
|
|
1659
|
+
"use strict";
|
|
1660
|
+
var spinners = Object.assign({}, require_spinners());
|
|
1661
|
+
var spinnersList = Object.keys(spinners);
|
|
1662
|
+
Object.defineProperty(spinners, "random", {
|
|
1663
|
+
get() {
|
|
1664
|
+
const randomIndex = Math.floor(Math.random() * spinnersList.length);
|
|
1665
|
+
const spinnerName = spinnersList[randomIndex];
|
|
1666
|
+
return spinners[spinnerName];
|
|
1667
|
+
}
|
|
1668
|
+
});
|
|
1669
|
+
module.exports = spinners;
|
|
1670
|
+
}
|
|
1671
|
+
});
|
|
2
1672
|
|
|
3
1673
|
// src/index.ts
|
|
4
1674
|
import { Command as Command7 } from "commander";
|
|
5
|
-
|
|
6
|
-
|
|
1675
|
+
|
|
1676
|
+
// src/core/runtime-paths.ts
|
|
1677
|
+
import { existsSync, readFileSync, realpathSync } from "fs";
|
|
1678
|
+
import path from "path";
|
|
1679
|
+
import { fileURLToPath } from "url";
|
|
1680
|
+
var CLI_PACKAGE_NAMES = /* @__PURE__ */ new Set(["@better-webhook/cli", "better-webhook"]);
|
|
1681
|
+
function resolveRealPath(filePath) {
|
|
1682
|
+
try {
|
|
1683
|
+
return realpathSync(filePath);
|
|
1684
|
+
} catch {
|
|
1685
|
+
return filePath;
|
|
1686
|
+
}
|
|
1687
|
+
}
|
|
1688
|
+
function readPackageName(packageJsonPath) {
|
|
1689
|
+
if (!existsSync(packageJsonPath)) {
|
|
1690
|
+
return void 0;
|
|
1691
|
+
}
|
|
1692
|
+
try {
|
|
1693
|
+
const packageJson = JSON.parse(
|
|
1694
|
+
readFileSync(packageJsonPath, { encoding: "utf8" })
|
|
1695
|
+
);
|
|
1696
|
+
return typeof packageJson.name === "string" ? packageJson.name : void 0;
|
|
1697
|
+
} catch {
|
|
1698
|
+
return void 0;
|
|
1699
|
+
}
|
|
1700
|
+
}
|
|
1701
|
+
function isCliPackageName(packageName) {
|
|
1702
|
+
return typeof packageName === "string" && CLI_PACKAGE_NAMES.has(packageName);
|
|
1703
|
+
}
|
|
1704
|
+
function findCliPackageRoot(startDir) {
|
|
1705
|
+
let currentDir = resolveRealPath(path.resolve(startDir));
|
|
1706
|
+
while (true) {
|
|
1707
|
+
const packageJsonPath = path.join(currentDir, "package.json");
|
|
1708
|
+
const packageName = readPackageName(packageJsonPath);
|
|
1709
|
+
if (isCliPackageName(packageName)) {
|
|
1710
|
+
return currentDir;
|
|
1711
|
+
}
|
|
1712
|
+
const parentDir = path.dirname(currentDir);
|
|
1713
|
+
if (parentDir === currentDir) {
|
|
1714
|
+
return void 0;
|
|
1715
|
+
}
|
|
1716
|
+
currentDir = parentDir;
|
|
1717
|
+
}
|
|
1718
|
+
}
|
|
1719
|
+
function resolveRuntimeDir() {
|
|
1720
|
+
if (typeof __dirname !== "undefined") {
|
|
1721
|
+
return resolveRealPath(__dirname);
|
|
1722
|
+
}
|
|
1723
|
+
const moduleUrl = import.meta.url;
|
|
1724
|
+
if (typeof moduleUrl === "string" && moduleUrl.startsWith("file:")) {
|
|
1725
|
+
return path.dirname(resolveRealPath(fileURLToPath(moduleUrl)));
|
|
1726
|
+
}
|
|
1727
|
+
const entryPath = process.argv[1];
|
|
1728
|
+
if (entryPath) {
|
|
1729
|
+
const entryDir = path.dirname(resolveRealPath(path.resolve(entryPath)));
|
|
1730
|
+
const cliPackageRoot = findCliPackageRoot(entryDir);
|
|
1731
|
+
if (cliPackageRoot) {
|
|
1732
|
+
return cliPackageRoot;
|
|
1733
|
+
}
|
|
1734
|
+
return entryDir;
|
|
1735
|
+
}
|
|
1736
|
+
const cwdPackageRoot = findCliPackageRoot(process.cwd());
|
|
1737
|
+
if (cwdPackageRoot) {
|
|
1738
|
+
return cwdPackageRoot;
|
|
1739
|
+
}
|
|
1740
|
+
return process.cwd();
|
|
1741
|
+
}
|
|
1742
|
+
|
|
1743
|
+
// src/core/cli-version.ts
|
|
1744
|
+
import { readFileSync as readFileSync2 } from "fs";
|
|
1745
|
+
import path2 from "path";
|
|
1746
|
+
function readPackageVersion(packageJsonPath) {
|
|
1747
|
+
try {
|
|
1748
|
+
const packageJson = JSON.parse(
|
|
1749
|
+
readFileSync2(packageJsonPath, { encoding: "utf8" })
|
|
1750
|
+
);
|
|
1751
|
+
return typeof packageJson.version === "string" && packageJson.version ? packageJson.version : void 0;
|
|
1752
|
+
} catch {
|
|
1753
|
+
return void 0;
|
|
1754
|
+
}
|
|
1755
|
+
}
|
|
1756
|
+
function resolveRuntimePackageVersion(runtimeDir) {
|
|
1757
|
+
const searchDirs = [runtimeDir, path2.resolve(runtimeDir, "..")];
|
|
1758
|
+
const visitedRoots = /* @__PURE__ */ new Set();
|
|
1759
|
+
for (const searchDir of searchDirs) {
|
|
1760
|
+
const cliPackageRoot = findCliPackageRoot(searchDir);
|
|
1761
|
+
if (!cliPackageRoot || visitedRoots.has(cliPackageRoot)) {
|
|
1762
|
+
continue;
|
|
1763
|
+
}
|
|
1764
|
+
visitedRoots.add(cliPackageRoot);
|
|
1765
|
+
const version = readPackageVersion(path2.join(cliPackageRoot, "package.json"));
|
|
1766
|
+
if (version) {
|
|
1767
|
+
return version;
|
|
1768
|
+
}
|
|
1769
|
+
}
|
|
1770
|
+
return void 0;
|
|
1771
|
+
}
|
|
7
1772
|
|
|
8
1773
|
// src/commands/templates.ts
|
|
9
1774
|
import { Command } from "commander";
|
|
10
|
-
|
|
1775
|
+
|
|
1776
|
+
// ../../node_modules/.pnpm/ora@8.2.0/node_modules/ora/index.js
|
|
1777
|
+
import process9 from "process";
|
|
1778
|
+
|
|
1779
|
+
// ../../node_modules/.pnpm/chalk@5.6.2/node_modules/chalk/source/vendor/ansi-styles/index.js
|
|
1780
|
+
var ANSI_BACKGROUND_OFFSET = 10;
|
|
1781
|
+
var wrapAnsi16 = (offset = 0) => (code) => `\x1B[${code + offset}m`;
|
|
1782
|
+
var wrapAnsi256 = (offset = 0) => (code) => `\x1B[${38 + offset};5;${code}m`;
|
|
1783
|
+
var wrapAnsi16m = (offset = 0) => (red, green, blue) => `\x1B[${38 + offset};2;${red};${green};${blue}m`;
|
|
1784
|
+
var styles = {
|
|
1785
|
+
modifier: {
|
|
1786
|
+
reset: [0, 0],
|
|
1787
|
+
// 21 isn't widely supported and 22 does the same thing
|
|
1788
|
+
bold: [1, 22],
|
|
1789
|
+
dim: [2, 22],
|
|
1790
|
+
italic: [3, 23],
|
|
1791
|
+
underline: [4, 24],
|
|
1792
|
+
overline: [53, 55],
|
|
1793
|
+
inverse: [7, 27],
|
|
1794
|
+
hidden: [8, 28],
|
|
1795
|
+
strikethrough: [9, 29]
|
|
1796
|
+
},
|
|
1797
|
+
color: {
|
|
1798
|
+
black: [30, 39],
|
|
1799
|
+
red: [31, 39],
|
|
1800
|
+
green: [32, 39],
|
|
1801
|
+
yellow: [33, 39],
|
|
1802
|
+
blue: [34, 39],
|
|
1803
|
+
magenta: [35, 39],
|
|
1804
|
+
cyan: [36, 39],
|
|
1805
|
+
white: [37, 39],
|
|
1806
|
+
// Bright color
|
|
1807
|
+
blackBright: [90, 39],
|
|
1808
|
+
gray: [90, 39],
|
|
1809
|
+
// Alias of `blackBright`
|
|
1810
|
+
grey: [90, 39],
|
|
1811
|
+
// Alias of `blackBright`
|
|
1812
|
+
redBright: [91, 39],
|
|
1813
|
+
greenBright: [92, 39],
|
|
1814
|
+
yellowBright: [93, 39],
|
|
1815
|
+
blueBright: [94, 39],
|
|
1816
|
+
magentaBright: [95, 39],
|
|
1817
|
+
cyanBright: [96, 39],
|
|
1818
|
+
whiteBright: [97, 39]
|
|
1819
|
+
},
|
|
1820
|
+
bgColor: {
|
|
1821
|
+
bgBlack: [40, 49],
|
|
1822
|
+
bgRed: [41, 49],
|
|
1823
|
+
bgGreen: [42, 49],
|
|
1824
|
+
bgYellow: [43, 49],
|
|
1825
|
+
bgBlue: [44, 49],
|
|
1826
|
+
bgMagenta: [45, 49],
|
|
1827
|
+
bgCyan: [46, 49],
|
|
1828
|
+
bgWhite: [47, 49],
|
|
1829
|
+
// Bright color
|
|
1830
|
+
bgBlackBright: [100, 49],
|
|
1831
|
+
bgGray: [100, 49],
|
|
1832
|
+
// Alias of `bgBlackBright`
|
|
1833
|
+
bgGrey: [100, 49],
|
|
1834
|
+
// Alias of `bgBlackBright`
|
|
1835
|
+
bgRedBright: [101, 49],
|
|
1836
|
+
bgGreenBright: [102, 49],
|
|
1837
|
+
bgYellowBright: [103, 49],
|
|
1838
|
+
bgBlueBright: [104, 49],
|
|
1839
|
+
bgMagentaBright: [105, 49],
|
|
1840
|
+
bgCyanBright: [106, 49],
|
|
1841
|
+
bgWhiteBright: [107, 49]
|
|
1842
|
+
}
|
|
1843
|
+
};
|
|
1844
|
+
var modifierNames = Object.keys(styles.modifier);
|
|
1845
|
+
var foregroundColorNames = Object.keys(styles.color);
|
|
1846
|
+
var backgroundColorNames = Object.keys(styles.bgColor);
|
|
1847
|
+
var colorNames = [...foregroundColorNames, ...backgroundColorNames];
|
|
1848
|
+
function assembleStyles() {
|
|
1849
|
+
const codes = /* @__PURE__ */ new Map();
|
|
1850
|
+
for (const [groupName, group] of Object.entries(styles)) {
|
|
1851
|
+
for (const [styleName, style] of Object.entries(group)) {
|
|
1852
|
+
styles[styleName] = {
|
|
1853
|
+
open: `\x1B[${style[0]}m`,
|
|
1854
|
+
close: `\x1B[${style[1]}m`
|
|
1855
|
+
};
|
|
1856
|
+
group[styleName] = styles[styleName];
|
|
1857
|
+
codes.set(style[0], style[1]);
|
|
1858
|
+
}
|
|
1859
|
+
Object.defineProperty(styles, groupName, {
|
|
1860
|
+
value: group,
|
|
1861
|
+
enumerable: false
|
|
1862
|
+
});
|
|
1863
|
+
}
|
|
1864
|
+
Object.defineProperty(styles, "codes", {
|
|
1865
|
+
value: codes,
|
|
1866
|
+
enumerable: false
|
|
1867
|
+
});
|
|
1868
|
+
styles.color.close = "\x1B[39m";
|
|
1869
|
+
styles.bgColor.close = "\x1B[49m";
|
|
1870
|
+
styles.color.ansi = wrapAnsi16();
|
|
1871
|
+
styles.color.ansi256 = wrapAnsi256();
|
|
1872
|
+
styles.color.ansi16m = wrapAnsi16m();
|
|
1873
|
+
styles.bgColor.ansi = wrapAnsi16(ANSI_BACKGROUND_OFFSET);
|
|
1874
|
+
styles.bgColor.ansi256 = wrapAnsi256(ANSI_BACKGROUND_OFFSET);
|
|
1875
|
+
styles.bgColor.ansi16m = wrapAnsi16m(ANSI_BACKGROUND_OFFSET);
|
|
1876
|
+
Object.defineProperties(styles, {
|
|
1877
|
+
rgbToAnsi256: {
|
|
1878
|
+
value(red, green, blue) {
|
|
1879
|
+
if (red === green && green === blue) {
|
|
1880
|
+
if (red < 8) {
|
|
1881
|
+
return 16;
|
|
1882
|
+
}
|
|
1883
|
+
if (red > 248) {
|
|
1884
|
+
return 231;
|
|
1885
|
+
}
|
|
1886
|
+
return Math.round((red - 8) / 247 * 24) + 232;
|
|
1887
|
+
}
|
|
1888
|
+
return 16 + 36 * Math.round(red / 255 * 5) + 6 * Math.round(green / 255 * 5) + Math.round(blue / 255 * 5);
|
|
1889
|
+
},
|
|
1890
|
+
enumerable: false
|
|
1891
|
+
},
|
|
1892
|
+
hexToRgb: {
|
|
1893
|
+
value(hex) {
|
|
1894
|
+
const matches = /[a-f\d]{6}|[a-f\d]{3}/i.exec(hex.toString(16));
|
|
1895
|
+
if (!matches) {
|
|
1896
|
+
return [0, 0, 0];
|
|
1897
|
+
}
|
|
1898
|
+
let [colorString] = matches;
|
|
1899
|
+
if (colorString.length === 3) {
|
|
1900
|
+
colorString = [...colorString].map((character) => character + character).join("");
|
|
1901
|
+
}
|
|
1902
|
+
const integer = Number.parseInt(colorString, 16);
|
|
1903
|
+
return [
|
|
1904
|
+
/* eslint-disable no-bitwise */
|
|
1905
|
+
integer >> 16 & 255,
|
|
1906
|
+
integer >> 8 & 255,
|
|
1907
|
+
integer & 255
|
|
1908
|
+
/* eslint-enable no-bitwise */
|
|
1909
|
+
];
|
|
1910
|
+
},
|
|
1911
|
+
enumerable: false
|
|
1912
|
+
},
|
|
1913
|
+
hexToAnsi256: {
|
|
1914
|
+
value: (hex) => styles.rgbToAnsi256(...styles.hexToRgb(hex)),
|
|
1915
|
+
enumerable: false
|
|
1916
|
+
},
|
|
1917
|
+
ansi256ToAnsi: {
|
|
1918
|
+
value(code) {
|
|
1919
|
+
if (code < 8) {
|
|
1920
|
+
return 30 + code;
|
|
1921
|
+
}
|
|
1922
|
+
if (code < 16) {
|
|
1923
|
+
return 90 + (code - 8);
|
|
1924
|
+
}
|
|
1925
|
+
let red;
|
|
1926
|
+
let green;
|
|
1927
|
+
let blue;
|
|
1928
|
+
if (code >= 232) {
|
|
1929
|
+
red = ((code - 232) * 10 + 8) / 255;
|
|
1930
|
+
green = red;
|
|
1931
|
+
blue = red;
|
|
1932
|
+
} else {
|
|
1933
|
+
code -= 16;
|
|
1934
|
+
const remainder = code % 36;
|
|
1935
|
+
red = Math.floor(code / 36) / 5;
|
|
1936
|
+
green = Math.floor(remainder / 6) / 5;
|
|
1937
|
+
blue = remainder % 6 / 5;
|
|
1938
|
+
}
|
|
1939
|
+
const value = Math.max(red, green, blue) * 2;
|
|
1940
|
+
if (value === 0) {
|
|
1941
|
+
return 30;
|
|
1942
|
+
}
|
|
1943
|
+
let result = 30 + (Math.round(blue) << 2 | Math.round(green) << 1 | Math.round(red));
|
|
1944
|
+
if (value === 2) {
|
|
1945
|
+
result += 60;
|
|
1946
|
+
}
|
|
1947
|
+
return result;
|
|
1948
|
+
},
|
|
1949
|
+
enumerable: false
|
|
1950
|
+
},
|
|
1951
|
+
rgbToAnsi: {
|
|
1952
|
+
value: (red, green, blue) => styles.ansi256ToAnsi(styles.rgbToAnsi256(red, green, blue)),
|
|
1953
|
+
enumerable: false
|
|
1954
|
+
},
|
|
1955
|
+
hexToAnsi: {
|
|
1956
|
+
value: (hex) => styles.ansi256ToAnsi(styles.hexToAnsi256(hex)),
|
|
1957
|
+
enumerable: false
|
|
1958
|
+
}
|
|
1959
|
+
});
|
|
1960
|
+
return styles;
|
|
1961
|
+
}
|
|
1962
|
+
var ansiStyles = assembleStyles();
|
|
1963
|
+
var ansi_styles_default = ansiStyles;
|
|
1964
|
+
|
|
1965
|
+
// ../../node_modules/.pnpm/chalk@5.6.2/node_modules/chalk/source/vendor/supports-color/index.js
|
|
1966
|
+
import process2 from "process";
|
|
1967
|
+
import os from "os";
|
|
1968
|
+
import tty from "tty";
|
|
1969
|
+
function hasFlag(flag, argv = globalThis.Deno ? globalThis.Deno.args : process2.argv) {
|
|
1970
|
+
const prefix = flag.startsWith("-") ? "" : flag.length === 1 ? "-" : "--";
|
|
1971
|
+
const position = argv.indexOf(prefix + flag);
|
|
1972
|
+
const terminatorPosition = argv.indexOf("--");
|
|
1973
|
+
return position !== -1 && (terminatorPosition === -1 || position < terminatorPosition);
|
|
1974
|
+
}
|
|
1975
|
+
var { env } = process2;
|
|
1976
|
+
var flagForceColor;
|
|
1977
|
+
if (hasFlag("no-color") || hasFlag("no-colors") || hasFlag("color=false") || hasFlag("color=never")) {
|
|
1978
|
+
flagForceColor = 0;
|
|
1979
|
+
} else if (hasFlag("color") || hasFlag("colors") || hasFlag("color=true") || hasFlag("color=always")) {
|
|
1980
|
+
flagForceColor = 1;
|
|
1981
|
+
}
|
|
1982
|
+
function envForceColor() {
|
|
1983
|
+
if ("FORCE_COLOR" in env) {
|
|
1984
|
+
if (env.FORCE_COLOR === "true") {
|
|
1985
|
+
return 1;
|
|
1986
|
+
}
|
|
1987
|
+
if (env.FORCE_COLOR === "false") {
|
|
1988
|
+
return 0;
|
|
1989
|
+
}
|
|
1990
|
+
return env.FORCE_COLOR.length === 0 ? 1 : Math.min(Number.parseInt(env.FORCE_COLOR, 10), 3);
|
|
1991
|
+
}
|
|
1992
|
+
}
|
|
1993
|
+
function translateLevel(level) {
|
|
1994
|
+
if (level === 0) {
|
|
1995
|
+
return false;
|
|
1996
|
+
}
|
|
1997
|
+
return {
|
|
1998
|
+
level,
|
|
1999
|
+
hasBasic: true,
|
|
2000
|
+
has256: level >= 2,
|
|
2001
|
+
has16m: level >= 3
|
|
2002
|
+
};
|
|
2003
|
+
}
|
|
2004
|
+
function _supportsColor(haveStream, { streamIsTTY, sniffFlags = true } = {}) {
|
|
2005
|
+
const noFlagForceColor = envForceColor();
|
|
2006
|
+
if (noFlagForceColor !== void 0) {
|
|
2007
|
+
flagForceColor = noFlagForceColor;
|
|
2008
|
+
}
|
|
2009
|
+
const forceColor = sniffFlags ? flagForceColor : noFlagForceColor;
|
|
2010
|
+
if (forceColor === 0) {
|
|
2011
|
+
return 0;
|
|
2012
|
+
}
|
|
2013
|
+
if (sniffFlags) {
|
|
2014
|
+
if (hasFlag("color=16m") || hasFlag("color=full") || hasFlag("color=truecolor")) {
|
|
2015
|
+
return 3;
|
|
2016
|
+
}
|
|
2017
|
+
if (hasFlag("color=256")) {
|
|
2018
|
+
return 2;
|
|
2019
|
+
}
|
|
2020
|
+
}
|
|
2021
|
+
if ("TF_BUILD" in env && "AGENT_NAME" in env) {
|
|
2022
|
+
return 1;
|
|
2023
|
+
}
|
|
2024
|
+
if (haveStream && !streamIsTTY && forceColor === void 0) {
|
|
2025
|
+
return 0;
|
|
2026
|
+
}
|
|
2027
|
+
const min = forceColor || 0;
|
|
2028
|
+
if (env.TERM === "dumb") {
|
|
2029
|
+
return min;
|
|
2030
|
+
}
|
|
2031
|
+
if (process2.platform === "win32") {
|
|
2032
|
+
const osRelease = os.release().split(".");
|
|
2033
|
+
if (Number(osRelease[0]) >= 10 && Number(osRelease[2]) >= 10586) {
|
|
2034
|
+
return Number(osRelease[2]) >= 14931 ? 3 : 2;
|
|
2035
|
+
}
|
|
2036
|
+
return 1;
|
|
2037
|
+
}
|
|
2038
|
+
if ("CI" in env) {
|
|
2039
|
+
if (["GITHUB_ACTIONS", "GITEA_ACTIONS", "CIRCLECI"].some((key) => key in env)) {
|
|
2040
|
+
return 3;
|
|
2041
|
+
}
|
|
2042
|
+
if (["TRAVIS", "APPVEYOR", "GITLAB_CI", "BUILDKITE", "DRONE"].some((sign) => sign in env) || env.CI_NAME === "codeship") {
|
|
2043
|
+
return 1;
|
|
2044
|
+
}
|
|
2045
|
+
return min;
|
|
2046
|
+
}
|
|
2047
|
+
if ("TEAMCITY_VERSION" in env) {
|
|
2048
|
+
return /^(9\.(0*[1-9]\d*)\.|\d{2,}\.)/.test(env.TEAMCITY_VERSION) ? 1 : 0;
|
|
2049
|
+
}
|
|
2050
|
+
if (env.COLORTERM === "truecolor") {
|
|
2051
|
+
return 3;
|
|
2052
|
+
}
|
|
2053
|
+
if (env.TERM === "xterm-kitty") {
|
|
2054
|
+
return 3;
|
|
2055
|
+
}
|
|
2056
|
+
if (env.TERM === "xterm-ghostty") {
|
|
2057
|
+
return 3;
|
|
2058
|
+
}
|
|
2059
|
+
if (env.TERM === "wezterm") {
|
|
2060
|
+
return 3;
|
|
2061
|
+
}
|
|
2062
|
+
if ("TERM_PROGRAM" in env) {
|
|
2063
|
+
const version = Number.parseInt((env.TERM_PROGRAM_VERSION || "").split(".")[0], 10);
|
|
2064
|
+
switch (env.TERM_PROGRAM) {
|
|
2065
|
+
case "iTerm.app": {
|
|
2066
|
+
return version >= 3 ? 3 : 2;
|
|
2067
|
+
}
|
|
2068
|
+
case "Apple_Terminal": {
|
|
2069
|
+
return 2;
|
|
2070
|
+
}
|
|
2071
|
+
}
|
|
2072
|
+
}
|
|
2073
|
+
if (/-256(color)?$/i.test(env.TERM)) {
|
|
2074
|
+
return 2;
|
|
2075
|
+
}
|
|
2076
|
+
if (/^screen|^xterm|^vt100|^vt220|^rxvt|color|ansi|cygwin|linux/i.test(env.TERM)) {
|
|
2077
|
+
return 1;
|
|
2078
|
+
}
|
|
2079
|
+
if ("COLORTERM" in env) {
|
|
2080
|
+
return 1;
|
|
2081
|
+
}
|
|
2082
|
+
return min;
|
|
2083
|
+
}
|
|
2084
|
+
function createSupportsColor(stream, options = {}) {
|
|
2085
|
+
const level = _supportsColor(stream, {
|
|
2086
|
+
streamIsTTY: stream && stream.isTTY,
|
|
2087
|
+
...options
|
|
2088
|
+
});
|
|
2089
|
+
return translateLevel(level);
|
|
2090
|
+
}
|
|
2091
|
+
var supportsColor = {
|
|
2092
|
+
stdout: createSupportsColor({ isTTY: tty.isatty(1) }),
|
|
2093
|
+
stderr: createSupportsColor({ isTTY: tty.isatty(2) })
|
|
2094
|
+
};
|
|
2095
|
+
var supports_color_default = supportsColor;
|
|
2096
|
+
|
|
2097
|
+
// ../../node_modules/.pnpm/chalk@5.6.2/node_modules/chalk/source/utilities.js
|
|
2098
|
+
function stringReplaceAll(string, substring, replacer) {
|
|
2099
|
+
let index = string.indexOf(substring);
|
|
2100
|
+
if (index === -1) {
|
|
2101
|
+
return string;
|
|
2102
|
+
}
|
|
2103
|
+
const substringLength = substring.length;
|
|
2104
|
+
let endIndex = 0;
|
|
2105
|
+
let returnValue = "";
|
|
2106
|
+
do {
|
|
2107
|
+
returnValue += string.slice(endIndex, index) + substring + replacer;
|
|
2108
|
+
endIndex = index + substringLength;
|
|
2109
|
+
index = string.indexOf(substring, endIndex);
|
|
2110
|
+
} while (index !== -1);
|
|
2111
|
+
returnValue += string.slice(endIndex);
|
|
2112
|
+
return returnValue;
|
|
2113
|
+
}
|
|
2114
|
+
function stringEncaseCRLFWithFirstIndex(string, prefix, postfix, index) {
|
|
2115
|
+
let endIndex = 0;
|
|
2116
|
+
let returnValue = "";
|
|
2117
|
+
do {
|
|
2118
|
+
const gotCR = string[index - 1] === "\r";
|
|
2119
|
+
returnValue += string.slice(endIndex, gotCR ? index - 1 : index) + prefix + (gotCR ? "\r\n" : "\n") + postfix;
|
|
2120
|
+
endIndex = index + 1;
|
|
2121
|
+
index = string.indexOf("\n", endIndex);
|
|
2122
|
+
} while (index !== -1);
|
|
2123
|
+
returnValue += string.slice(endIndex);
|
|
2124
|
+
return returnValue;
|
|
2125
|
+
}
|
|
2126
|
+
|
|
2127
|
+
// ../../node_modules/.pnpm/chalk@5.6.2/node_modules/chalk/source/index.js
|
|
2128
|
+
var { stdout: stdoutColor, stderr: stderrColor } = supports_color_default;
|
|
2129
|
+
var GENERATOR = Symbol("GENERATOR");
|
|
2130
|
+
var STYLER = Symbol("STYLER");
|
|
2131
|
+
var IS_EMPTY = Symbol("IS_EMPTY");
|
|
2132
|
+
var levelMapping = [
|
|
2133
|
+
"ansi",
|
|
2134
|
+
"ansi",
|
|
2135
|
+
"ansi256",
|
|
2136
|
+
"ansi16m"
|
|
2137
|
+
];
|
|
2138
|
+
var styles2 = /* @__PURE__ */ Object.create(null);
|
|
2139
|
+
var applyOptions = (object, options = {}) => {
|
|
2140
|
+
if (options.level && !(Number.isInteger(options.level) && options.level >= 0 && options.level <= 3)) {
|
|
2141
|
+
throw new Error("The `level` option should be an integer from 0 to 3");
|
|
2142
|
+
}
|
|
2143
|
+
const colorLevel = stdoutColor ? stdoutColor.level : 0;
|
|
2144
|
+
object.level = options.level === void 0 ? colorLevel : options.level;
|
|
2145
|
+
};
|
|
2146
|
+
var chalkFactory = (options) => {
|
|
2147
|
+
const chalk2 = (...strings) => strings.join(" ");
|
|
2148
|
+
applyOptions(chalk2, options);
|
|
2149
|
+
Object.setPrototypeOf(chalk2, createChalk.prototype);
|
|
2150
|
+
return chalk2;
|
|
2151
|
+
};
|
|
2152
|
+
function createChalk(options) {
|
|
2153
|
+
return chalkFactory(options);
|
|
2154
|
+
}
|
|
2155
|
+
Object.setPrototypeOf(createChalk.prototype, Function.prototype);
|
|
2156
|
+
for (const [styleName, style] of Object.entries(ansi_styles_default)) {
|
|
2157
|
+
styles2[styleName] = {
|
|
2158
|
+
get() {
|
|
2159
|
+
const builder = createBuilder(this, createStyler(style.open, style.close, this[STYLER]), this[IS_EMPTY]);
|
|
2160
|
+
Object.defineProperty(this, styleName, { value: builder });
|
|
2161
|
+
return builder;
|
|
2162
|
+
}
|
|
2163
|
+
};
|
|
2164
|
+
}
|
|
2165
|
+
styles2.visible = {
|
|
2166
|
+
get() {
|
|
2167
|
+
const builder = createBuilder(this, this[STYLER], true);
|
|
2168
|
+
Object.defineProperty(this, "visible", { value: builder });
|
|
2169
|
+
return builder;
|
|
2170
|
+
}
|
|
2171
|
+
};
|
|
2172
|
+
var getModelAnsi = (model, level, type, ...arguments_) => {
|
|
2173
|
+
if (model === "rgb") {
|
|
2174
|
+
if (level === "ansi16m") {
|
|
2175
|
+
return ansi_styles_default[type].ansi16m(...arguments_);
|
|
2176
|
+
}
|
|
2177
|
+
if (level === "ansi256") {
|
|
2178
|
+
return ansi_styles_default[type].ansi256(ansi_styles_default.rgbToAnsi256(...arguments_));
|
|
2179
|
+
}
|
|
2180
|
+
return ansi_styles_default[type].ansi(ansi_styles_default.rgbToAnsi(...arguments_));
|
|
2181
|
+
}
|
|
2182
|
+
if (model === "hex") {
|
|
2183
|
+
return getModelAnsi("rgb", level, type, ...ansi_styles_default.hexToRgb(...arguments_));
|
|
2184
|
+
}
|
|
2185
|
+
return ansi_styles_default[type][model](...arguments_);
|
|
2186
|
+
};
|
|
2187
|
+
var usedModels = ["rgb", "hex", "ansi256"];
|
|
2188
|
+
for (const model of usedModels) {
|
|
2189
|
+
styles2[model] = {
|
|
2190
|
+
get() {
|
|
2191
|
+
const { level } = this;
|
|
2192
|
+
return function(...arguments_) {
|
|
2193
|
+
const styler = createStyler(getModelAnsi(model, levelMapping[level], "color", ...arguments_), ansi_styles_default.color.close, this[STYLER]);
|
|
2194
|
+
return createBuilder(this, styler, this[IS_EMPTY]);
|
|
2195
|
+
};
|
|
2196
|
+
}
|
|
2197
|
+
};
|
|
2198
|
+
const bgModel = "bg" + model[0].toUpperCase() + model.slice(1);
|
|
2199
|
+
styles2[bgModel] = {
|
|
2200
|
+
get() {
|
|
2201
|
+
const { level } = this;
|
|
2202
|
+
return function(...arguments_) {
|
|
2203
|
+
const styler = createStyler(getModelAnsi(model, levelMapping[level], "bgColor", ...arguments_), ansi_styles_default.bgColor.close, this[STYLER]);
|
|
2204
|
+
return createBuilder(this, styler, this[IS_EMPTY]);
|
|
2205
|
+
};
|
|
2206
|
+
}
|
|
2207
|
+
};
|
|
2208
|
+
}
|
|
2209
|
+
var proto = Object.defineProperties(() => {
|
|
2210
|
+
}, {
|
|
2211
|
+
...styles2,
|
|
2212
|
+
level: {
|
|
2213
|
+
enumerable: true,
|
|
2214
|
+
get() {
|
|
2215
|
+
return this[GENERATOR].level;
|
|
2216
|
+
},
|
|
2217
|
+
set(level) {
|
|
2218
|
+
this[GENERATOR].level = level;
|
|
2219
|
+
}
|
|
2220
|
+
}
|
|
2221
|
+
});
|
|
2222
|
+
var createStyler = (open, close, parent) => {
|
|
2223
|
+
let openAll;
|
|
2224
|
+
let closeAll;
|
|
2225
|
+
if (parent === void 0) {
|
|
2226
|
+
openAll = open;
|
|
2227
|
+
closeAll = close;
|
|
2228
|
+
} else {
|
|
2229
|
+
openAll = parent.openAll + open;
|
|
2230
|
+
closeAll = close + parent.closeAll;
|
|
2231
|
+
}
|
|
2232
|
+
return {
|
|
2233
|
+
open,
|
|
2234
|
+
close,
|
|
2235
|
+
openAll,
|
|
2236
|
+
closeAll,
|
|
2237
|
+
parent
|
|
2238
|
+
};
|
|
2239
|
+
};
|
|
2240
|
+
var createBuilder = (self, _styler, _isEmpty) => {
|
|
2241
|
+
const builder = (...arguments_) => applyStyle(builder, arguments_.length === 1 ? "" + arguments_[0] : arguments_.join(" "));
|
|
2242
|
+
Object.setPrototypeOf(builder, proto);
|
|
2243
|
+
builder[GENERATOR] = self;
|
|
2244
|
+
builder[STYLER] = _styler;
|
|
2245
|
+
builder[IS_EMPTY] = _isEmpty;
|
|
2246
|
+
return builder;
|
|
2247
|
+
};
|
|
2248
|
+
var applyStyle = (self, string) => {
|
|
2249
|
+
if (self.level <= 0 || !string) {
|
|
2250
|
+
return self[IS_EMPTY] ? "" : string;
|
|
2251
|
+
}
|
|
2252
|
+
let styler = self[STYLER];
|
|
2253
|
+
if (styler === void 0) {
|
|
2254
|
+
return string;
|
|
2255
|
+
}
|
|
2256
|
+
const { openAll, closeAll } = styler;
|
|
2257
|
+
if (string.includes("\x1B")) {
|
|
2258
|
+
while (styler !== void 0) {
|
|
2259
|
+
string = stringReplaceAll(string, styler.close, styler.open);
|
|
2260
|
+
styler = styler.parent;
|
|
2261
|
+
}
|
|
2262
|
+
}
|
|
2263
|
+
const lfIndex = string.indexOf("\n");
|
|
2264
|
+
if (lfIndex !== -1) {
|
|
2265
|
+
string = stringEncaseCRLFWithFirstIndex(string, closeAll, openAll, lfIndex);
|
|
2266
|
+
}
|
|
2267
|
+
return openAll + string + closeAll;
|
|
2268
|
+
};
|
|
2269
|
+
Object.defineProperties(createChalk.prototype, styles2);
|
|
2270
|
+
var chalk = createChalk();
|
|
2271
|
+
var chalkStderr = createChalk({ level: stderrColor ? stderrColor.level : 0 });
|
|
2272
|
+
var source_default = chalk;
|
|
2273
|
+
|
|
2274
|
+
// ../../node_modules/.pnpm/cli-cursor@5.0.0/node_modules/cli-cursor/index.js
|
|
2275
|
+
import process5 from "process";
|
|
2276
|
+
|
|
2277
|
+
// ../../node_modules/.pnpm/restore-cursor@5.1.0/node_modules/restore-cursor/index.js
|
|
2278
|
+
import process4 from "process";
|
|
2279
|
+
|
|
2280
|
+
// ../../node_modules/.pnpm/mimic-function@5.0.1/node_modules/mimic-function/index.js
|
|
2281
|
+
var copyProperty = (to, from, property, ignoreNonConfigurable) => {
|
|
2282
|
+
if (property === "length" || property === "prototype") {
|
|
2283
|
+
return;
|
|
2284
|
+
}
|
|
2285
|
+
if (property === "arguments" || property === "caller") {
|
|
2286
|
+
return;
|
|
2287
|
+
}
|
|
2288
|
+
const toDescriptor = Object.getOwnPropertyDescriptor(to, property);
|
|
2289
|
+
const fromDescriptor = Object.getOwnPropertyDescriptor(from, property);
|
|
2290
|
+
if (!canCopyProperty(toDescriptor, fromDescriptor) && ignoreNonConfigurable) {
|
|
2291
|
+
return;
|
|
2292
|
+
}
|
|
2293
|
+
Object.defineProperty(to, property, fromDescriptor);
|
|
2294
|
+
};
|
|
2295
|
+
var canCopyProperty = function(toDescriptor, fromDescriptor) {
|
|
2296
|
+
return toDescriptor === void 0 || toDescriptor.configurable || toDescriptor.writable === fromDescriptor.writable && toDescriptor.enumerable === fromDescriptor.enumerable && toDescriptor.configurable === fromDescriptor.configurable && (toDescriptor.writable || toDescriptor.value === fromDescriptor.value);
|
|
2297
|
+
};
|
|
2298
|
+
var changePrototype = (to, from) => {
|
|
2299
|
+
const fromPrototype = Object.getPrototypeOf(from);
|
|
2300
|
+
if (fromPrototype === Object.getPrototypeOf(to)) {
|
|
2301
|
+
return;
|
|
2302
|
+
}
|
|
2303
|
+
Object.setPrototypeOf(to, fromPrototype);
|
|
2304
|
+
};
|
|
2305
|
+
var wrappedToString = (withName, fromBody) => `/* Wrapped ${withName}*/
|
|
2306
|
+
${fromBody}`;
|
|
2307
|
+
var toStringDescriptor = Object.getOwnPropertyDescriptor(Function.prototype, "toString");
|
|
2308
|
+
var toStringName = Object.getOwnPropertyDescriptor(Function.prototype.toString, "name");
|
|
2309
|
+
var changeToString = (to, from, name) => {
|
|
2310
|
+
const withName = name === "" ? "" : `with ${name.trim()}() `;
|
|
2311
|
+
const newToString = wrappedToString.bind(null, withName, from.toString());
|
|
2312
|
+
Object.defineProperty(newToString, "name", toStringName);
|
|
2313
|
+
const { writable, enumerable, configurable } = toStringDescriptor;
|
|
2314
|
+
Object.defineProperty(to, "toString", { value: newToString, writable, enumerable, configurable });
|
|
2315
|
+
};
|
|
2316
|
+
function mimicFunction(to, from, { ignoreNonConfigurable = false } = {}) {
|
|
2317
|
+
const { name } = to;
|
|
2318
|
+
for (const property of Reflect.ownKeys(from)) {
|
|
2319
|
+
copyProperty(to, from, property, ignoreNonConfigurable);
|
|
2320
|
+
}
|
|
2321
|
+
changePrototype(to, from);
|
|
2322
|
+
changeToString(to, from, name);
|
|
2323
|
+
return to;
|
|
2324
|
+
}
|
|
2325
|
+
|
|
2326
|
+
// ../../node_modules/.pnpm/onetime@7.0.0/node_modules/onetime/index.js
|
|
2327
|
+
var calledFunctions = /* @__PURE__ */ new WeakMap();
|
|
2328
|
+
var onetime = (function_, options = {}) => {
|
|
2329
|
+
if (typeof function_ !== "function") {
|
|
2330
|
+
throw new TypeError("Expected a function");
|
|
2331
|
+
}
|
|
2332
|
+
let returnValue;
|
|
2333
|
+
let callCount = 0;
|
|
2334
|
+
const functionName = function_.displayName || function_.name || "<anonymous>";
|
|
2335
|
+
const onetime2 = function(...arguments_) {
|
|
2336
|
+
calledFunctions.set(onetime2, ++callCount);
|
|
2337
|
+
if (callCount === 1) {
|
|
2338
|
+
returnValue = function_.apply(this, arguments_);
|
|
2339
|
+
function_ = void 0;
|
|
2340
|
+
} else if (options.throw === true) {
|
|
2341
|
+
throw new Error(`Function \`${functionName}\` can only be called once`);
|
|
2342
|
+
}
|
|
2343
|
+
return returnValue;
|
|
2344
|
+
};
|
|
2345
|
+
mimicFunction(onetime2, function_);
|
|
2346
|
+
calledFunctions.set(onetime2, callCount);
|
|
2347
|
+
return onetime2;
|
|
2348
|
+
};
|
|
2349
|
+
onetime.callCount = (function_) => {
|
|
2350
|
+
if (!calledFunctions.has(function_)) {
|
|
2351
|
+
throw new Error(`The given function \`${function_.name}\` is not wrapped by the \`onetime\` package`);
|
|
2352
|
+
}
|
|
2353
|
+
return calledFunctions.get(function_);
|
|
2354
|
+
};
|
|
2355
|
+
var onetime_default = onetime;
|
|
2356
|
+
|
|
2357
|
+
// ../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/signals.js
|
|
2358
|
+
var signals = [];
|
|
2359
|
+
signals.push("SIGHUP", "SIGINT", "SIGTERM");
|
|
2360
|
+
if (process.platform !== "win32") {
|
|
2361
|
+
signals.push(
|
|
2362
|
+
"SIGALRM",
|
|
2363
|
+
"SIGABRT",
|
|
2364
|
+
"SIGVTALRM",
|
|
2365
|
+
"SIGXCPU",
|
|
2366
|
+
"SIGXFSZ",
|
|
2367
|
+
"SIGUSR2",
|
|
2368
|
+
"SIGTRAP",
|
|
2369
|
+
"SIGSYS",
|
|
2370
|
+
"SIGQUIT",
|
|
2371
|
+
"SIGIOT"
|
|
2372
|
+
// should detect profiler and enable/disable accordingly.
|
|
2373
|
+
// see #21
|
|
2374
|
+
// 'SIGPROF'
|
|
2375
|
+
);
|
|
2376
|
+
}
|
|
2377
|
+
if (process.platform === "linux") {
|
|
2378
|
+
signals.push("SIGIO", "SIGPOLL", "SIGPWR", "SIGSTKFLT");
|
|
2379
|
+
}
|
|
2380
|
+
|
|
2381
|
+
// ../../node_modules/.pnpm/signal-exit@4.1.0/node_modules/signal-exit/dist/mjs/index.js
|
|
2382
|
+
var processOk = (process10) => !!process10 && typeof process10 === "object" && typeof process10.removeListener === "function" && typeof process10.emit === "function" && typeof process10.reallyExit === "function" && typeof process10.listeners === "function" && typeof process10.kill === "function" && typeof process10.pid === "number" && typeof process10.on === "function";
|
|
2383
|
+
var kExitEmitter = Symbol.for("signal-exit emitter");
|
|
2384
|
+
var global = globalThis;
|
|
2385
|
+
var ObjectDefineProperty = Object.defineProperty.bind(Object);
|
|
2386
|
+
var Emitter = class {
|
|
2387
|
+
emitted = {
|
|
2388
|
+
afterExit: false,
|
|
2389
|
+
exit: false
|
|
2390
|
+
};
|
|
2391
|
+
listeners = {
|
|
2392
|
+
afterExit: [],
|
|
2393
|
+
exit: []
|
|
2394
|
+
};
|
|
2395
|
+
count = 0;
|
|
2396
|
+
id = Math.random();
|
|
2397
|
+
constructor() {
|
|
2398
|
+
if (global[kExitEmitter]) {
|
|
2399
|
+
return global[kExitEmitter];
|
|
2400
|
+
}
|
|
2401
|
+
ObjectDefineProperty(global, kExitEmitter, {
|
|
2402
|
+
value: this,
|
|
2403
|
+
writable: false,
|
|
2404
|
+
enumerable: false,
|
|
2405
|
+
configurable: false
|
|
2406
|
+
});
|
|
2407
|
+
}
|
|
2408
|
+
on(ev, fn) {
|
|
2409
|
+
this.listeners[ev].push(fn);
|
|
2410
|
+
}
|
|
2411
|
+
removeListener(ev, fn) {
|
|
2412
|
+
const list = this.listeners[ev];
|
|
2413
|
+
const i = list.indexOf(fn);
|
|
2414
|
+
if (i === -1) {
|
|
2415
|
+
return;
|
|
2416
|
+
}
|
|
2417
|
+
if (i === 0 && list.length === 1) {
|
|
2418
|
+
list.length = 0;
|
|
2419
|
+
} else {
|
|
2420
|
+
list.splice(i, 1);
|
|
2421
|
+
}
|
|
2422
|
+
}
|
|
2423
|
+
emit(ev, code, signal) {
|
|
2424
|
+
if (this.emitted[ev]) {
|
|
2425
|
+
return false;
|
|
2426
|
+
}
|
|
2427
|
+
this.emitted[ev] = true;
|
|
2428
|
+
let ret = false;
|
|
2429
|
+
for (const fn of this.listeners[ev]) {
|
|
2430
|
+
ret = fn(code, signal) === true || ret;
|
|
2431
|
+
}
|
|
2432
|
+
if (ev === "exit") {
|
|
2433
|
+
ret = this.emit("afterExit", code, signal) || ret;
|
|
2434
|
+
}
|
|
2435
|
+
return ret;
|
|
2436
|
+
}
|
|
2437
|
+
};
|
|
2438
|
+
var SignalExitBase = class {
|
|
2439
|
+
};
|
|
2440
|
+
var signalExitWrap = (handler) => {
|
|
2441
|
+
return {
|
|
2442
|
+
onExit(cb, opts) {
|
|
2443
|
+
return handler.onExit(cb, opts);
|
|
2444
|
+
},
|
|
2445
|
+
load() {
|
|
2446
|
+
return handler.load();
|
|
2447
|
+
},
|
|
2448
|
+
unload() {
|
|
2449
|
+
return handler.unload();
|
|
2450
|
+
}
|
|
2451
|
+
};
|
|
2452
|
+
};
|
|
2453
|
+
var SignalExitFallback = class extends SignalExitBase {
|
|
2454
|
+
onExit() {
|
|
2455
|
+
return () => {
|
|
2456
|
+
};
|
|
2457
|
+
}
|
|
2458
|
+
load() {
|
|
2459
|
+
}
|
|
2460
|
+
unload() {
|
|
2461
|
+
}
|
|
2462
|
+
};
|
|
2463
|
+
var SignalExit = class extends SignalExitBase {
|
|
2464
|
+
// "SIGHUP" throws an `ENOSYS` error on Windows,
|
|
2465
|
+
// so use a supported signal instead
|
|
2466
|
+
/* c8 ignore start */
|
|
2467
|
+
#hupSig = process3.platform === "win32" ? "SIGINT" : "SIGHUP";
|
|
2468
|
+
/* c8 ignore stop */
|
|
2469
|
+
#emitter = new Emitter();
|
|
2470
|
+
#process;
|
|
2471
|
+
#originalProcessEmit;
|
|
2472
|
+
#originalProcessReallyExit;
|
|
2473
|
+
#sigListeners = {};
|
|
2474
|
+
#loaded = false;
|
|
2475
|
+
constructor(process10) {
|
|
2476
|
+
super();
|
|
2477
|
+
this.#process = process10;
|
|
2478
|
+
this.#sigListeners = {};
|
|
2479
|
+
for (const sig of signals) {
|
|
2480
|
+
this.#sigListeners[sig] = () => {
|
|
2481
|
+
const listeners = this.#process.listeners(sig);
|
|
2482
|
+
let { count } = this.#emitter;
|
|
2483
|
+
const p = process10;
|
|
2484
|
+
if (typeof p.__signal_exit_emitter__ === "object" && typeof p.__signal_exit_emitter__.count === "number") {
|
|
2485
|
+
count += p.__signal_exit_emitter__.count;
|
|
2486
|
+
}
|
|
2487
|
+
if (listeners.length === count) {
|
|
2488
|
+
this.unload();
|
|
2489
|
+
const ret = this.#emitter.emit("exit", null, sig);
|
|
2490
|
+
const s = sig === "SIGHUP" ? this.#hupSig : sig;
|
|
2491
|
+
if (!ret)
|
|
2492
|
+
process10.kill(process10.pid, s);
|
|
2493
|
+
}
|
|
2494
|
+
};
|
|
2495
|
+
}
|
|
2496
|
+
this.#originalProcessReallyExit = process10.reallyExit;
|
|
2497
|
+
this.#originalProcessEmit = process10.emit;
|
|
2498
|
+
}
|
|
2499
|
+
onExit(cb, opts) {
|
|
2500
|
+
if (!processOk(this.#process)) {
|
|
2501
|
+
return () => {
|
|
2502
|
+
};
|
|
2503
|
+
}
|
|
2504
|
+
if (this.#loaded === false) {
|
|
2505
|
+
this.load();
|
|
2506
|
+
}
|
|
2507
|
+
const ev = opts?.alwaysLast ? "afterExit" : "exit";
|
|
2508
|
+
this.#emitter.on(ev, cb);
|
|
2509
|
+
return () => {
|
|
2510
|
+
this.#emitter.removeListener(ev, cb);
|
|
2511
|
+
if (this.#emitter.listeners["exit"].length === 0 && this.#emitter.listeners["afterExit"].length === 0) {
|
|
2512
|
+
this.unload();
|
|
2513
|
+
}
|
|
2514
|
+
};
|
|
2515
|
+
}
|
|
2516
|
+
load() {
|
|
2517
|
+
if (this.#loaded) {
|
|
2518
|
+
return;
|
|
2519
|
+
}
|
|
2520
|
+
this.#loaded = true;
|
|
2521
|
+
this.#emitter.count += 1;
|
|
2522
|
+
for (const sig of signals) {
|
|
2523
|
+
try {
|
|
2524
|
+
const fn = this.#sigListeners[sig];
|
|
2525
|
+
if (fn)
|
|
2526
|
+
this.#process.on(sig, fn);
|
|
2527
|
+
} catch (_) {
|
|
2528
|
+
}
|
|
2529
|
+
}
|
|
2530
|
+
this.#process.emit = (ev, ...a) => {
|
|
2531
|
+
return this.#processEmit(ev, ...a);
|
|
2532
|
+
};
|
|
2533
|
+
this.#process.reallyExit = (code) => {
|
|
2534
|
+
return this.#processReallyExit(code);
|
|
2535
|
+
};
|
|
2536
|
+
}
|
|
2537
|
+
unload() {
|
|
2538
|
+
if (!this.#loaded) {
|
|
2539
|
+
return;
|
|
2540
|
+
}
|
|
2541
|
+
this.#loaded = false;
|
|
2542
|
+
signals.forEach((sig) => {
|
|
2543
|
+
const listener = this.#sigListeners[sig];
|
|
2544
|
+
if (!listener) {
|
|
2545
|
+
throw new Error("Listener not defined for signal: " + sig);
|
|
2546
|
+
}
|
|
2547
|
+
try {
|
|
2548
|
+
this.#process.removeListener(sig, listener);
|
|
2549
|
+
} catch (_) {
|
|
2550
|
+
}
|
|
2551
|
+
});
|
|
2552
|
+
this.#process.emit = this.#originalProcessEmit;
|
|
2553
|
+
this.#process.reallyExit = this.#originalProcessReallyExit;
|
|
2554
|
+
this.#emitter.count -= 1;
|
|
2555
|
+
}
|
|
2556
|
+
#processReallyExit(code) {
|
|
2557
|
+
if (!processOk(this.#process)) {
|
|
2558
|
+
return 0;
|
|
2559
|
+
}
|
|
2560
|
+
this.#process.exitCode = code || 0;
|
|
2561
|
+
this.#emitter.emit("exit", this.#process.exitCode, null);
|
|
2562
|
+
return this.#originalProcessReallyExit.call(this.#process, this.#process.exitCode);
|
|
2563
|
+
}
|
|
2564
|
+
#processEmit(ev, ...args) {
|
|
2565
|
+
const og = this.#originalProcessEmit;
|
|
2566
|
+
if (ev === "exit" && processOk(this.#process)) {
|
|
2567
|
+
if (typeof args[0] === "number") {
|
|
2568
|
+
this.#process.exitCode = args[0];
|
|
2569
|
+
}
|
|
2570
|
+
const ret = og.call(this.#process, ev, ...args);
|
|
2571
|
+
this.#emitter.emit("exit", this.#process.exitCode, null);
|
|
2572
|
+
return ret;
|
|
2573
|
+
} else {
|
|
2574
|
+
return og.call(this.#process, ev, ...args);
|
|
2575
|
+
}
|
|
2576
|
+
}
|
|
2577
|
+
};
|
|
2578
|
+
var process3 = globalThis.process;
|
|
2579
|
+
var {
|
|
2580
|
+
/**
|
|
2581
|
+
* Called when the process is exiting, whether via signal, explicit
|
|
2582
|
+
* exit, or running out of stuff to do.
|
|
2583
|
+
*
|
|
2584
|
+
* If the global process object is not suitable for instrumentation,
|
|
2585
|
+
* then this will be a no-op.
|
|
2586
|
+
*
|
|
2587
|
+
* Returns a function that may be used to unload signal-exit.
|
|
2588
|
+
*/
|
|
2589
|
+
onExit,
|
|
2590
|
+
/**
|
|
2591
|
+
* Load the listeners. Likely you never need to call this, unless
|
|
2592
|
+
* doing a rather deep integration with signal-exit functionality.
|
|
2593
|
+
* Mostly exposed for the benefit of testing.
|
|
2594
|
+
*
|
|
2595
|
+
* @internal
|
|
2596
|
+
*/
|
|
2597
|
+
load,
|
|
2598
|
+
/**
|
|
2599
|
+
* Unload the listeners. Likely you never need to call this, unless
|
|
2600
|
+
* doing a rather deep integration with signal-exit functionality.
|
|
2601
|
+
* Mostly exposed for the benefit of testing.
|
|
2602
|
+
*
|
|
2603
|
+
* @internal
|
|
2604
|
+
*/
|
|
2605
|
+
unload
|
|
2606
|
+
} = signalExitWrap(processOk(process3) ? new SignalExit(process3) : new SignalExitFallback());
|
|
2607
|
+
|
|
2608
|
+
// ../../node_modules/.pnpm/restore-cursor@5.1.0/node_modules/restore-cursor/index.js
|
|
2609
|
+
var terminal = process4.stderr.isTTY ? process4.stderr : process4.stdout.isTTY ? process4.stdout : void 0;
|
|
2610
|
+
var restoreCursor = terminal ? onetime_default(() => {
|
|
2611
|
+
onExit(() => {
|
|
2612
|
+
terminal.write("\x1B[?25h");
|
|
2613
|
+
}, { alwaysLast: true });
|
|
2614
|
+
}) : () => {
|
|
2615
|
+
};
|
|
2616
|
+
var restore_cursor_default = restoreCursor;
|
|
2617
|
+
|
|
2618
|
+
// ../../node_modules/.pnpm/cli-cursor@5.0.0/node_modules/cli-cursor/index.js
|
|
2619
|
+
var isHidden = false;
|
|
2620
|
+
var cliCursor = {};
|
|
2621
|
+
cliCursor.show = (writableStream = process5.stderr) => {
|
|
2622
|
+
if (!writableStream.isTTY) {
|
|
2623
|
+
return;
|
|
2624
|
+
}
|
|
2625
|
+
isHidden = false;
|
|
2626
|
+
writableStream.write("\x1B[?25h");
|
|
2627
|
+
};
|
|
2628
|
+
cliCursor.hide = (writableStream = process5.stderr) => {
|
|
2629
|
+
if (!writableStream.isTTY) {
|
|
2630
|
+
return;
|
|
2631
|
+
}
|
|
2632
|
+
restore_cursor_default();
|
|
2633
|
+
isHidden = true;
|
|
2634
|
+
writableStream.write("\x1B[?25l");
|
|
2635
|
+
};
|
|
2636
|
+
cliCursor.toggle = (force, writableStream) => {
|
|
2637
|
+
if (force !== void 0) {
|
|
2638
|
+
isHidden = force;
|
|
2639
|
+
}
|
|
2640
|
+
if (isHidden) {
|
|
2641
|
+
cliCursor.show(writableStream);
|
|
2642
|
+
} else {
|
|
2643
|
+
cliCursor.hide(writableStream);
|
|
2644
|
+
}
|
|
2645
|
+
};
|
|
2646
|
+
var cli_cursor_default = cliCursor;
|
|
2647
|
+
|
|
2648
|
+
// ../../node_modules/.pnpm/ora@8.2.0/node_modules/ora/index.js
|
|
2649
|
+
var import_cli_spinners = __toESM(require_cli_spinners(), 1);
|
|
2650
|
+
|
|
2651
|
+
// ../../node_modules/.pnpm/is-unicode-supported@1.3.0/node_modules/is-unicode-supported/index.js
|
|
2652
|
+
import process6 from "process";
|
|
2653
|
+
function isUnicodeSupported() {
|
|
2654
|
+
if (process6.platform !== "win32") {
|
|
2655
|
+
return process6.env.TERM !== "linux";
|
|
2656
|
+
}
|
|
2657
|
+
return Boolean(process6.env.CI) || Boolean(process6.env.WT_SESSION) || Boolean(process6.env.TERMINUS_SUBLIME) || process6.env.ConEmuTask === "{cmd::Cmder}" || process6.env.TERM_PROGRAM === "Terminus-Sublime" || process6.env.TERM_PROGRAM === "vscode" || process6.env.TERM === "xterm-256color" || process6.env.TERM === "alacritty" || process6.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
2658
|
+
}
|
|
2659
|
+
|
|
2660
|
+
// ../../node_modules/.pnpm/log-symbols@6.0.0/node_modules/log-symbols/index.js
|
|
2661
|
+
var main = {
|
|
2662
|
+
info: source_default.blue("\u2139"),
|
|
2663
|
+
success: source_default.green("\u2714"),
|
|
2664
|
+
warning: source_default.yellow("\u26A0"),
|
|
2665
|
+
error: source_default.red("\u2716")
|
|
2666
|
+
};
|
|
2667
|
+
var fallback = {
|
|
2668
|
+
info: source_default.blue("i"),
|
|
2669
|
+
success: source_default.green("\u221A"),
|
|
2670
|
+
warning: source_default.yellow("\u203C"),
|
|
2671
|
+
error: source_default.red("\xD7")
|
|
2672
|
+
};
|
|
2673
|
+
var logSymbols = isUnicodeSupported() ? main : fallback;
|
|
2674
|
+
var log_symbols_default = logSymbols;
|
|
2675
|
+
|
|
2676
|
+
// ../../node_modules/.pnpm/ansi-regex@6.2.2/node_modules/ansi-regex/index.js
|
|
2677
|
+
function ansiRegex({ onlyFirst = false } = {}) {
|
|
2678
|
+
const ST = "(?:\\u0007|\\u001B\\u005C|\\u009C)";
|
|
2679
|
+
const osc = `(?:\\u001B\\][\\s\\S]*?${ST})`;
|
|
2680
|
+
const csi = "[\\u001B\\u009B][[\\]()#;?]*(?:\\d{1,4}(?:[;:]\\d{0,4})*)?[\\dA-PR-TZcf-nq-uy=><~]";
|
|
2681
|
+
const pattern = `${osc}|${csi}`;
|
|
2682
|
+
return new RegExp(pattern, onlyFirst ? void 0 : "g");
|
|
2683
|
+
}
|
|
2684
|
+
|
|
2685
|
+
// ../../node_modules/.pnpm/strip-ansi@7.1.2/node_modules/strip-ansi/index.js
|
|
2686
|
+
var regex = ansiRegex();
|
|
2687
|
+
function stripAnsi(string) {
|
|
2688
|
+
if (typeof string !== "string") {
|
|
2689
|
+
throw new TypeError(`Expected a \`string\`, got \`${typeof string}\``);
|
|
2690
|
+
}
|
|
2691
|
+
return string.replace(regex, "");
|
|
2692
|
+
}
|
|
2693
|
+
|
|
2694
|
+
// ../../node_modules/.pnpm/get-east-asian-width@1.4.0/node_modules/get-east-asian-width/lookup.js
|
|
2695
|
+
function isAmbiguous(x) {
|
|
2696
|
+
return x === 161 || x === 164 || x === 167 || x === 168 || x === 170 || x === 173 || x === 174 || x >= 176 && x <= 180 || x >= 182 && x <= 186 || x >= 188 && x <= 191 || x === 198 || x === 208 || x === 215 || x === 216 || x >= 222 && x <= 225 || x === 230 || x >= 232 && x <= 234 || x === 236 || x === 237 || x === 240 || x === 242 || x === 243 || x >= 247 && x <= 250 || x === 252 || x === 254 || x === 257 || x === 273 || x === 275 || x === 283 || x === 294 || x === 295 || x === 299 || x >= 305 && x <= 307 || x === 312 || x >= 319 && x <= 322 || x === 324 || x >= 328 && x <= 331 || x === 333 || x === 338 || x === 339 || x === 358 || x === 359 || x === 363 || x === 462 || x === 464 || x === 466 || x === 468 || x === 470 || x === 472 || x === 474 || x === 476 || x === 593 || x === 609 || x === 708 || x === 711 || x >= 713 && x <= 715 || x === 717 || x === 720 || x >= 728 && x <= 731 || x === 733 || x === 735 || x >= 768 && x <= 879 || x >= 913 && x <= 929 || x >= 931 && x <= 937 || x >= 945 && x <= 961 || x >= 963 && x <= 969 || x === 1025 || x >= 1040 && x <= 1103 || x === 1105 || x === 8208 || x >= 8211 && x <= 8214 || x === 8216 || x === 8217 || x === 8220 || x === 8221 || x >= 8224 && x <= 8226 || x >= 8228 && x <= 8231 || x === 8240 || x === 8242 || x === 8243 || x === 8245 || x === 8251 || x === 8254 || x === 8308 || x === 8319 || x >= 8321 && x <= 8324 || x === 8364 || x === 8451 || x === 8453 || x === 8457 || x === 8467 || x === 8470 || x === 8481 || x === 8482 || x === 8486 || x === 8491 || x === 8531 || x === 8532 || x >= 8539 && x <= 8542 || x >= 8544 && x <= 8555 || x >= 8560 && x <= 8569 || x === 8585 || x >= 8592 && x <= 8601 || x === 8632 || x === 8633 || x === 8658 || x === 8660 || x === 8679 || x === 8704 || x === 8706 || x === 8707 || x === 8711 || x === 8712 || x === 8715 || x === 8719 || x === 8721 || x === 8725 || x === 8730 || x >= 8733 && x <= 8736 || x === 8739 || x === 8741 || x >= 8743 && x <= 8748 || x === 8750 || x >= 8756 && x <= 8759 || x === 8764 || x === 8765 || x === 8776 || x === 8780 || x === 8786 || x === 8800 || x === 8801 || x >= 8804 && x <= 8807 || x === 8810 || x === 8811 || x === 8814 || x === 8815 || x === 8834 || x === 8835 || x === 8838 || x === 8839 || x === 8853 || x === 8857 || x === 8869 || x === 8895 || x === 8978 || x >= 9312 && x <= 9449 || x >= 9451 && x <= 9547 || x >= 9552 && x <= 9587 || x >= 9600 && x <= 9615 || x >= 9618 && x <= 9621 || x === 9632 || x === 9633 || x >= 9635 && x <= 9641 || x === 9650 || x === 9651 || x === 9654 || x === 9655 || x === 9660 || x === 9661 || x === 9664 || x === 9665 || x >= 9670 && x <= 9672 || x === 9675 || x >= 9678 && x <= 9681 || x >= 9698 && x <= 9701 || x === 9711 || x === 9733 || x === 9734 || x === 9737 || x === 9742 || x === 9743 || x === 9756 || x === 9758 || x === 9792 || x === 9794 || x === 9824 || x === 9825 || x >= 9827 && x <= 9829 || x >= 9831 && x <= 9834 || x === 9836 || x === 9837 || x === 9839 || x === 9886 || x === 9887 || x === 9919 || x >= 9926 && x <= 9933 || x >= 9935 && x <= 9939 || x >= 9941 && x <= 9953 || x === 9955 || x === 9960 || x === 9961 || x >= 9963 && x <= 9969 || x === 9972 || x >= 9974 && x <= 9977 || x === 9979 || x === 9980 || x === 9982 || x === 9983 || x === 10045 || x >= 10102 && x <= 10111 || x >= 11094 && x <= 11097 || x >= 12872 && x <= 12879 || x >= 57344 && x <= 63743 || x >= 65024 && x <= 65039 || x === 65533 || x >= 127232 && x <= 127242 || x >= 127248 && x <= 127277 || x >= 127280 && x <= 127337 || x >= 127344 && x <= 127373 || x === 127375 || x === 127376 || x >= 127387 && x <= 127404 || x >= 917760 && x <= 917999 || x >= 983040 && x <= 1048573 || x >= 1048576 && x <= 1114109;
|
|
2697
|
+
}
|
|
2698
|
+
function isFullWidth(x) {
|
|
2699
|
+
return x === 12288 || x >= 65281 && x <= 65376 || x >= 65504 && x <= 65510;
|
|
2700
|
+
}
|
|
2701
|
+
function isWide(x) {
|
|
2702
|
+
return x >= 4352 && x <= 4447 || x === 8986 || x === 8987 || x === 9001 || x === 9002 || x >= 9193 && x <= 9196 || x === 9200 || x === 9203 || x === 9725 || x === 9726 || x === 9748 || x === 9749 || x >= 9776 && x <= 9783 || x >= 9800 && x <= 9811 || x === 9855 || x >= 9866 && x <= 9871 || x === 9875 || x === 9889 || x === 9898 || x === 9899 || x === 9917 || x === 9918 || x === 9924 || x === 9925 || x === 9934 || x === 9940 || x === 9962 || x === 9970 || x === 9971 || x === 9973 || x === 9978 || x === 9981 || x === 9989 || x === 9994 || x === 9995 || x === 10024 || x === 10060 || x === 10062 || x >= 10067 && x <= 10069 || x === 10071 || x >= 10133 && x <= 10135 || x === 10160 || x === 10175 || x === 11035 || x === 11036 || x === 11088 || x === 11093 || x >= 11904 && x <= 11929 || x >= 11931 && x <= 12019 || x >= 12032 && x <= 12245 || x >= 12272 && x <= 12287 || x >= 12289 && x <= 12350 || x >= 12353 && x <= 12438 || x >= 12441 && x <= 12543 || x >= 12549 && x <= 12591 || x >= 12593 && x <= 12686 || x >= 12688 && x <= 12773 || x >= 12783 && x <= 12830 || x >= 12832 && x <= 12871 || x >= 12880 && x <= 42124 || x >= 42128 && x <= 42182 || x >= 43360 && x <= 43388 || x >= 44032 && x <= 55203 || x >= 63744 && x <= 64255 || x >= 65040 && x <= 65049 || x >= 65072 && x <= 65106 || x >= 65108 && x <= 65126 || x >= 65128 && x <= 65131 || x >= 94176 && x <= 94180 || x >= 94192 && x <= 94198 || x >= 94208 && x <= 101589 || x >= 101631 && x <= 101662 || x >= 101760 && x <= 101874 || x >= 110576 && x <= 110579 || x >= 110581 && x <= 110587 || x === 110589 || x === 110590 || x >= 110592 && x <= 110882 || x === 110898 || x >= 110928 && x <= 110930 || x === 110933 || x >= 110948 && x <= 110951 || x >= 110960 && x <= 111355 || x >= 119552 && x <= 119638 || x >= 119648 && x <= 119670 || x === 126980 || x === 127183 || x === 127374 || x >= 127377 && x <= 127386 || x >= 127488 && x <= 127490 || x >= 127504 && x <= 127547 || x >= 127552 && x <= 127560 || x === 127568 || x === 127569 || x >= 127584 && x <= 127589 || x >= 127744 && x <= 127776 || x >= 127789 && x <= 127797 || x >= 127799 && x <= 127868 || x >= 127870 && x <= 127891 || x >= 127904 && x <= 127946 || x >= 127951 && x <= 127955 || x >= 127968 && x <= 127984 || x === 127988 || x >= 127992 && x <= 128062 || x === 128064 || x >= 128066 && x <= 128252 || x >= 128255 && x <= 128317 || x >= 128331 && x <= 128334 || x >= 128336 && x <= 128359 || x === 128378 || x === 128405 || x === 128406 || x === 128420 || x >= 128507 && x <= 128591 || x >= 128640 && x <= 128709 || x === 128716 || x >= 128720 && x <= 128722 || x >= 128725 && x <= 128728 || x >= 128732 && x <= 128735 || x === 128747 || x === 128748 || x >= 128756 && x <= 128764 || x >= 128992 && x <= 129003 || x === 129008 || x >= 129292 && x <= 129338 || x >= 129340 && x <= 129349 || x >= 129351 && x <= 129535 || x >= 129648 && x <= 129660 || x >= 129664 && x <= 129674 || x >= 129678 && x <= 129734 || x === 129736 || x >= 129741 && x <= 129756 || x >= 129759 && x <= 129770 || x >= 129775 && x <= 129784 || x >= 131072 && x <= 196605 || x >= 196608 && x <= 262141;
|
|
2703
|
+
}
|
|
2704
|
+
|
|
2705
|
+
// ../../node_modules/.pnpm/get-east-asian-width@1.4.0/node_modules/get-east-asian-width/index.js
|
|
2706
|
+
function validate(codePoint) {
|
|
2707
|
+
if (!Number.isSafeInteger(codePoint)) {
|
|
2708
|
+
throw new TypeError(`Expected a code point, got \`${typeof codePoint}\`.`);
|
|
2709
|
+
}
|
|
2710
|
+
}
|
|
2711
|
+
function eastAsianWidth(codePoint, { ambiguousAsWide = false } = {}) {
|
|
2712
|
+
validate(codePoint);
|
|
2713
|
+
if (isFullWidth(codePoint) || isWide(codePoint) || ambiguousAsWide && isAmbiguous(codePoint)) {
|
|
2714
|
+
return 2;
|
|
2715
|
+
}
|
|
2716
|
+
return 1;
|
|
2717
|
+
}
|
|
2718
|
+
|
|
2719
|
+
// ../../node_modules/.pnpm/emoji-regex@10.6.0/node_modules/emoji-regex/index.mjs
|
|
2720
|
+
var emoji_regex_default = () => {
|
|
2721
|
+
return /[#*0-9]\uFE0F?\u20E3|[\xA9\xAE\u203C\u2049\u2122\u2139\u2194-\u2199\u21A9\u21AA\u231A\u231B\u2328\u23CF\u23ED-\u23EF\u23F1\u23F2\u23F8-\u23FA\u24C2\u25AA\u25AB\u25B6\u25C0\u25FB\u25FC\u25FE\u2600-\u2604\u260E\u2611\u2614\u2615\u2618\u2620\u2622\u2623\u2626\u262A\u262E\u262F\u2638-\u263A\u2640\u2642\u2648-\u2653\u265F\u2660\u2663\u2665\u2666\u2668\u267B\u267E\u267F\u2692\u2694-\u2697\u2699\u269B\u269C\u26A0\u26A7\u26AA\u26B0\u26B1\u26BD\u26BE\u26C4\u26C8\u26CF\u26D1\u26E9\u26F0-\u26F5\u26F7\u26F8\u26FA\u2702\u2708\u2709\u270F\u2712\u2714\u2716\u271D\u2721\u2733\u2734\u2744\u2747\u2757\u2763\u27A1\u2934\u2935\u2B05-\u2B07\u2B1B\u2B1C\u2B55\u3030\u303D\u3297\u3299]\uFE0F?|[\u261D\u270C\u270D](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\u270A\u270B](?:\uD83C[\uDFFB-\uDFFF])?|[\u23E9-\u23EC\u23F0\u23F3\u25FD\u2693\u26A1\u26AB\u26C5\u26CE\u26D4\u26EA\u26FD\u2705\u2728\u274C\u274E\u2753-\u2755\u2795-\u2797\u27B0\u27BF\u2B50]|\u26D3\uFE0F?(?:\u200D\uD83D\uDCA5)?|\u26F9(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\u2764\uFE0F?(?:\u200D(?:\uD83D\uDD25|\uD83E\uDE79))?|\uD83C(?:[\uDC04\uDD70\uDD71\uDD7E\uDD7F\uDE02\uDE37\uDF21\uDF24-\uDF2C\uDF36\uDF7D\uDF96\uDF97\uDF99-\uDF9B\uDF9E\uDF9F\uDFCD\uDFCE\uDFD4-\uDFDF\uDFF5\uDFF7]\uFE0F?|[\uDF85\uDFC2\uDFC7](?:\uD83C[\uDFFB-\uDFFF])?|[\uDFC4\uDFCA](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDFCB\uDFCC](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDCCF\uDD8E\uDD91-\uDD9A\uDE01\uDE1A\uDE2F\uDE32-\uDE36\uDE38-\uDE3A\uDE50\uDE51\uDF00-\uDF20\uDF2D-\uDF35\uDF37-\uDF43\uDF45-\uDF4A\uDF4C-\uDF7C\uDF7E-\uDF84\uDF86-\uDF93\uDFA0-\uDFC1\uDFC5\uDFC6\uDFC8\uDFC9\uDFCF-\uDFD3\uDFE0-\uDFF0\uDFF8-\uDFFF]|\uDDE6\uD83C[\uDDE8-\uDDEC\uDDEE\uDDF1\uDDF2\uDDF4\uDDF6-\uDDFA\uDDFC\uDDFD\uDDFF]|\uDDE7\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEF\uDDF1-\uDDF4\uDDF6-\uDDF9\uDDFB\uDDFC\uDDFE\uDDFF]|\uDDE8\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDEE\uDDF0-\uDDF7\uDDFA-\uDDFF]|\uDDE9\uD83C[\uDDEA\uDDEC\uDDEF\uDDF0\uDDF2\uDDF4\uDDFF]|\uDDEA\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDED\uDDF7-\uDDFA]|\uDDEB\uD83C[\uDDEE-\uDDF0\uDDF2\uDDF4\uDDF7]|\uDDEC\uD83C[\uDDE6\uDDE7\uDDE9-\uDDEE\uDDF1-\uDDF3\uDDF5-\uDDFA\uDDFC\uDDFE]|\uDDED\uD83C[\uDDF0\uDDF2\uDDF3\uDDF7\uDDF9\uDDFA]|\uDDEE\uD83C[\uDDE8-\uDDEA\uDDF1-\uDDF4\uDDF6-\uDDF9]|\uDDEF\uD83C[\uDDEA\uDDF2\uDDF4\uDDF5]|\uDDF0\uD83C[\uDDEA\uDDEC-\uDDEE\uDDF2\uDDF3\uDDF5\uDDF7\uDDFC\uDDFE\uDDFF]|\uDDF1\uD83C[\uDDE6-\uDDE8\uDDEE\uDDF0\uDDF7-\uDDFB\uDDFE]|\uDDF2\uD83C[\uDDE6\uDDE8-\uDDED\uDDF0-\uDDFF]|\uDDF3\uD83C[\uDDE6\uDDE8\uDDEA-\uDDEC\uDDEE\uDDF1\uDDF4\uDDF5\uDDF7\uDDFA\uDDFF]|\uDDF4\uD83C\uDDF2|\uDDF5\uD83C[\uDDE6\uDDEA-\uDDED\uDDF0-\uDDF3\uDDF7-\uDDF9\uDDFC\uDDFE]|\uDDF6\uD83C\uDDE6|\uDDF7\uD83C[\uDDEA\uDDF4\uDDF8\uDDFA\uDDFC]|\uDDF8\uD83C[\uDDE6-\uDDEA\uDDEC-\uDDF4\uDDF7-\uDDF9\uDDFB\uDDFD-\uDDFF]|\uDDF9\uD83C[\uDDE6\uDDE8\uDDE9\uDDEB-\uDDED\uDDEF-\uDDF4\uDDF7\uDDF9\uDDFB\uDDFC\uDDFF]|\uDDFA\uD83C[\uDDE6\uDDEC\uDDF2\uDDF3\uDDF8\uDDFE\uDDFF]|\uDDFB\uD83C[\uDDE6\uDDE8\uDDEA\uDDEC\uDDEE\uDDF3\uDDFA]|\uDDFC\uD83C[\uDDEB\uDDF8]|\uDDFD\uD83C\uDDF0|\uDDFE\uD83C[\uDDEA\uDDF9]|\uDDFF\uD83C[\uDDE6\uDDF2\uDDFC]|\uDF44(?:\u200D\uD83D\uDFEB)?|\uDF4B(?:\u200D\uD83D\uDFE9)?|\uDFC3(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDFF3\uFE0F?(?:\u200D(?:\u26A7\uFE0F?|\uD83C\uDF08))?|\uDFF4(?:\u200D\u2620\uFE0F?|\uDB40\uDC67\uDB40\uDC62\uDB40(?:\uDC65\uDB40\uDC6E\uDB40\uDC67|\uDC73\uDB40\uDC63\uDB40\uDC74|\uDC77\uDB40\uDC6C\uDB40\uDC73)\uDB40\uDC7F)?)|\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?|[\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](?:\uD83C[\uDFFB-\uDFFF])?|[\uDC6E-\uDC71\uDC73\uDC77\uDC81\uDC82\uDC86\uDC87\uDE45-\uDE47\uDE4B\uDE4D\uDE4E\uDEA3\uDEB4\uDEB5](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD74\uDD90](?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?|[\uDC00-\uDC07\uDC09-\uDC14\uDC16-\uDC25\uDC27-\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-\uDE41\uDE43\uDE44\uDE48-\uDE4A\uDE80-\uDEA2\uDEA4-\uDEB3\uDEB7-\uDEBF\uDEC1-\uDEC5\uDED0-\uDED2\uDED5-\uDED8\uDEDC-\uDEDF\uDEEB\uDEEC\uDEF4-\uDEFC\uDFE0-\uDFEB\uDFF0]|\uDC08(?:\u200D\u2B1B)?|\uDC15(?:\u200D\uD83E\uDDBA)?|\uDC26(?:\u200D(?:\u2B1B|\uD83D\uDD25))?|\uDC3B(?:\u200D\u2744\uFE0F?)?|\uDC41\uFE0F?(?:\u200D\uD83D\uDDE8\uFE0F?)?|\uDC68(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDC68\uDC69]\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?)|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFC-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFD-\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFD\uDFFF]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?\uDC68\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDD1D\uDEEF]\u200D\uD83D\uDC68\uD83C[\uDFFB-\uDFFE]|[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3])))?))?|\uDC69(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:\uDC8B\u200D\uD83D)?[\uDC68\uDC69]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?|\uDC69\u200D\uD83D(?:\uDC66(?:\u200D\uD83D\uDC66)?|\uDC67(?:\u200D\uD83D[\uDC66\uDC67])?))|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFC-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFD-\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFD\uDFFF]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D\uD83D(?:[\uDC68\uDC69]|\uDC8B\u200D\uD83D[\uDC68\uDC69])\uD83C[\uDFFB-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3]|\uDD1D\u200D\uD83D[\uDC68\uDC69]\uD83C[\uDFFB-\uDFFE]|\uDEEF\u200D\uD83D\uDC69\uD83C[\uDFFB-\uDFFE])))?))?|\uDD75(?:\uD83C[\uDFFB-\uDFFF]|\uFE0F)?(?:\u200D[\u2640\u2642]\uFE0F?)?|\uDE2E(?:\u200D\uD83D\uDCA8)?|\uDE35(?:\u200D\uD83D\uDCAB)?|\uDE36(?:\u200D\uD83C\uDF2B\uFE0F?)?|\uDE42(?:\u200D[\u2194\u2195]\uFE0F?)?|\uDEB6(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?)|\uD83E(?:[\uDD0C\uDD0F\uDD18-\uDD1F\uDD30-\uDD34\uDD36\uDD77\uDDB5\uDDB6\uDDBB\uDDD2\uDDD3\uDDD5\uDEC3-\uDEC5\uDEF0\uDEF2-\uDEF8](?:\uD83C[\uDFFB-\uDFFF])?|[\uDD26\uDD35\uDD37-\uDD39\uDD3C-\uDD3E\uDDB8\uDDB9\uDDCD\uDDCF\uDDD4\uDDD6-\uDDDD](?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDDDE\uDDDF](?:\u200D[\u2640\u2642]\uFE0F?)?|[\uDD0D\uDD0E\uDD10-\uDD17\uDD20-\uDD25\uDD27-\uDD2F\uDD3A\uDD3F-\uDD45\uDD47-\uDD76\uDD78-\uDDB4\uDDB7\uDDBA\uDDBC-\uDDCC\uDDD0\uDDE0-\uDDFF\uDE70-\uDE7C\uDE80-\uDE8A\uDE8E-\uDEC2\uDEC6\uDEC8\uDECD-\uDEDC\uDEDF-\uDEEA\uDEEF]|\uDDCE(?:\uD83C[\uDFFB-\uDFFF])?(?:\u200D(?:[\u2640\u2642]\uFE0F?(?:\u200D\u27A1\uFE0F?)?|\u27A1\uFE0F?))?|\uDDD1(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1|\uDDD1\u200D\uD83E\uDDD2(?:\u200D\uD83E\uDDD2)?|\uDDD2(?:\u200D\uD83E\uDDD2)?))|\uD83C(?:\uDFFB(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFC-\uDFFF])))?|\uDFFC(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFD-\uDFFF])))?|\uDFFD(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])))?|\uDFFE(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFD\uDFFF])))?|\uDFFF(?:\u200D(?:[\u2695\u2696\u2708]\uFE0F?|\u2764\uFE0F?\u200D(?:\uD83D\uDC8B\u200D)?\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE]|\uD83C[\uDF3E\uDF73\uDF7C\uDF84\uDF93\uDFA4\uDFA8\uDFEB\uDFED]|\uD83D(?:[\uDCBB\uDCBC\uDD27\uDD2C\uDE80\uDE92]|\uDC30\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])|\uD83E(?:[\uDDAF\uDDBC\uDDBD](?:\u200D\u27A1\uFE0F?)?|[\uDDB0-\uDDB3\uDE70]|\uDD1D\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFF]|\uDEEF\u200D\uD83E\uDDD1\uD83C[\uDFFB-\uDFFE])))?))?|\uDEF1(?:\uD83C(?:\uDFFB(?:\u200D\uD83E\uDEF2\uD83C[\uDFFC-\uDFFF])?|\uDFFC(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFD-\uDFFF])?|\uDFFD(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB\uDFFC\uDFFE\uDFFF])?|\uDFFE(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFD\uDFFF])?|\uDFFF(?:\u200D\uD83E\uDEF2\uD83C[\uDFFB-\uDFFE])?))?)/g;
|
|
2722
|
+
};
|
|
2723
|
+
|
|
2724
|
+
// ../../node_modules/.pnpm/string-width@7.2.0/node_modules/string-width/index.js
|
|
2725
|
+
var segmenter = new Intl.Segmenter();
|
|
2726
|
+
var defaultIgnorableCodePointRegex = new RegExp("^\\p{Default_Ignorable_Code_Point}$", "u");
|
|
2727
|
+
function stringWidth(string, options = {}) {
|
|
2728
|
+
if (typeof string !== "string" || string.length === 0) {
|
|
2729
|
+
return 0;
|
|
2730
|
+
}
|
|
2731
|
+
const {
|
|
2732
|
+
ambiguousIsNarrow = true,
|
|
2733
|
+
countAnsiEscapeCodes = false
|
|
2734
|
+
} = options;
|
|
2735
|
+
if (!countAnsiEscapeCodes) {
|
|
2736
|
+
string = stripAnsi(string);
|
|
2737
|
+
}
|
|
2738
|
+
if (string.length === 0) {
|
|
2739
|
+
return 0;
|
|
2740
|
+
}
|
|
2741
|
+
let width = 0;
|
|
2742
|
+
const eastAsianWidthOptions = { ambiguousAsWide: !ambiguousIsNarrow };
|
|
2743
|
+
for (const { segment: character } of segmenter.segment(string)) {
|
|
2744
|
+
const codePoint = character.codePointAt(0);
|
|
2745
|
+
if (codePoint <= 31 || codePoint >= 127 && codePoint <= 159) {
|
|
2746
|
+
continue;
|
|
2747
|
+
}
|
|
2748
|
+
if (codePoint >= 8203 && codePoint <= 8207 || codePoint === 65279) {
|
|
2749
|
+
continue;
|
|
2750
|
+
}
|
|
2751
|
+
if (codePoint >= 768 && codePoint <= 879 || codePoint >= 6832 && codePoint <= 6911 || codePoint >= 7616 && codePoint <= 7679 || codePoint >= 8400 && codePoint <= 8447 || codePoint >= 65056 && codePoint <= 65071) {
|
|
2752
|
+
continue;
|
|
2753
|
+
}
|
|
2754
|
+
if (codePoint >= 55296 && codePoint <= 57343) {
|
|
2755
|
+
continue;
|
|
2756
|
+
}
|
|
2757
|
+
if (codePoint >= 65024 && codePoint <= 65039) {
|
|
2758
|
+
continue;
|
|
2759
|
+
}
|
|
2760
|
+
if (defaultIgnorableCodePointRegex.test(character)) {
|
|
2761
|
+
continue;
|
|
2762
|
+
}
|
|
2763
|
+
if (emoji_regex_default().test(character)) {
|
|
2764
|
+
width += 2;
|
|
2765
|
+
continue;
|
|
2766
|
+
}
|
|
2767
|
+
width += eastAsianWidth(codePoint, eastAsianWidthOptions);
|
|
2768
|
+
}
|
|
2769
|
+
return width;
|
|
2770
|
+
}
|
|
2771
|
+
|
|
2772
|
+
// ../../node_modules/.pnpm/is-interactive@2.0.0/node_modules/is-interactive/index.js
|
|
2773
|
+
function isInteractive({ stream = process.stdout } = {}) {
|
|
2774
|
+
return Boolean(
|
|
2775
|
+
stream && stream.isTTY && process.env.TERM !== "dumb" && !("CI" in process.env)
|
|
2776
|
+
);
|
|
2777
|
+
}
|
|
2778
|
+
|
|
2779
|
+
// ../../node_modules/.pnpm/is-unicode-supported@2.1.0/node_modules/is-unicode-supported/index.js
|
|
2780
|
+
import process7 from "process";
|
|
2781
|
+
function isUnicodeSupported2() {
|
|
2782
|
+
const { env: env2 } = process7;
|
|
2783
|
+
const { TERM, TERM_PROGRAM } = env2;
|
|
2784
|
+
if (process7.platform !== "win32") {
|
|
2785
|
+
return TERM !== "linux";
|
|
2786
|
+
}
|
|
2787
|
+
return Boolean(env2.WT_SESSION) || Boolean(env2.TERMINUS_SUBLIME) || env2.ConEmuTask === "{cmd::Cmder}" || TERM_PROGRAM === "Terminus-Sublime" || TERM_PROGRAM === "vscode" || TERM === "xterm-256color" || TERM === "alacritty" || TERM === "rxvt-unicode" || TERM === "rxvt-unicode-256color" || env2.TERMINAL_EMULATOR === "JetBrains-JediTerm";
|
|
2788
|
+
}
|
|
2789
|
+
|
|
2790
|
+
// ../../node_modules/.pnpm/stdin-discarder@0.2.2/node_modules/stdin-discarder/index.js
|
|
2791
|
+
import process8 from "process";
|
|
2792
|
+
var ASCII_ETX_CODE = 3;
|
|
2793
|
+
var StdinDiscarder = class {
|
|
2794
|
+
#activeCount = 0;
|
|
2795
|
+
start() {
|
|
2796
|
+
this.#activeCount++;
|
|
2797
|
+
if (this.#activeCount === 1) {
|
|
2798
|
+
this.#realStart();
|
|
2799
|
+
}
|
|
2800
|
+
}
|
|
2801
|
+
stop() {
|
|
2802
|
+
if (this.#activeCount <= 0) {
|
|
2803
|
+
throw new Error("`stop` called more times than `start`");
|
|
2804
|
+
}
|
|
2805
|
+
this.#activeCount--;
|
|
2806
|
+
if (this.#activeCount === 0) {
|
|
2807
|
+
this.#realStop();
|
|
2808
|
+
}
|
|
2809
|
+
}
|
|
2810
|
+
#realStart() {
|
|
2811
|
+
if (process8.platform === "win32" || !process8.stdin.isTTY) {
|
|
2812
|
+
return;
|
|
2813
|
+
}
|
|
2814
|
+
process8.stdin.setRawMode(true);
|
|
2815
|
+
process8.stdin.on("data", this.#handleInput);
|
|
2816
|
+
process8.stdin.resume();
|
|
2817
|
+
}
|
|
2818
|
+
#realStop() {
|
|
2819
|
+
if (!process8.stdin.isTTY) {
|
|
2820
|
+
return;
|
|
2821
|
+
}
|
|
2822
|
+
process8.stdin.off("data", this.#handleInput);
|
|
2823
|
+
process8.stdin.pause();
|
|
2824
|
+
process8.stdin.setRawMode(false);
|
|
2825
|
+
}
|
|
2826
|
+
#handleInput(chunk) {
|
|
2827
|
+
if (chunk[0] === ASCII_ETX_CODE) {
|
|
2828
|
+
process8.emit("SIGINT");
|
|
2829
|
+
}
|
|
2830
|
+
}
|
|
2831
|
+
};
|
|
2832
|
+
var stdinDiscarder = new StdinDiscarder();
|
|
2833
|
+
var stdin_discarder_default = stdinDiscarder;
|
|
2834
|
+
|
|
2835
|
+
// ../../node_modules/.pnpm/ora@8.2.0/node_modules/ora/index.js
|
|
2836
|
+
var import_cli_spinners2 = __toESM(require_cli_spinners(), 1);
|
|
2837
|
+
var Ora = class {
|
|
2838
|
+
#linesToClear = 0;
|
|
2839
|
+
#isDiscardingStdin = false;
|
|
2840
|
+
#lineCount = 0;
|
|
2841
|
+
#frameIndex = -1;
|
|
2842
|
+
#lastSpinnerFrameTime = 0;
|
|
2843
|
+
#options;
|
|
2844
|
+
#spinner;
|
|
2845
|
+
#stream;
|
|
2846
|
+
#id;
|
|
2847
|
+
#initialInterval;
|
|
2848
|
+
#isEnabled;
|
|
2849
|
+
#isSilent;
|
|
2850
|
+
#indent;
|
|
2851
|
+
#text;
|
|
2852
|
+
#prefixText;
|
|
2853
|
+
#suffixText;
|
|
2854
|
+
color;
|
|
2855
|
+
constructor(options) {
|
|
2856
|
+
if (typeof options === "string") {
|
|
2857
|
+
options = {
|
|
2858
|
+
text: options
|
|
2859
|
+
};
|
|
2860
|
+
}
|
|
2861
|
+
this.#options = {
|
|
2862
|
+
color: "cyan",
|
|
2863
|
+
stream: process9.stderr,
|
|
2864
|
+
discardStdin: true,
|
|
2865
|
+
hideCursor: true,
|
|
2866
|
+
...options
|
|
2867
|
+
};
|
|
2868
|
+
this.color = this.#options.color;
|
|
2869
|
+
this.spinner = this.#options.spinner;
|
|
2870
|
+
this.#initialInterval = this.#options.interval;
|
|
2871
|
+
this.#stream = this.#options.stream;
|
|
2872
|
+
this.#isEnabled = typeof this.#options.isEnabled === "boolean" ? this.#options.isEnabled : isInteractive({ stream: this.#stream });
|
|
2873
|
+
this.#isSilent = typeof this.#options.isSilent === "boolean" ? this.#options.isSilent : false;
|
|
2874
|
+
this.text = this.#options.text;
|
|
2875
|
+
this.prefixText = this.#options.prefixText;
|
|
2876
|
+
this.suffixText = this.#options.suffixText;
|
|
2877
|
+
this.indent = this.#options.indent;
|
|
2878
|
+
if (process9.env.NODE_ENV === "test") {
|
|
2879
|
+
this._stream = this.#stream;
|
|
2880
|
+
this._isEnabled = this.#isEnabled;
|
|
2881
|
+
Object.defineProperty(this, "_linesToClear", {
|
|
2882
|
+
get() {
|
|
2883
|
+
return this.#linesToClear;
|
|
2884
|
+
},
|
|
2885
|
+
set(newValue) {
|
|
2886
|
+
this.#linesToClear = newValue;
|
|
2887
|
+
}
|
|
2888
|
+
});
|
|
2889
|
+
Object.defineProperty(this, "_frameIndex", {
|
|
2890
|
+
get() {
|
|
2891
|
+
return this.#frameIndex;
|
|
2892
|
+
}
|
|
2893
|
+
});
|
|
2894
|
+
Object.defineProperty(this, "_lineCount", {
|
|
2895
|
+
get() {
|
|
2896
|
+
return this.#lineCount;
|
|
2897
|
+
}
|
|
2898
|
+
});
|
|
2899
|
+
}
|
|
2900
|
+
}
|
|
2901
|
+
get indent() {
|
|
2902
|
+
return this.#indent;
|
|
2903
|
+
}
|
|
2904
|
+
set indent(indent = 0) {
|
|
2905
|
+
if (!(indent >= 0 && Number.isInteger(indent))) {
|
|
2906
|
+
throw new Error("The `indent` option must be an integer from 0 and up");
|
|
2907
|
+
}
|
|
2908
|
+
this.#indent = indent;
|
|
2909
|
+
this.#updateLineCount();
|
|
2910
|
+
}
|
|
2911
|
+
get interval() {
|
|
2912
|
+
return this.#initialInterval ?? this.#spinner.interval ?? 100;
|
|
2913
|
+
}
|
|
2914
|
+
get spinner() {
|
|
2915
|
+
return this.#spinner;
|
|
2916
|
+
}
|
|
2917
|
+
set spinner(spinner) {
|
|
2918
|
+
this.#frameIndex = -1;
|
|
2919
|
+
this.#initialInterval = void 0;
|
|
2920
|
+
if (typeof spinner === "object") {
|
|
2921
|
+
if (spinner.frames === void 0) {
|
|
2922
|
+
throw new Error("The given spinner must have a `frames` property");
|
|
2923
|
+
}
|
|
2924
|
+
this.#spinner = spinner;
|
|
2925
|
+
} else if (!isUnicodeSupported2()) {
|
|
2926
|
+
this.#spinner = import_cli_spinners.default.line;
|
|
2927
|
+
} else if (spinner === void 0) {
|
|
2928
|
+
this.#spinner = import_cli_spinners.default.dots;
|
|
2929
|
+
} else if (spinner !== "default" && import_cli_spinners.default[spinner]) {
|
|
2930
|
+
this.#spinner = import_cli_spinners.default[spinner];
|
|
2931
|
+
} else {
|
|
2932
|
+
throw new Error(`There is no built-in spinner named '${spinner}'. See https://github.com/sindresorhus/cli-spinners/blob/main/spinners.json for a full list.`);
|
|
2933
|
+
}
|
|
2934
|
+
}
|
|
2935
|
+
get text() {
|
|
2936
|
+
return this.#text;
|
|
2937
|
+
}
|
|
2938
|
+
set text(value = "") {
|
|
2939
|
+
this.#text = value;
|
|
2940
|
+
this.#updateLineCount();
|
|
2941
|
+
}
|
|
2942
|
+
get prefixText() {
|
|
2943
|
+
return this.#prefixText;
|
|
2944
|
+
}
|
|
2945
|
+
set prefixText(value = "") {
|
|
2946
|
+
this.#prefixText = value;
|
|
2947
|
+
this.#updateLineCount();
|
|
2948
|
+
}
|
|
2949
|
+
get suffixText() {
|
|
2950
|
+
return this.#suffixText;
|
|
2951
|
+
}
|
|
2952
|
+
set suffixText(value = "") {
|
|
2953
|
+
this.#suffixText = value;
|
|
2954
|
+
this.#updateLineCount();
|
|
2955
|
+
}
|
|
2956
|
+
get isSpinning() {
|
|
2957
|
+
return this.#id !== void 0;
|
|
2958
|
+
}
|
|
2959
|
+
#getFullPrefixText(prefixText = this.#prefixText, postfix = " ") {
|
|
2960
|
+
if (typeof prefixText === "string" && prefixText !== "") {
|
|
2961
|
+
return prefixText + postfix;
|
|
2962
|
+
}
|
|
2963
|
+
if (typeof prefixText === "function") {
|
|
2964
|
+
return prefixText() + postfix;
|
|
2965
|
+
}
|
|
2966
|
+
return "";
|
|
2967
|
+
}
|
|
2968
|
+
#getFullSuffixText(suffixText = this.#suffixText, prefix = " ") {
|
|
2969
|
+
if (typeof suffixText === "string" && suffixText !== "") {
|
|
2970
|
+
return prefix + suffixText;
|
|
2971
|
+
}
|
|
2972
|
+
if (typeof suffixText === "function") {
|
|
2973
|
+
return prefix + suffixText();
|
|
2974
|
+
}
|
|
2975
|
+
return "";
|
|
2976
|
+
}
|
|
2977
|
+
#updateLineCount() {
|
|
2978
|
+
const columns = this.#stream.columns ?? 80;
|
|
2979
|
+
const fullPrefixText = this.#getFullPrefixText(this.#prefixText, "-");
|
|
2980
|
+
const fullSuffixText = this.#getFullSuffixText(this.#suffixText, "-");
|
|
2981
|
+
const fullText = " ".repeat(this.#indent) + fullPrefixText + "--" + this.#text + "--" + fullSuffixText;
|
|
2982
|
+
this.#lineCount = 0;
|
|
2983
|
+
for (const line of stripAnsi(fullText).split("\n")) {
|
|
2984
|
+
this.#lineCount += Math.max(1, Math.ceil(stringWidth(line, { countAnsiEscapeCodes: true }) / columns));
|
|
2985
|
+
}
|
|
2986
|
+
}
|
|
2987
|
+
get isEnabled() {
|
|
2988
|
+
return this.#isEnabled && !this.#isSilent;
|
|
2989
|
+
}
|
|
2990
|
+
set isEnabled(value) {
|
|
2991
|
+
if (typeof value !== "boolean") {
|
|
2992
|
+
throw new TypeError("The `isEnabled` option must be a boolean");
|
|
2993
|
+
}
|
|
2994
|
+
this.#isEnabled = value;
|
|
2995
|
+
}
|
|
2996
|
+
get isSilent() {
|
|
2997
|
+
return this.#isSilent;
|
|
2998
|
+
}
|
|
2999
|
+
set isSilent(value) {
|
|
3000
|
+
if (typeof value !== "boolean") {
|
|
3001
|
+
throw new TypeError("The `isSilent` option must be a boolean");
|
|
3002
|
+
}
|
|
3003
|
+
this.#isSilent = value;
|
|
3004
|
+
}
|
|
3005
|
+
frame() {
|
|
3006
|
+
const now = Date.now();
|
|
3007
|
+
if (this.#frameIndex === -1 || now - this.#lastSpinnerFrameTime >= this.interval) {
|
|
3008
|
+
this.#frameIndex = ++this.#frameIndex % this.#spinner.frames.length;
|
|
3009
|
+
this.#lastSpinnerFrameTime = now;
|
|
3010
|
+
}
|
|
3011
|
+
const { frames } = this.#spinner;
|
|
3012
|
+
let frame = frames[this.#frameIndex];
|
|
3013
|
+
if (this.color) {
|
|
3014
|
+
frame = source_default[this.color](frame);
|
|
3015
|
+
}
|
|
3016
|
+
const fullPrefixText = typeof this.#prefixText === "string" && this.#prefixText !== "" ? this.#prefixText + " " : "";
|
|
3017
|
+
const fullText = typeof this.text === "string" ? " " + this.text : "";
|
|
3018
|
+
const fullSuffixText = typeof this.#suffixText === "string" && this.#suffixText !== "" ? " " + this.#suffixText : "";
|
|
3019
|
+
return fullPrefixText + frame + fullText + fullSuffixText;
|
|
3020
|
+
}
|
|
3021
|
+
clear() {
|
|
3022
|
+
if (!this.#isEnabled || !this.#stream.isTTY) {
|
|
3023
|
+
return this;
|
|
3024
|
+
}
|
|
3025
|
+
this.#stream.cursorTo(0);
|
|
3026
|
+
for (let index = 0; index < this.#linesToClear; index++) {
|
|
3027
|
+
if (index > 0) {
|
|
3028
|
+
this.#stream.moveCursor(0, -1);
|
|
3029
|
+
}
|
|
3030
|
+
this.#stream.clearLine(1);
|
|
3031
|
+
}
|
|
3032
|
+
if (this.#indent || this.lastIndent !== this.#indent) {
|
|
3033
|
+
this.#stream.cursorTo(this.#indent);
|
|
3034
|
+
}
|
|
3035
|
+
this.lastIndent = this.#indent;
|
|
3036
|
+
this.#linesToClear = 0;
|
|
3037
|
+
return this;
|
|
3038
|
+
}
|
|
3039
|
+
render() {
|
|
3040
|
+
if (this.#isSilent) {
|
|
3041
|
+
return this;
|
|
3042
|
+
}
|
|
3043
|
+
this.clear();
|
|
3044
|
+
this.#stream.write(this.frame());
|
|
3045
|
+
this.#linesToClear = this.#lineCount;
|
|
3046
|
+
return this;
|
|
3047
|
+
}
|
|
3048
|
+
start(text) {
|
|
3049
|
+
if (text) {
|
|
3050
|
+
this.text = text;
|
|
3051
|
+
}
|
|
3052
|
+
if (this.#isSilent) {
|
|
3053
|
+
return this;
|
|
3054
|
+
}
|
|
3055
|
+
if (!this.#isEnabled) {
|
|
3056
|
+
if (this.text) {
|
|
3057
|
+
this.#stream.write(`- ${this.text}
|
|
3058
|
+
`);
|
|
3059
|
+
}
|
|
3060
|
+
return this;
|
|
3061
|
+
}
|
|
3062
|
+
if (this.isSpinning) {
|
|
3063
|
+
return this;
|
|
3064
|
+
}
|
|
3065
|
+
if (this.#options.hideCursor) {
|
|
3066
|
+
cli_cursor_default.hide(this.#stream);
|
|
3067
|
+
}
|
|
3068
|
+
if (this.#options.discardStdin && process9.stdin.isTTY) {
|
|
3069
|
+
this.#isDiscardingStdin = true;
|
|
3070
|
+
stdin_discarder_default.start();
|
|
3071
|
+
}
|
|
3072
|
+
this.render();
|
|
3073
|
+
this.#id = setInterval(this.render.bind(this), this.interval);
|
|
3074
|
+
return this;
|
|
3075
|
+
}
|
|
3076
|
+
stop() {
|
|
3077
|
+
if (!this.#isEnabled) {
|
|
3078
|
+
return this;
|
|
3079
|
+
}
|
|
3080
|
+
clearInterval(this.#id);
|
|
3081
|
+
this.#id = void 0;
|
|
3082
|
+
this.#frameIndex = 0;
|
|
3083
|
+
this.clear();
|
|
3084
|
+
if (this.#options.hideCursor) {
|
|
3085
|
+
cli_cursor_default.show(this.#stream);
|
|
3086
|
+
}
|
|
3087
|
+
if (this.#options.discardStdin && process9.stdin.isTTY && this.#isDiscardingStdin) {
|
|
3088
|
+
stdin_discarder_default.stop();
|
|
3089
|
+
this.#isDiscardingStdin = false;
|
|
3090
|
+
}
|
|
3091
|
+
return this;
|
|
3092
|
+
}
|
|
3093
|
+
succeed(text) {
|
|
3094
|
+
return this.stopAndPersist({ symbol: log_symbols_default.success, text });
|
|
3095
|
+
}
|
|
3096
|
+
fail(text) {
|
|
3097
|
+
return this.stopAndPersist({ symbol: log_symbols_default.error, text });
|
|
3098
|
+
}
|
|
3099
|
+
warn(text) {
|
|
3100
|
+
return this.stopAndPersist({ symbol: log_symbols_default.warning, text });
|
|
3101
|
+
}
|
|
3102
|
+
info(text) {
|
|
3103
|
+
return this.stopAndPersist({ symbol: log_symbols_default.info, text });
|
|
3104
|
+
}
|
|
3105
|
+
stopAndPersist(options = {}) {
|
|
3106
|
+
if (this.#isSilent) {
|
|
3107
|
+
return this;
|
|
3108
|
+
}
|
|
3109
|
+
const prefixText = options.prefixText ?? this.#prefixText;
|
|
3110
|
+
const fullPrefixText = this.#getFullPrefixText(prefixText, " ");
|
|
3111
|
+
const symbolText = options.symbol ?? " ";
|
|
3112
|
+
const text = options.text ?? this.text;
|
|
3113
|
+
const separatorText = symbolText ? " " : "";
|
|
3114
|
+
const fullText = typeof text === "string" ? separatorText + text : "";
|
|
3115
|
+
const suffixText = options.suffixText ?? this.#suffixText;
|
|
3116
|
+
const fullSuffixText = this.#getFullSuffixText(suffixText, " ");
|
|
3117
|
+
const textToWrite = fullPrefixText + symbolText + fullText + fullSuffixText + "\n";
|
|
3118
|
+
this.stop();
|
|
3119
|
+
this.#stream.write(textToWrite);
|
|
3120
|
+
return this;
|
|
3121
|
+
}
|
|
3122
|
+
};
|
|
3123
|
+
function ora(options) {
|
|
3124
|
+
return new Ora(options);
|
|
3125
|
+
}
|
|
3126
|
+
|
|
3127
|
+
// src/commands/templates.ts
|
|
11
3128
|
import prompts from "prompts";
|
|
12
|
-
import chalk from "chalk";
|
|
13
3129
|
|
|
14
3130
|
// src/core/template-manager.ts
|
|
15
3131
|
import { request } from "undici";
|
|
16
3132
|
import {
|
|
17
|
-
existsSync,
|
|
3133
|
+
existsSync as existsSync2,
|
|
18
3134
|
mkdirSync,
|
|
19
|
-
readFileSync,
|
|
3135
|
+
readFileSync as readFileSync3,
|
|
20
3136
|
readdirSync,
|
|
21
3137
|
rmdirSync,
|
|
22
3138
|
unlinkSync,
|
|
@@ -124,10 +3240,10 @@ var TemplateManager = class {
|
|
|
124
3240
|
this.baseDir = baseDir || join(homedir(), ".better-webhook");
|
|
125
3241
|
this.templatesDir = join(this.baseDir, "templates");
|
|
126
3242
|
this.cacheFile = join(this.baseDir, "templates-cache.json");
|
|
127
|
-
if (!
|
|
3243
|
+
if (!existsSync2(this.baseDir)) {
|
|
128
3244
|
mkdirSync(this.baseDir, { recursive: true });
|
|
129
3245
|
}
|
|
130
|
-
if (!
|
|
3246
|
+
if (!existsSync2(this.templatesDir)) {
|
|
131
3247
|
mkdirSync(this.templatesDir, { recursive: true });
|
|
132
3248
|
}
|
|
133
3249
|
}
|
|
@@ -144,9 +3260,9 @@ var TemplateManager = class {
|
|
|
144
3260
|
if (!forceRefresh && this.indexCache) {
|
|
145
3261
|
return this.indexCache;
|
|
146
3262
|
}
|
|
147
|
-
if (!forceRefresh &&
|
|
3263
|
+
if (!forceRefresh && existsSync2(this.cacheFile)) {
|
|
148
3264
|
try {
|
|
149
|
-
const cached = JSON.parse(
|
|
3265
|
+
const cached = JSON.parse(readFileSync3(this.cacheFile, "utf-8"));
|
|
150
3266
|
const cacheAge = Date.now() - (cached.cachedAt || 0);
|
|
151
3267
|
if (cacheAge < 36e5) {
|
|
152
3268
|
this.indexCache = cached.index;
|
|
@@ -170,9 +3286,9 @@ var TemplateManager = class {
|
|
|
170
3286
|
);
|
|
171
3287
|
return index;
|
|
172
3288
|
} catch (error) {
|
|
173
|
-
if (
|
|
3289
|
+
if (existsSync2(this.cacheFile)) {
|
|
174
3290
|
try {
|
|
175
|
-
const cached = JSON.parse(
|
|
3291
|
+
const cached = JSON.parse(readFileSync3(this.cacheFile, "utf-8"));
|
|
176
3292
|
if (cached.index) {
|
|
177
3293
|
this.indexCache = cached.index;
|
|
178
3294
|
return cached.index;
|
|
@@ -213,7 +3329,7 @@ var TemplateManager = class {
|
|
|
213
3329
|
const json = JSON.parse(text);
|
|
214
3330
|
const template = WebhookTemplateSchema.parse(json);
|
|
215
3331
|
const providerDir = join(this.templatesDir, templateMeta.provider);
|
|
216
|
-
if (!
|
|
3332
|
+
if (!existsSync2(providerDir)) {
|
|
217
3333
|
mkdirSync(providerDir, { recursive: true });
|
|
218
3334
|
}
|
|
219
3335
|
const fileName = `${templateId}.json`;
|
|
@@ -245,7 +3361,7 @@ var TemplateManager = class {
|
|
|
245
3361
|
*/
|
|
246
3362
|
listLocalTemplates() {
|
|
247
3363
|
const templates2 = [];
|
|
248
|
-
if (!
|
|
3364
|
+
if (!existsSync2(this.templatesDir)) {
|
|
249
3365
|
return templates2;
|
|
250
3366
|
}
|
|
251
3367
|
const scanDir = (dir) => {
|
|
@@ -256,7 +3372,7 @@ var TemplateManager = class {
|
|
|
256
3372
|
scanDir(fullPath);
|
|
257
3373
|
} else if (entry.isFile() && entry.name.endsWith(".json")) {
|
|
258
3374
|
try {
|
|
259
|
-
const content = JSON.parse(
|
|
3375
|
+
const content = JSON.parse(readFileSync3(fullPath, "utf-8"));
|
|
260
3376
|
const metadata = content._metadata;
|
|
261
3377
|
if (metadata) {
|
|
262
3378
|
const { _metadata, ...templateData } = content;
|
|
@@ -333,7 +3449,7 @@ var TemplateManager = class {
|
|
|
333
3449
|
*/
|
|
334
3450
|
clearCache() {
|
|
335
3451
|
this.indexCache = null;
|
|
336
|
-
if (
|
|
3452
|
+
if (existsSync2(this.cacheFile)) {
|
|
337
3453
|
unlinkSync(this.cacheFile);
|
|
338
3454
|
}
|
|
339
3455
|
}
|
|
@@ -351,7 +3467,7 @@ var TemplateManager = class {
|
|
|
351
3467
|
} catch {
|
|
352
3468
|
}
|
|
353
3469
|
}
|
|
354
|
-
if (
|
|
3470
|
+
if (existsSync2(this.templatesDir)) {
|
|
355
3471
|
const entries = readdirSync(this.templatesDir, { withFileTypes: true });
|
|
356
3472
|
for (const entry of entries) {
|
|
357
3473
|
if (entry.isDirectory()) {
|
|
@@ -410,7 +3526,7 @@ var TemplateManager = class {
|
|
|
410
3526
|
);
|
|
411
3527
|
}
|
|
412
3528
|
const providerDir = join(this.templatesDir, provider);
|
|
413
|
-
if (!
|
|
3529
|
+
if (!existsSync2(providerDir)) {
|
|
414
3530
|
mkdirSync(providerDir, { recursive: true });
|
|
415
3531
|
}
|
|
416
3532
|
const metadata = {
|
|
@@ -460,7 +3576,7 @@ var listCommand = new Command().name("list").alias("ls").description("List avail
|
|
|
460
3576
|
});
|
|
461
3577
|
spinner.stop();
|
|
462
3578
|
if (templates2.length === 0) {
|
|
463
|
-
console.log(
|
|
3579
|
+
console.log(source_default.yellow("\u{1F4ED} No remote templates found."));
|
|
464
3580
|
return;
|
|
465
3581
|
}
|
|
466
3582
|
let filtered = templates2;
|
|
@@ -471,13 +3587,13 @@ var listCommand = new Command().name("list").alias("ls").description("List avail
|
|
|
471
3587
|
}
|
|
472
3588
|
if (filtered.length === 0) {
|
|
473
3589
|
console.log(
|
|
474
|
-
|
|
3590
|
+
source_default.yellow(
|
|
475
3591
|
`\u{1F4ED} No templates found for provider: ${options.provider}`
|
|
476
3592
|
)
|
|
477
3593
|
);
|
|
478
3594
|
return;
|
|
479
3595
|
}
|
|
480
|
-
console.log(
|
|
3596
|
+
console.log(source_default.bold("\n\u{1F4E6} Available Templates\n"));
|
|
481
3597
|
const byProvider = /* @__PURE__ */ new Map();
|
|
482
3598
|
for (const t of filtered) {
|
|
483
3599
|
const provider = t.metadata.provider;
|
|
@@ -487,24 +3603,24 @@ var listCommand = new Command().name("list").alias("ls").description("List avail
|
|
|
487
3603
|
byProvider.get(provider).push(t);
|
|
488
3604
|
}
|
|
489
3605
|
for (const [provider, providerTemplates] of byProvider) {
|
|
490
|
-
console.log(
|
|
3606
|
+
console.log(source_default.cyan.bold(` ${provider.toUpperCase()}`));
|
|
491
3607
|
for (const t of providerTemplates) {
|
|
492
|
-
const status = t.isDownloaded ?
|
|
493
|
-
console.log(` ${
|
|
3608
|
+
const status = t.isDownloaded ? source_default.green("\u2713 downloaded") : source_default.gray("\u25CB remote");
|
|
3609
|
+
console.log(` ${source_default.white(t.metadata.id)} ${status}`);
|
|
494
3610
|
if (t.metadata.description) {
|
|
495
|
-
console.log(
|
|
3611
|
+
console.log(source_default.gray(` ${t.metadata.description}`));
|
|
496
3612
|
}
|
|
497
3613
|
}
|
|
498
3614
|
console.log();
|
|
499
3615
|
}
|
|
500
|
-
console.log(
|
|
3616
|
+
console.log(source_default.gray(` Total: ${filtered.length} templates`));
|
|
501
3617
|
console.log(
|
|
502
|
-
|
|
3618
|
+
source_default.gray(` Download: better-webhook templates download <id>
|
|
503
3619
|
`)
|
|
504
3620
|
);
|
|
505
3621
|
} catch (error) {
|
|
506
3622
|
spinner.fail("Failed to fetch templates");
|
|
507
|
-
console.error(
|
|
3623
|
+
console.error(source_default.red(error.message));
|
|
508
3624
|
process.exitCode = 1;
|
|
509
3625
|
}
|
|
510
3626
|
});
|
|
@@ -520,11 +3636,11 @@ var downloadCommand = new Command().name("download").alias("get").argument("[tem
|
|
|
520
3636
|
const toDownload = templates2.filter((t) => !t.isDownloaded);
|
|
521
3637
|
spinner2.stop();
|
|
522
3638
|
if (toDownload.length === 0) {
|
|
523
|
-
console.log(
|
|
3639
|
+
console.log(source_default.green("\u2713 All templates already downloaded"));
|
|
524
3640
|
return;
|
|
525
3641
|
}
|
|
526
3642
|
console.log(
|
|
527
|
-
|
|
3643
|
+
source_default.bold(`
|
|
528
3644
|
Downloading ${toDownload.length} templates...
|
|
529
3645
|
`)
|
|
530
3646
|
);
|
|
@@ -541,10 +3657,10 @@ Downloading ${toDownload.length} templates...
|
|
|
541
3657
|
);
|
|
542
3658
|
}
|
|
543
3659
|
}
|
|
544
|
-
console.log(
|
|
3660
|
+
console.log(source_default.green("\n\u2713 Download complete\n"));
|
|
545
3661
|
} catch (error) {
|
|
546
3662
|
spinner2.fail("Failed to fetch templates");
|
|
547
|
-
console.error(
|
|
3663
|
+
console.error(source_default.red(error.message));
|
|
548
3664
|
process.exitCode = 1;
|
|
549
3665
|
}
|
|
550
3666
|
return;
|
|
@@ -558,7 +3674,7 @@ Downloading ${toDownload.length} templates...
|
|
|
558
3674
|
spinner2.stop();
|
|
559
3675
|
const notDownloaded = templates2.filter((t) => !t.isDownloaded);
|
|
560
3676
|
if (notDownloaded.length === 0) {
|
|
561
|
-
console.log(
|
|
3677
|
+
console.log(source_default.green("\u2713 All templates already downloaded"));
|
|
562
3678
|
return;
|
|
563
3679
|
}
|
|
564
3680
|
const choices = notDownloaded.map((t) => ({
|
|
@@ -573,13 +3689,13 @@ Downloading ${toDownload.length} templates...
|
|
|
573
3689
|
choices
|
|
574
3690
|
});
|
|
575
3691
|
if (!response.templateId) {
|
|
576
|
-
console.log(
|
|
3692
|
+
console.log(source_default.yellow("Cancelled"));
|
|
577
3693
|
return;
|
|
578
3694
|
}
|
|
579
3695
|
templateId = response.templateId;
|
|
580
3696
|
} catch (error) {
|
|
581
3697
|
spinner2.fail("Failed to fetch templates");
|
|
582
|
-
console.error(
|
|
3698
|
+
console.error(source_default.red(error.message));
|
|
583
3699
|
process.exitCode = 1;
|
|
584
3700
|
return;
|
|
585
3701
|
}
|
|
@@ -588,14 +3704,14 @@ Downloading ${toDownload.length} templates...
|
|
|
588
3704
|
try {
|
|
589
3705
|
const template = await manager.downloadTemplate(templateId);
|
|
590
3706
|
spinner.succeed(`Downloaded ${templateId}`);
|
|
591
|
-
console.log(
|
|
3707
|
+
console.log(source_default.gray(` Saved to: ${template.filePath}`));
|
|
592
3708
|
console.log(
|
|
593
|
-
|
|
3709
|
+
source_default.gray(` Run with: better-webhook run ${templateId}
|
|
594
3710
|
`)
|
|
595
3711
|
);
|
|
596
3712
|
} catch (error) {
|
|
597
3713
|
spinner.fail(`Failed to download ${templateId}`);
|
|
598
|
-
console.error(
|
|
3714
|
+
console.error(source_default.red(error.message));
|
|
599
3715
|
process.exitCode = 1;
|
|
600
3716
|
}
|
|
601
3717
|
}
|
|
@@ -609,15 +3725,15 @@ var localCommand = new Command().name("local").description("List downloaded loca
|
|
|
609
3725
|
);
|
|
610
3726
|
}
|
|
611
3727
|
if (templates2.length === 0) {
|
|
612
|
-
console.log(
|
|
3728
|
+
console.log(source_default.yellow("\n\u{1F4ED} No local templates found."));
|
|
613
3729
|
console.log(
|
|
614
|
-
|
|
3730
|
+
source_default.gray(
|
|
615
3731
|
" Download templates with: better-webhook templates download\n"
|
|
616
3732
|
)
|
|
617
3733
|
);
|
|
618
3734
|
return;
|
|
619
3735
|
}
|
|
620
|
-
console.log(
|
|
3736
|
+
console.log(source_default.bold("\n\u{1F4C1} Local Templates\n"));
|
|
621
3737
|
const byProvider = /* @__PURE__ */ new Map();
|
|
622
3738
|
for (const t of templates2) {
|
|
623
3739
|
const provider = t.metadata.provider;
|
|
@@ -627,20 +3743,20 @@ var localCommand = new Command().name("local").description("List downloaded loca
|
|
|
627
3743
|
byProvider.get(provider).push(t);
|
|
628
3744
|
}
|
|
629
3745
|
for (const [provider, providerTemplates] of byProvider) {
|
|
630
|
-
console.log(
|
|
3746
|
+
console.log(source_default.cyan.bold(` ${provider.toUpperCase()}`));
|
|
631
3747
|
for (const t of providerTemplates) {
|
|
632
|
-
console.log(` ${
|
|
633
|
-
console.log(
|
|
3748
|
+
console.log(` ${source_default.white(t.id)}`);
|
|
3749
|
+
console.log(source_default.gray(` Event: ${t.metadata.event}`));
|
|
634
3750
|
console.log(
|
|
635
|
-
|
|
3751
|
+
source_default.gray(
|
|
636
3752
|
` Downloaded: ${new Date(t.downloadedAt).toLocaleDateString()}`
|
|
637
3753
|
)
|
|
638
3754
|
);
|
|
639
3755
|
}
|
|
640
3756
|
console.log();
|
|
641
3757
|
}
|
|
642
|
-
console.log(
|
|
643
|
-
console.log(
|
|
3758
|
+
console.log(source_default.gray(` Total: ${templates2.length} templates`));
|
|
3759
|
+
console.log(source_default.gray(` Storage: ${manager.getTemplatesDir()}
|
|
644
3760
|
`));
|
|
645
3761
|
});
|
|
646
3762
|
var searchCommand = new Command().name("search").argument("<query>", "Search query").description("Search templates by name, provider, or event").action(async (query) => {
|
|
@@ -651,38 +3767,38 @@ var searchCommand = new Command().name("search").argument("<query>", "Search que
|
|
|
651
3767
|
spinner.stop();
|
|
652
3768
|
const totalCount = results.remote.length + results.local.length;
|
|
653
3769
|
if (totalCount === 0) {
|
|
654
|
-
console.log(
|
|
3770
|
+
console.log(source_default.yellow(`
|
|
655
3771
|
\u{1F4ED} No templates found for: "${query}"
|
|
656
3772
|
`));
|
|
657
3773
|
return;
|
|
658
3774
|
}
|
|
659
|
-
console.log(
|
|
3775
|
+
console.log(source_default.bold(`
|
|
660
3776
|
\u{1F50D} Search Results for "${query}"
|
|
661
3777
|
`));
|
|
662
3778
|
if (results.local.length > 0) {
|
|
663
|
-
console.log(
|
|
3779
|
+
console.log(source_default.cyan.bold(" LOCAL TEMPLATES"));
|
|
664
3780
|
for (const t of results.local) {
|
|
665
3781
|
console.log(
|
|
666
|
-
` ${
|
|
3782
|
+
` ${source_default.green("\u2713")} ${t.id} (${t.metadata.provider})`
|
|
667
3783
|
);
|
|
668
3784
|
}
|
|
669
3785
|
console.log();
|
|
670
3786
|
}
|
|
671
3787
|
if (results.remote.length > 0) {
|
|
672
|
-
console.log(
|
|
3788
|
+
console.log(source_default.cyan.bold(" REMOTE TEMPLATES"));
|
|
673
3789
|
for (const t of results.remote) {
|
|
674
|
-
const status = t.isDownloaded ?
|
|
3790
|
+
const status = t.isDownloaded ? source_default.green("\u2713") : source_default.gray("\u25CB");
|
|
675
3791
|
console.log(
|
|
676
3792
|
` ${status} ${t.metadata.id} (${t.metadata.provider})`
|
|
677
3793
|
);
|
|
678
3794
|
}
|
|
679
3795
|
console.log();
|
|
680
3796
|
}
|
|
681
|
-
console.log(
|
|
3797
|
+
console.log(source_default.gray(` Found: ${totalCount} templates
|
|
682
3798
|
`));
|
|
683
3799
|
} catch (error) {
|
|
684
3800
|
spinner.fail("Search failed");
|
|
685
|
-
console.error(
|
|
3801
|
+
console.error(source_default.red(error.message));
|
|
686
3802
|
process.exitCode = 1;
|
|
687
3803
|
}
|
|
688
3804
|
});
|
|
@@ -690,7 +3806,7 @@ var cacheCommand = new Command().name("cache").description("Manage template cach
|
|
|
690
3806
|
if (options.clear) {
|
|
691
3807
|
const manager = getTemplateManager();
|
|
692
3808
|
manager.clearCache();
|
|
693
|
-
console.log(
|
|
3809
|
+
console.log(source_default.green("\u2713 Template cache cleared"));
|
|
694
3810
|
} else {
|
|
695
3811
|
console.log("Use --clear to clear the template cache");
|
|
696
3812
|
}
|
|
@@ -699,16 +3815,16 @@ var cleanCommand = new Command().name("clean").alias("remove-all").description("
|
|
|
699
3815
|
const manager = getTemplateManager();
|
|
700
3816
|
const templates2 = manager.listLocalTemplates();
|
|
701
3817
|
if (templates2.length === 0) {
|
|
702
|
-
console.log(
|
|
3818
|
+
console.log(source_default.yellow("\n\u{1F4ED} No local templates to remove.\n"));
|
|
703
3819
|
return;
|
|
704
3820
|
}
|
|
705
3821
|
console.log(
|
|
706
|
-
|
|
3822
|
+
source_default.bold(`
|
|
707
3823
|
\u{1F5D1}\uFE0F Found ${templates2.length} downloaded template(s)
|
|
708
3824
|
`)
|
|
709
3825
|
);
|
|
710
3826
|
for (const t of templates2) {
|
|
711
|
-
console.log(
|
|
3827
|
+
console.log(source_default.gray(` ${t.id} (${t.metadata.provider})`));
|
|
712
3828
|
}
|
|
713
3829
|
console.log();
|
|
714
3830
|
if (!options.force) {
|
|
@@ -719,23 +3835,21 @@ var cleanCommand = new Command().name("clean").alias("remove-all").description("
|
|
|
719
3835
|
initial: false
|
|
720
3836
|
});
|
|
721
3837
|
if (!response.confirm) {
|
|
722
|
-
console.log(
|
|
3838
|
+
console.log(source_default.yellow("Cancelled"));
|
|
723
3839
|
return;
|
|
724
3840
|
}
|
|
725
3841
|
}
|
|
726
3842
|
const deleted = manager.deleteAllLocalTemplates();
|
|
727
|
-
console.log(
|
|
3843
|
+
console.log(source_default.green(`
|
|
728
3844
|
\u2713 Removed ${deleted} template(s)`));
|
|
729
|
-
console.log(
|
|
3845
|
+
console.log(source_default.gray(` Storage: ${manager.getTemplatesDir()}
|
|
730
3846
|
`));
|
|
731
3847
|
});
|
|
732
3848
|
var templates = new Command().name("templates").alias("t").description("Manage webhook templates").addCommand(listCommand).addCommand(downloadCommand).addCommand(localCommand).addCommand(searchCommand).addCommand(cacheCommand).addCommand(cleanCommand);
|
|
733
3849
|
|
|
734
3850
|
// src/commands/run.ts
|
|
735
3851
|
import { Command as Command2 } from "commander";
|
|
736
|
-
import ora2 from "ora";
|
|
737
3852
|
import prompts2 from "prompts";
|
|
738
|
-
import chalk2 from "chalk";
|
|
739
3853
|
|
|
740
3854
|
// src/core/executor.ts
|
|
741
3855
|
import { request as request2 } from "undici";
|
|
@@ -1113,15 +4227,15 @@ var run = new Command2().name("run").argument("[templateId]", "Template ID to ru
|
|
|
1113
4227
|
async (templateId, options) => {
|
|
1114
4228
|
const manager = getTemplateManager();
|
|
1115
4229
|
if (!templateId) {
|
|
1116
|
-
const spinner2 =
|
|
4230
|
+
const spinner2 = ora("Loading templates...").start();
|
|
1117
4231
|
try {
|
|
1118
4232
|
const local = manager.listLocalTemplates();
|
|
1119
4233
|
const remote = await manager.listRemoteTemplates();
|
|
1120
4234
|
spinner2.stop();
|
|
1121
4235
|
if (local.length === 0 && remote.length === 0) {
|
|
1122
|
-
console.log(
|
|
4236
|
+
console.log(source_default.yellow("\n\u{1F4ED} No templates available."));
|
|
1123
4237
|
console.log(
|
|
1124
|
-
|
|
4238
|
+
source_default.gray(
|
|
1125
4239
|
" Download templates with: better-webhook templates download\n"
|
|
1126
4240
|
)
|
|
1127
4241
|
);
|
|
@@ -1131,7 +4245,7 @@ var run = new Command2().name("run").argument("[templateId]", "Template ID to ru
|
|
|
1131
4245
|
if (local.length > 0) {
|
|
1132
4246
|
for (const t of local) {
|
|
1133
4247
|
choices.push({
|
|
1134
|
-
title: `${t.id} ${
|
|
4248
|
+
title: `${t.id} ${source_default.green("(local)")}`,
|
|
1135
4249
|
description: `${t.metadata.provider} - ${t.metadata.event}`,
|
|
1136
4250
|
value: t.id
|
|
1137
4251
|
});
|
|
@@ -1140,7 +4254,7 @@ var run = new Command2().name("run").argument("[templateId]", "Template ID to ru
|
|
|
1140
4254
|
const remoteOnly = remote.filter((t) => !t.isDownloaded);
|
|
1141
4255
|
for (const t of remoteOnly) {
|
|
1142
4256
|
choices.push({
|
|
1143
|
-
title: `${t.metadata.id} ${
|
|
4257
|
+
title: `${t.metadata.id} ${source_default.gray("(remote)")}`,
|
|
1144
4258
|
description: `${t.metadata.provider} - ${t.metadata.event}`,
|
|
1145
4259
|
value: `remote:${t.metadata.id}`
|
|
1146
4260
|
});
|
|
@@ -1152,20 +4266,20 @@ var run = new Command2().name("run").argument("[templateId]", "Template ID to ru
|
|
|
1152
4266
|
choices
|
|
1153
4267
|
});
|
|
1154
4268
|
if (!response.templateId) {
|
|
1155
|
-
console.log(
|
|
4269
|
+
console.log(source_default.yellow("Cancelled"));
|
|
1156
4270
|
return;
|
|
1157
4271
|
}
|
|
1158
4272
|
templateId = response.templateId;
|
|
1159
4273
|
} catch (error) {
|
|
1160
4274
|
spinner2.fail("Failed to load templates");
|
|
1161
|
-
console.error(
|
|
4275
|
+
console.error(source_default.red(error.message));
|
|
1162
4276
|
process.exitCode = 1;
|
|
1163
4277
|
return;
|
|
1164
4278
|
}
|
|
1165
4279
|
}
|
|
1166
4280
|
if (templateId?.startsWith("remote:")) {
|
|
1167
4281
|
const remoteId = templateId.replace("remote:", "");
|
|
1168
|
-
const downloadSpinner =
|
|
4282
|
+
const downloadSpinner = ora(`Downloading ${remoteId}...`).start();
|
|
1169
4283
|
try {
|
|
1170
4284
|
await manager.downloadTemplate(remoteId);
|
|
1171
4285
|
downloadSpinner.succeed(`Downloaded ${remoteId}`);
|
|
@@ -1178,10 +4292,10 @@ var run = new Command2().name("run").argument("[templateId]", "Template ID to ru
|
|
|
1178
4292
|
}
|
|
1179
4293
|
const localTemplate = manager.getLocalTemplate(templateId);
|
|
1180
4294
|
if (!localTemplate) {
|
|
1181
|
-
console.log(
|
|
4295
|
+
console.log(source_default.red(`
|
|
1182
4296
|
\u274C Template not found: ${templateId}`));
|
|
1183
4297
|
console.log(
|
|
1184
|
-
|
|
4298
|
+
source_default.gray(
|
|
1185
4299
|
" Download it with: better-webhook templates download " + templateId + "\n"
|
|
1186
4300
|
)
|
|
1187
4301
|
);
|
|
@@ -1194,24 +4308,24 @@ var run = new Command2().name("run").argument("[templateId]", "Template ID to ru
|
|
|
1194
4308
|
const envVarName = getSecretEnvVarName(localTemplate.metadata.provider);
|
|
1195
4309
|
secret = process.env[envVarName];
|
|
1196
4310
|
}
|
|
1197
|
-
console.log(
|
|
1198
|
-
console.log(
|
|
4311
|
+
console.log(source_default.bold("\n\u{1F680} Executing Webhook\n"));
|
|
4312
|
+
console.log(source_default.gray(` Template: ${templateId}`));
|
|
1199
4313
|
console.log(
|
|
1200
|
-
|
|
4314
|
+
source_default.gray(` Provider: ${localTemplate.metadata.provider}`)
|
|
1201
4315
|
);
|
|
1202
|
-
console.log(
|
|
1203
|
-
console.log(
|
|
4316
|
+
console.log(source_default.gray(` Event: ${localTemplate.metadata.event}`));
|
|
4317
|
+
console.log(source_default.gray(` Target: ${targetUrl}`));
|
|
1204
4318
|
if (secret) {
|
|
1205
|
-
console.log(
|
|
4319
|
+
console.log(source_default.gray(` Signature: Will be generated`));
|
|
1206
4320
|
} else {
|
|
1207
4321
|
console.log(
|
|
1208
|
-
|
|
4322
|
+
source_default.yellow(
|
|
1209
4323
|
` \u26A0\uFE0F No secret provided - signature will not be generated`
|
|
1210
4324
|
)
|
|
1211
4325
|
);
|
|
1212
4326
|
}
|
|
1213
4327
|
console.log();
|
|
1214
|
-
const spinner =
|
|
4328
|
+
const spinner = ora("Sending webhook...").start();
|
|
1215
4329
|
try {
|
|
1216
4330
|
const result = await executeTemplate(localTemplate.template, {
|
|
1217
4331
|
url: targetUrl,
|
|
@@ -1219,43 +4333,43 @@ var run = new Command2().name("run").argument("[templateId]", "Template ID to ru
|
|
|
1219
4333
|
headers: options?.header
|
|
1220
4334
|
});
|
|
1221
4335
|
spinner.stop();
|
|
1222
|
-
const statusColor = result.status >= 200 && result.status < 300 ?
|
|
1223
|
-
console.log(
|
|
4336
|
+
const statusColor = result.status >= 200 && result.status < 300 ? source_default.green : result.status >= 400 ? source_default.red : source_default.yellow;
|
|
4337
|
+
console.log(source_default.bold("\u{1F4E5} Response\n"));
|
|
1224
4338
|
console.log(
|
|
1225
4339
|
` Status: ${statusColor(`${result.status} ${result.statusText}`)}`
|
|
1226
4340
|
);
|
|
1227
|
-
console.log(` Duration: ${
|
|
4341
|
+
console.log(` Duration: ${source_default.cyan(`${result.duration}ms`)}`);
|
|
1228
4342
|
if (options?.verbose) {
|
|
1229
|
-
console.log(
|
|
4343
|
+
console.log(source_default.bold("\n Headers:"));
|
|
1230
4344
|
for (const [key, value] of Object.entries(result.headers)) {
|
|
1231
4345
|
const headerValue = Array.isArray(value) ? value.join(", ") : value;
|
|
1232
|
-
console.log(
|
|
4346
|
+
console.log(source_default.gray(` ${key}: ${headerValue}`));
|
|
1233
4347
|
}
|
|
1234
4348
|
}
|
|
1235
4349
|
if (result.json !== void 0) {
|
|
1236
|
-
console.log(
|
|
4350
|
+
console.log(source_default.bold("\n Body:"));
|
|
1237
4351
|
console.log(
|
|
1238
|
-
|
|
4352
|
+
source_default.gray(
|
|
1239
4353
|
JSON.stringify(result.json, null, 2).split("\n").map((l) => ` ${l}`).join("\n")
|
|
1240
4354
|
)
|
|
1241
4355
|
);
|
|
1242
4356
|
} else if (result.bodyText) {
|
|
1243
|
-
console.log(
|
|
4357
|
+
console.log(source_default.bold("\n Body:"));
|
|
1244
4358
|
const preview = result.bodyText.length > 500 ? result.bodyText.slice(0, 500) + "..." : result.bodyText;
|
|
1245
|
-
console.log(
|
|
4359
|
+
console.log(source_default.gray(` ${preview}`));
|
|
1246
4360
|
}
|
|
1247
4361
|
console.log();
|
|
1248
4362
|
if (result.status >= 200 && result.status < 300) {
|
|
1249
|
-
console.log(
|
|
4363
|
+
console.log(source_default.green("\u2713 Webhook delivered successfully\n"));
|
|
1250
4364
|
} else {
|
|
1251
4365
|
console.log(
|
|
1252
|
-
|
|
4366
|
+
source_default.yellow(`\u26A0 Webhook delivered with status ${result.status}
|
|
1253
4367
|
`)
|
|
1254
4368
|
);
|
|
1255
4369
|
}
|
|
1256
4370
|
} catch (error) {
|
|
1257
4371
|
spinner.fail("Request failed");
|
|
1258
|
-
console.error(
|
|
4372
|
+
console.error(source_default.red(`
|
|
1259
4373
|
\u274C ${error.message}
|
|
1260
4374
|
`));
|
|
1261
4375
|
process.exitCode = 1;
|
|
@@ -1265,7 +4379,6 @@ var run = new Command2().name("run").argument("[templateId]", "Template ID to ru
|
|
|
1265
4379
|
|
|
1266
4380
|
// src/commands/capture.ts
|
|
1267
4381
|
import { Command as Command3 } from "commander";
|
|
1268
|
-
import chalk3 from "chalk";
|
|
1269
4382
|
|
|
1270
4383
|
// src/core/capture-server.ts
|
|
1271
4384
|
import {
|
|
@@ -1275,9 +4388,9 @@ import { WebSocketServer } from "ws";
|
|
|
1275
4388
|
import {
|
|
1276
4389
|
writeFileSync as writeFileSync2,
|
|
1277
4390
|
mkdirSync as mkdirSync2,
|
|
1278
|
-
existsSync as
|
|
4391
|
+
existsSync as existsSync3,
|
|
1279
4392
|
readdirSync as readdirSync2,
|
|
1280
|
-
readFileSync as
|
|
4393
|
+
readFileSync as readFileSync4,
|
|
1281
4394
|
unlinkSync as unlinkSync2
|
|
1282
4395
|
} from "fs";
|
|
1283
4396
|
import { join as join2 } from "path";
|
|
@@ -1298,7 +4411,7 @@ var CaptureServer = class {
|
|
|
1298
4411
|
this.enableWebSocket = typeof options === "object" ? options?.enableWebSocket !== false : true;
|
|
1299
4412
|
this.onCapture = typeof options === "object" ? options?.onCapture : void 0;
|
|
1300
4413
|
this.verbose = typeof options === "object" ? options?.verbose === true : false;
|
|
1301
|
-
if (!
|
|
4414
|
+
if (!existsSync3(this.capturesDir)) {
|
|
1302
4415
|
mkdirSync2(this.capturesDir, { recursive: true });
|
|
1303
4416
|
}
|
|
1304
4417
|
}
|
|
@@ -1579,14 +4692,14 @@ var CaptureServer = class {
|
|
|
1579
4692
|
* List all captured webhooks
|
|
1580
4693
|
*/
|
|
1581
4694
|
listCaptures(limit = 100) {
|
|
1582
|
-
if (!
|
|
4695
|
+
if (!existsSync3(this.capturesDir)) {
|
|
1583
4696
|
return [];
|
|
1584
4697
|
}
|
|
1585
4698
|
const files = readdirSync2(this.capturesDir).filter((f) => f.endsWith(".json")).sort().reverse().slice(0, limit);
|
|
1586
4699
|
const captures2 = [];
|
|
1587
4700
|
for (const file of files) {
|
|
1588
4701
|
try {
|
|
1589
|
-
const content =
|
|
4702
|
+
const content = readFileSync4(join2(this.capturesDir, file), "utf-8");
|
|
1590
4703
|
const capture2 = JSON.parse(content);
|
|
1591
4704
|
captures2.push({ file, capture: capture2 });
|
|
1592
4705
|
} catch {
|
|
@@ -1631,7 +4744,7 @@ var capture = new Command3().name("capture").description("Start a server to capt
|
|
|
1631
4744
|
async (options) => {
|
|
1632
4745
|
const port = parseInt(options.port, 10);
|
|
1633
4746
|
if (isNaN(port) || port < 0 || port > 65535) {
|
|
1634
|
-
console.error(
|
|
4747
|
+
console.error(source_default.red("Invalid port number"));
|
|
1635
4748
|
process.exitCode = 1;
|
|
1636
4749
|
return;
|
|
1637
4750
|
}
|
|
@@ -1646,7 +4759,7 @@ var capture = new Command3().name("capture").description("Start a server to capt
|
|
|
1646
4759
|
process.on("SIGINT", shutdown);
|
|
1647
4760
|
process.on("SIGTERM", shutdown);
|
|
1648
4761
|
} catch (error) {
|
|
1649
|
-
console.error(
|
|
4762
|
+
console.error(source_default.red(`Failed to start server: ${error.message}`));
|
|
1650
4763
|
process.exitCode = 1;
|
|
1651
4764
|
}
|
|
1652
4765
|
}
|
|
@@ -1654,12 +4767,11 @@ var capture = new Command3().name("capture").description("Start a server to capt
|
|
|
1654
4767
|
|
|
1655
4768
|
// src/commands/captures.ts
|
|
1656
4769
|
import { Command as Command4 } from "commander";
|
|
1657
|
-
import chalk4 from "chalk";
|
|
1658
4770
|
import prompts3 from "prompts";
|
|
1659
4771
|
import { homedir as homedir4 } from "os";
|
|
1660
4772
|
|
|
1661
4773
|
// src/core/replay-engine.ts
|
|
1662
|
-
import { existsSync as
|
|
4774
|
+
import { existsSync as existsSync4, readFileSync as readFileSync5, readdirSync as readdirSync3, unlinkSync as unlinkSync3 } from "fs";
|
|
1663
4775
|
import { join as join3 } from "path";
|
|
1664
4776
|
import { homedir as homedir3 } from "os";
|
|
1665
4777
|
var ReplayEngine = class {
|
|
@@ -1677,14 +4789,14 @@ var ReplayEngine = class {
|
|
|
1677
4789
|
* List all captured webhooks
|
|
1678
4790
|
*/
|
|
1679
4791
|
listCaptures(limit = 100) {
|
|
1680
|
-
if (!
|
|
4792
|
+
if (!existsSync4(this.capturesDir)) {
|
|
1681
4793
|
return [];
|
|
1682
4794
|
}
|
|
1683
4795
|
const files = readdirSync3(this.capturesDir).filter((f) => f.endsWith(".json")).sort().reverse().slice(0, limit);
|
|
1684
4796
|
const captures2 = [];
|
|
1685
4797
|
for (const file of files) {
|
|
1686
4798
|
try {
|
|
1687
|
-
const content =
|
|
4799
|
+
const content = readFileSync5(join3(this.capturesDir, file), "utf-8");
|
|
1688
4800
|
const capture2 = JSON.parse(content);
|
|
1689
4801
|
captures2.push({ file, capture: capture2 });
|
|
1690
4802
|
} catch {
|
|
@@ -1939,7 +5051,7 @@ var ReplayEngine = class {
|
|
|
1939
5051
|
* @returns Number of captures deleted
|
|
1940
5052
|
*/
|
|
1941
5053
|
deleteAllCaptures() {
|
|
1942
|
-
if (!
|
|
5054
|
+
if (!existsSync4(this.capturesDir)) {
|
|
1943
5055
|
return 0;
|
|
1944
5056
|
}
|
|
1945
5057
|
const files = readdirSync3(this.capturesDir).filter(
|
|
@@ -1975,7 +5087,7 @@ function toRelativePath(absolutePath) {
|
|
|
1975
5087
|
var listCommand2 = new Command4().name("list").alias("ls").description("List captured webhooks").option("-l, --limit <limit>", "Maximum number of captures to show", "20").option("-p, --provider <provider>", "Filter by provider").action((options) => {
|
|
1976
5088
|
const limit = parseInt(options.limit, 10);
|
|
1977
5089
|
if (isNaN(limit) || limit <= 0) {
|
|
1978
|
-
console.error(
|
|
5090
|
+
console.error(source_default.red("Invalid limit value"));
|
|
1979
5091
|
process.exitCode = 1;
|
|
1980
5092
|
return;
|
|
1981
5093
|
}
|
|
@@ -1987,90 +5099,90 @@ var listCommand2 = new Command4().name("list").alias("ls").description("List cap
|
|
|
1987
5099
|
);
|
|
1988
5100
|
}
|
|
1989
5101
|
if (captures2.length === 0) {
|
|
1990
|
-
console.log(
|
|
5102
|
+
console.log(source_default.yellow("\n\u{1F4ED} No captured webhooks found."));
|
|
1991
5103
|
console.log(
|
|
1992
|
-
|
|
5104
|
+
source_default.gray(" Start capturing with: better-webhook capture\n")
|
|
1993
5105
|
);
|
|
1994
5106
|
return;
|
|
1995
5107
|
}
|
|
1996
|
-
console.log(
|
|
5108
|
+
console.log(source_default.bold("\n\u{1F4E6} Captured Webhooks\n"));
|
|
1997
5109
|
for (const { file, capture: capture2 } of captures2) {
|
|
1998
5110
|
const date = new Date(capture2.timestamp).toLocaleString();
|
|
1999
|
-
const provider = capture2.provider ?
|
|
5111
|
+
const provider = capture2.provider ? source_default.cyan(`[${capture2.provider}]`) : source_default.gray("[unknown]");
|
|
2000
5112
|
const size = capture2.contentLength || capture2.rawBody?.length || 0;
|
|
2001
|
-
console.log(` ${
|
|
2002
|
-
console.log(
|
|
2003
|
-
console.log(
|
|
2004
|
-
console.log(
|
|
5113
|
+
console.log(` ${source_default.white(capture2.id.slice(0, 8))} ${provider}`);
|
|
5114
|
+
console.log(source_default.gray(` ${capture2.method} ${capture2.path}`));
|
|
5115
|
+
console.log(source_default.gray(` ${date} | ${size} bytes`));
|
|
5116
|
+
console.log(source_default.gray(` File: ${file}`));
|
|
2005
5117
|
console.log();
|
|
2006
5118
|
}
|
|
2007
|
-
console.log(
|
|
2008
|
-
console.log(
|
|
5119
|
+
console.log(source_default.gray(` Showing ${captures2.length} captures`));
|
|
5120
|
+
console.log(source_default.gray(` Storage: ${engine.getCapturesDir()}
|
|
2009
5121
|
`));
|
|
2010
5122
|
});
|
|
2011
5123
|
var showCommand = new Command4().name("show").argument("<captureId>", "Capture ID or partial ID").description("Show detailed information about a capture").option("-b, --body", "Show full body content").action((captureId, options) => {
|
|
2012
5124
|
const engine = getReplayEngine();
|
|
2013
5125
|
const captureFile = engine.getCapture(captureId);
|
|
2014
5126
|
if (!captureFile) {
|
|
2015
|
-
console.log(
|
|
5127
|
+
console.log(source_default.red(`
|
|
2016
5128
|
\u274C Capture not found: ${captureId}
|
|
2017
5129
|
`));
|
|
2018
5130
|
process.exitCode = 1;
|
|
2019
5131
|
return;
|
|
2020
5132
|
}
|
|
2021
5133
|
const { capture: capture2 } = captureFile;
|
|
2022
|
-
console.log(
|
|
2023
|
-
console.log(` ${
|
|
2024
|
-
console.log(` ${
|
|
5134
|
+
console.log(source_default.bold("\n\u{1F4CB} Capture Details\n"));
|
|
5135
|
+
console.log(` ${source_default.gray("ID:")} ${capture2.id}`);
|
|
5136
|
+
console.log(` ${source_default.gray("File:")} ${captureFile.file}`);
|
|
2025
5137
|
console.log(
|
|
2026
|
-
` ${
|
|
5138
|
+
` ${source_default.gray("Timestamp:")} ${new Date(capture2.timestamp).toLocaleString()}`
|
|
2027
5139
|
);
|
|
2028
|
-
console.log(` ${
|
|
2029
|
-
console.log(` ${
|
|
2030
|
-
console.log(` ${
|
|
5140
|
+
console.log(` ${source_default.gray("Method:")} ${capture2.method}`);
|
|
5141
|
+
console.log(` ${source_default.gray("Path:")} ${capture2.path}`);
|
|
5142
|
+
console.log(` ${source_default.gray("URL:")} ${capture2.url}`);
|
|
2031
5143
|
if (capture2.provider) {
|
|
2032
5144
|
console.log(
|
|
2033
|
-
` ${
|
|
5145
|
+
` ${source_default.gray("Provider:")} ${source_default.cyan(capture2.provider)}`
|
|
2034
5146
|
);
|
|
2035
5147
|
}
|
|
2036
5148
|
console.log(
|
|
2037
|
-
` ${
|
|
5149
|
+
` ${source_default.gray("Content-Type:")} ${capture2.contentType || "unknown"}`
|
|
2038
5150
|
);
|
|
2039
5151
|
console.log(
|
|
2040
|
-
` ${
|
|
5152
|
+
` ${source_default.gray("Content-Length:")} ${capture2.contentLength || 0} bytes`
|
|
2041
5153
|
);
|
|
2042
5154
|
const queryKeys = Object.keys(capture2.query);
|
|
2043
5155
|
if (queryKeys.length > 0) {
|
|
2044
|
-
console.log(
|
|
5156
|
+
console.log(source_default.bold("\n Query Parameters:"));
|
|
2045
5157
|
for (const [key, value] of Object.entries(capture2.query)) {
|
|
2046
5158
|
const queryValue = Array.isArray(value) ? value.join(", ") : value;
|
|
2047
|
-
console.log(
|
|
5159
|
+
console.log(source_default.gray(` ${key}: ${queryValue}`));
|
|
2048
5160
|
}
|
|
2049
5161
|
}
|
|
2050
|
-
console.log(
|
|
5162
|
+
console.log(source_default.bold("\n Headers:"));
|
|
2051
5163
|
for (const [key, value] of Object.entries(capture2.headers)) {
|
|
2052
5164
|
const headerValue = Array.isArray(value) ? value.join(", ") : value;
|
|
2053
5165
|
const display = headerValue.length > 80 ? headerValue.slice(0, 80) + "..." : headerValue;
|
|
2054
|
-
console.log(
|
|
5166
|
+
console.log(source_default.gray(` ${key}: ${display}`));
|
|
2055
5167
|
}
|
|
2056
5168
|
if (options.body && capture2.body) {
|
|
2057
|
-
console.log(
|
|
5169
|
+
console.log(source_default.bold("\n Body:"));
|
|
2058
5170
|
if (typeof capture2.body === "object") {
|
|
2059
5171
|
console.log(
|
|
2060
|
-
|
|
5172
|
+
source_default.gray(
|
|
2061
5173
|
JSON.stringify(capture2.body, null, 2).split("\n").map((l) => ` ${l}`).join("\n")
|
|
2062
5174
|
)
|
|
2063
5175
|
);
|
|
2064
5176
|
} else {
|
|
2065
|
-
console.log(
|
|
5177
|
+
console.log(source_default.gray(` ${capture2.body}`));
|
|
2066
5178
|
}
|
|
2067
5179
|
} else if (capture2.body) {
|
|
2068
|
-
console.log(
|
|
5180
|
+
console.log(source_default.bold("\n Body:"));
|
|
2069
5181
|
const preview = JSON.stringify(capture2.body).slice(0, 200);
|
|
2070
5182
|
console.log(
|
|
2071
|
-
|
|
5183
|
+
source_default.gray(` ${preview}${preview.length >= 200 ? "..." : ""}`)
|
|
2072
5184
|
);
|
|
2073
|
-
console.log(
|
|
5185
|
+
console.log(source_default.gray(" Use --body to see full content"));
|
|
2074
5186
|
}
|
|
2075
5187
|
console.log();
|
|
2076
5188
|
});
|
|
@@ -2078,30 +5190,30 @@ var searchCommand2 = new Command4().name("search").argument("<query>", "Search q
|
|
|
2078
5190
|
const engine = getReplayEngine();
|
|
2079
5191
|
const results = engine.searchCaptures(query);
|
|
2080
5192
|
if (results.length === 0) {
|
|
2081
|
-
console.log(
|
|
5193
|
+
console.log(source_default.yellow(`
|
|
2082
5194
|
\u{1F4ED} No captures found for: "${query}"
|
|
2083
5195
|
`));
|
|
2084
5196
|
return;
|
|
2085
5197
|
}
|
|
2086
|
-
console.log(
|
|
5198
|
+
console.log(source_default.bold(`
|
|
2087
5199
|
\u{1F50D} Search Results for "${query}"
|
|
2088
5200
|
`));
|
|
2089
5201
|
for (const { file, capture: capture2 } of results) {
|
|
2090
5202
|
const date = new Date(capture2.timestamp).toLocaleString();
|
|
2091
|
-
const provider = capture2.provider ?
|
|
2092
|
-
console.log(` ${
|
|
2093
|
-
console.log(
|
|
2094
|
-
console.log(
|
|
5203
|
+
const provider = capture2.provider ? source_default.cyan(`[${capture2.provider}]`) : "";
|
|
5204
|
+
console.log(` ${source_default.white(capture2.id.slice(0, 8))} ${provider}`);
|
|
5205
|
+
console.log(source_default.gray(` ${capture2.method} ${capture2.path}`));
|
|
5206
|
+
console.log(source_default.gray(` ${date}`));
|
|
2095
5207
|
console.log();
|
|
2096
5208
|
}
|
|
2097
|
-
console.log(
|
|
5209
|
+
console.log(source_default.gray(` Found: ${results.length} captures
|
|
2098
5210
|
`));
|
|
2099
5211
|
});
|
|
2100
5212
|
var deleteCommand = new Command4().name("delete").alias("rm").argument("<captureId>", "Capture ID or partial ID to delete").description("Delete a specific captured webhook").option("-f, --force", "Skip confirmation prompt").action(async (captureId, options) => {
|
|
2101
5213
|
const engine = getReplayEngine();
|
|
2102
5214
|
const captureFile = engine.getCapture(captureId);
|
|
2103
5215
|
if (!captureFile) {
|
|
2104
|
-
console.log(
|
|
5216
|
+
console.log(source_default.red(`
|
|
2105
5217
|
\u274C Capture not found: ${captureId}
|
|
2106
5218
|
`));
|
|
2107
5219
|
process.exitCode = 1;
|
|
@@ -2109,11 +5221,11 @@ var deleteCommand = new Command4().name("delete").alias("rm").argument("<capture
|
|
|
2109
5221
|
}
|
|
2110
5222
|
const { capture: capture2 } = captureFile;
|
|
2111
5223
|
if (!options.force) {
|
|
2112
|
-
console.log(
|
|
2113
|
-
console.log(` ${
|
|
2114
|
-
console.log(
|
|
5224
|
+
console.log(source_default.bold("\n\u{1F5D1}\uFE0F Capture to delete:\n"));
|
|
5225
|
+
console.log(` ${source_default.white(capture2.id.slice(0, 8))}`);
|
|
5226
|
+
console.log(source_default.gray(` ${capture2.method} ${capture2.path}`));
|
|
2115
5227
|
console.log(
|
|
2116
|
-
|
|
5228
|
+
source_default.gray(` ${new Date(capture2.timestamp).toLocaleString()}`)
|
|
2117
5229
|
);
|
|
2118
5230
|
console.log();
|
|
2119
5231
|
const response = await prompts3({
|
|
@@ -2123,19 +5235,19 @@ var deleteCommand = new Command4().name("delete").alias("rm").argument("<capture
|
|
|
2123
5235
|
initial: false
|
|
2124
5236
|
});
|
|
2125
5237
|
if (!response.confirm) {
|
|
2126
|
-
console.log(
|
|
5238
|
+
console.log(source_default.yellow("Cancelled"));
|
|
2127
5239
|
return;
|
|
2128
5240
|
}
|
|
2129
5241
|
}
|
|
2130
5242
|
const deleted = engine.deleteCapture(captureId);
|
|
2131
5243
|
if (deleted) {
|
|
2132
5244
|
console.log(
|
|
2133
|
-
|
|
5245
|
+
source_default.green(`
|
|
2134
5246
|
\u2713 Deleted capture: ${capture2.id.slice(0, 8)}
|
|
2135
5247
|
`)
|
|
2136
5248
|
);
|
|
2137
5249
|
} else {
|
|
2138
|
-
console.log(
|
|
5250
|
+
console.log(source_default.red(`
|
|
2139
5251
|
\u274C Failed to delete capture
|
|
2140
5252
|
`));
|
|
2141
5253
|
process.exitCode = 1;
|
|
@@ -2145,11 +5257,11 @@ var cleanCommand2 = new Command4().name("clean").alias("remove-all").description
|
|
|
2145
5257
|
const engine = getReplayEngine();
|
|
2146
5258
|
const captures2 = engine.listCaptures(1e4);
|
|
2147
5259
|
if (captures2.length === 0) {
|
|
2148
|
-
console.log(
|
|
5260
|
+
console.log(source_default.yellow("\n\u{1F4ED} No captures to remove.\n"));
|
|
2149
5261
|
return;
|
|
2150
5262
|
}
|
|
2151
5263
|
console.log(
|
|
2152
|
-
|
|
5264
|
+
source_default.bold(`
|
|
2153
5265
|
\u{1F5D1}\uFE0F Found ${captures2.length} captured webhook(s)
|
|
2154
5266
|
`)
|
|
2155
5267
|
);
|
|
@@ -2159,7 +5271,7 @@ var cleanCommand2 = new Command4().name("clean").alias("remove-all").description
|
|
|
2159
5271
|
byProvider.set(provider, (byProvider.get(provider) || 0) + 1);
|
|
2160
5272
|
}
|
|
2161
5273
|
for (const [provider, count] of byProvider) {
|
|
2162
|
-
console.log(
|
|
5274
|
+
console.log(source_default.gray(` ${provider}: ${count}`));
|
|
2163
5275
|
}
|
|
2164
5276
|
console.log();
|
|
2165
5277
|
if (!options.force) {
|
|
@@ -2170,14 +5282,14 @@ var cleanCommand2 = new Command4().name("clean").alias("remove-all").description
|
|
|
2170
5282
|
initial: false
|
|
2171
5283
|
});
|
|
2172
5284
|
if (!response.confirm) {
|
|
2173
|
-
console.log(
|
|
5285
|
+
console.log(source_default.yellow("Cancelled"));
|
|
2174
5286
|
return;
|
|
2175
5287
|
}
|
|
2176
5288
|
}
|
|
2177
5289
|
const deleted = engine.deleteAllCaptures();
|
|
2178
|
-
console.log(
|
|
5290
|
+
console.log(source_default.green(`
|
|
2179
5291
|
\u2713 Removed ${deleted} capture(s)`));
|
|
2180
|
-
console.log(
|
|
5292
|
+
console.log(source_default.gray(` Storage: ${engine.getCapturesDir()}
|
|
2181
5293
|
`));
|
|
2182
5294
|
});
|
|
2183
5295
|
var saveAsTemplateCommand = new Command4().name("save-as-template").alias("sat").argument("<captureId>", "Capture ID or partial ID").description("Save a captured webhook as a reusable template").option("--id <id>", "Template ID (auto-generated if not provided)").option("--name <name>", "Template display name").option("--event <event>", "Event type (auto-detected if not provided)").option("--description <description>", "Template description").option("--url <url>", "Default target URL for the template").option("--overwrite", "Overwrite existing template with same ID").action(
|
|
@@ -2186,18 +5298,18 @@ var saveAsTemplateCommand = new Command4().name("save-as-template").alias("sat")
|
|
|
2186
5298
|
const templateManager = getTemplateManager();
|
|
2187
5299
|
const captureFile = engine.getCapture(captureId);
|
|
2188
5300
|
if (!captureFile) {
|
|
2189
|
-
console.log(
|
|
5301
|
+
console.log(source_default.red(`
|
|
2190
5302
|
\u274C Capture not found: ${captureId}
|
|
2191
5303
|
`));
|
|
2192
5304
|
process.exitCode = 1;
|
|
2193
5305
|
return;
|
|
2194
5306
|
}
|
|
2195
5307
|
const { capture: capture2 } = captureFile;
|
|
2196
|
-
console.log(
|
|
2197
|
-
console.log(` ${
|
|
2198
|
-
console.log(
|
|
5308
|
+
console.log(source_default.bold("\n\u{1F4CB} Capture to save as template:\n"));
|
|
5309
|
+
console.log(` ${source_default.white(capture2.id.slice(0, 8))}`);
|
|
5310
|
+
console.log(source_default.gray(` ${capture2.method} ${capture2.path}`));
|
|
2199
5311
|
if (capture2.provider) {
|
|
2200
|
-
console.log(
|
|
5312
|
+
console.log(source_default.gray(` Provider: ${capture2.provider}`));
|
|
2201
5313
|
}
|
|
2202
5314
|
console.log();
|
|
2203
5315
|
const template = engine.captureToTemplate(captureId, {
|
|
@@ -2215,7 +5327,7 @@ var saveAsTemplateCommand = new Command4().name("save-as-template").alias("sat")
|
|
|
2215
5327
|
validate: (value) => value.trim().length > 0 || "Template ID is required"
|
|
2216
5328
|
});
|
|
2217
5329
|
if (!response.templateId) {
|
|
2218
|
-
console.log(
|
|
5330
|
+
console.log(source_default.yellow("Cancelled"));
|
|
2219
5331
|
return;
|
|
2220
5332
|
}
|
|
2221
5333
|
templateId = response.templateId;
|
|
@@ -2228,7 +5340,7 @@ var saveAsTemplateCommand = new Command4().name("save-as-template").alias("sat")
|
|
|
2228
5340
|
initial: false
|
|
2229
5341
|
});
|
|
2230
5342
|
if (!response.overwrite) {
|
|
2231
|
-
console.log(
|
|
5343
|
+
console.log(source_default.yellow("Cancelled"));
|
|
2232
5344
|
return;
|
|
2233
5345
|
}
|
|
2234
5346
|
options.overwrite = true;
|
|
@@ -2241,24 +5353,24 @@ var saveAsTemplateCommand = new Command4().name("save-as-template").alias("sat")
|
|
|
2241
5353
|
description: options.description,
|
|
2242
5354
|
overwrite: options.overwrite
|
|
2243
5355
|
});
|
|
2244
|
-
console.log(
|
|
5356
|
+
console.log(source_default.green(`
|
|
2245
5357
|
\u2713 Saved template: ${result.id}`));
|
|
2246
|
-
console.log(
|
|
2247
|
-
console.log(
|
|
5358
|
+
console.log(source_default.gray(` File: ${toRelativePath(result.filePath)}`));
|
|
5359
|
+
console.log(source_default.gray(` Provider: ${template.provider || "custom"}`));
|
|
2248
5360
|
if (template.event) {
|
|
2249
|
-
console.log(
|
|
5361
|
+
console.log(source_default.gray(` Event: ${template.event}`));
|
|
2250
5362
|
}
|
|
2251
5363
|
console.log();
|
|
2252
|
-
console.log(
|
|
5364
|
+
console.log(source_default.gray(" Run it with:"));
|
|
2253
5365
|
console.log(
|
|
2254
|
-
|
|
5366
|
+
source_default.cyan(
|
|
2255
5367
|
` better-webhook run ${result.id} --url http://localhost:3000/webhooks
|
|
2256
5368
|
`
|
|
2257
5369
|
)
|
|
2258
5370
|
);
|
|
2259
5371
|
} catch (error) {
|
|
2260
5372
|
const message = error instanceof Error ? error.message : "Failed to save template";
|
|
2261
|
-
console.log(
|
|
5373
|
+
console.log(source_default.red(`
|
|
2262
5374
|
\u274C ${message}
|
|
2263
5375
|
`));
|
|
2264
5376
|
process.exitCode = 1;
|
|
@@ -2269,9 +5381,7 @@ var captures = new Command4().name("captures").alias("c").description("Manage ca
|
|
|
2269
5381
|
|
|
2270
5382
|
// src/commands/replay.ts
|
|
2271
5383
|
import { Command as Command5 } from "commander";
|
|
2272
|
-
import ora3 from "ora";
|
|
2273
5384
|
import prompts4 from "prompts";
|
|
2274
|
-
import chalk5 from "chalk";
|
|
2275
5385
|
var replay = new Command5().name("replay").argument("[captureId]", "Capture ID to replay").argument("[targetUrl]", "Target URL to replay to").description("Replay a captured webhook to a target URL").option("-m, --method <method>", "Override HTTP method").option(
|
|
2276
5386
|
"-H, --header <header>",
|
|
2277
5387
|
"Add or override header (format: key:value)",
|
|
@@ -2292,9 +5402,9 @@ var replay = new Command5().name("replay").argument("[captureId]", "Capture ID t
|
|
|
2292
5402
|
if (!captureId) {
|
|
2293
5403
|
const captures2 = engine.listCaptures(50);
|
|
2294
5404
|
if (captures2.length === 0) {
|
|
2295
|
-
console.log(
|
|
5405
|
+
console.log(source_default.yellow("\n\u{1F4ED} No captured webhooks found."));
|
|
2296
5406
|
console.log(
|
|
2297
|
-
|
|
5407
|
+
source_default.gray(" Start capturing with: better-webhook capture\n")
|
|
2298
5408
|
);
|
|
2299
5409
|
return;
|
|
2300
5410
|
}
|
|
@@ -2314,14 +5424,14 @@ var replay = new Command5().name("replay").argument("[captureId]", "Capture ID t
|
|
|
2314
5424
|
choices
|
|
2315
5425
|
});
|
|
2316
5426
|
if (!response.captureId) {
|
|
2317
|
-
console.log(
|
|
5427
|
+
console.log(source_default.yellow("Cancelled"));
|
|
2318
5428
|
return;
|
|
2319
5429
|
}
|
|
2320
5430
|
captureId = response.captureId;
|
|
2321
5431
|
}
|
|
2322
5432
|
const captureFile = engine.getCapture(captureId);
|
|
2323
5433
|
if (!captureFile) {
|
|
2324
|
-
console.log(
|
|
5434
|
+
console.log(source_default.red(`
|
|
2325
5435
|
\u274C Capture not found: ${captureId}
|
|
2326
5436
|
`));
|
|
2327
5437
|
process.exitCode = 1;
|
|
@@ -2343,21 +5453,21 @@ var replay = new Command5().name("replay").argument("[captureId]", "Capture ID t
|
|
|
2343
5453
|
}
|
|
2344
5454
|
});
|
|
2345
5455
|
if (!response.url) {
|
|
2346
|
-
console.log(
|
|
5456
|
+
console.log(source_default.yellow("Cancelled"));
|
|
2347
5457
|
return;
|
|
2348
5458
|
}
|
|
2349
5459
|
targetUrl = response.url;
|
|
2350
5460
|
}
|
|
2351
5461
|
const { capture: capture2 } = captureFile;
|
|
2352
|
-
console.log(
|
|
2353
|
-
console.log(
|
|
2354
|
-
console.log(
|
|
5462
|
+
console.log(source_default.bold("\n\u{1F504} Replaying Webhook\n"));
|
|
5463
|
+
console.log(source_default.gray(` Capture ID: ${capture2.id.slice(0, 8)}`));
|
|
5464
|
+
console.log(source_default.gray(` Original: ${capture2.method} ${capture2.path}`));
|
|
2355
5465
|
if (capture2.provider) {
|
|
2356
|
-
console.log(
|
|
5466
|
+
console.log(source_default.gray(` Provider: ${capture2.provider}`));
|
|
2357
5467
|
}
|
|
2358
|
-
console.log(
|
|
5468
|
+
console.log(source_default.gray(` Target: ${targetUrl}`));
|
|
2359
5469
|
console.log();
|
|
2360
|
-
const spinner =
|
|
5470
|
+
const spinner = ora("Replaying webhook...").start();
|
|
2361
5471
|
try {
|
|
2362
5472
|
const result = await engine.replay(captureId, {
|
|
2363
5473
|
targetUrl,
|
|
@@ -2365,43 +5475,43 @@ var replay = new Command5().name("replay").argument("[captureId]", "Capture ID t
|
|
|
2365
5475
|
headers: options?.header
|
|
2366
5476
|
});
|
|
2367
5477
|
spinner.stop();
|
|
2368
|
-
const statusColor = result.status >= 200 && result.status < 300 ?
|
|
2369
|
-
console.log(
|
|
5478
|
+
const statusColor = result.status >= 200 && result.status < 300 ? source_default.green : result.status >= 400 ? source_default.red : source_default.yellow;
|
|
5479
|
+
console.log(source_default.bold("\u{1F4E5} Response\n"));
|
|
2370
5480
|
console.log(
|
|
2371
5481
|
` Status: ${statusColor(`${result.status} ${result.statusText}`)}`
|
|
2372
5482
|
);
|
|
2373
|
-
console.log(` Duration: ${
|
|
5483
|
+
console.log(` Duration: ${source_default.cyan(`${result.duration}ms`)}`);
|
|
2374
5484
|
if (options?.verbose) {
|
|
2375
|
-
console.log(
|
|
5485
|
+
console.log(source_default.bold("\n Headers:"));
|
|
2376
5486
|
for (const [key, value] of Object.entries(result.headers)) {
|
|
2377
5487
|
const headerValue = Array.isArray(value) ? value.join(", ") : value;
|
|
2378
|
-
console.log(
|
|
5488
|
+
console.log(source_default.gray(` ${key}: ${headerValue}`));
|
|
2379
5489
|
}
|
|
2380
5490
|
}
|
|
2381
5491
|
if (result.json !== void 0) {
|
|
2382
|
-
console.log(
|
|
5492
|
+
console.log(source_default.bold("\n Body:"));
|
|
2383
5493
|
console.log(
|
|
2384
|
-
|
|
5494
|
+
source_default.gray(
|
|
2385
5495
|
JSON.stringify(result.json, null, 2).split("\n").map((l) => ` ${l}`).join("\n")
|
|
2386
5496
|
)
|
|
2387
5497
|
);
|
|
2388
5498
|
} else if (result.bodyText) {
|
|
2389
|
-
console.log(
|
|
5499
|
+
console.log(source_default.bold("\n Body:"));
|
|
2390
5500
|
const preview = result.bodyText.length > 500 ? result.bodyText.slice(0, 500) + "..." : result.bodyText;
|
|
2391
|
-
console.log(
|
|
5501
|
+
console.log(source_default.gray(` ${preview}`));
|
|
2392
5502
|
}
|
|
2393
5503
|
console.log();
|
|
2394
5504
|
if (result.status >= 200 && result.status < 300) {
|
|
2395
|
-
console.log(
|
|
5505
|
+
console.log(source_default.green("\u2713 Replay completed successfully\n"));
|
|
2396
5506
|
} else {
|
|
2397
5507
|
console.log(
|
|
2398
|
-
|
|
5508
|
+
source_default.yellow(`\u26A0 Replay completed with status ${result.status}
|
|
2399
5509
|
`)
|
|
2400
5510
|
);
|
|
2401
5511
|
}
|
|
2402
5512
|
} catch (error) {
|
|
2403
5513
|
spinner.fail("Replay failed");
|
|
2404
|
-
console.error(
|
|
5514
|
+
console.error(source_default.red(`
|
|
2405
5515
|
\u274C ${error.message}
|
|
2406
5516
|
`));
|
|
2407
5517
|
process.exitCode = 1;
|
|
@@ -2411,15 +5521,13 @@ var replay = new Command5().name("replay").argument("[captureId]", "Capture ID t
|
|
|
2411
5521
|
|
|
2412
5522
|
// src/commands/dashboard.ts
|
|
2413
5523
|
import { Command as Command6 } from "commander";
|
|
2414
|
-
import chalk6 from "chalk";
|
|
2415
5524
|
|
|
2416
5525
|
// src/core/dashboard-server.ts
|
|
2417
5526
|
import express2 from "express";
|
|
2418
5527
|
import { createServer as createServer2 } from "http";
|
|
2419
5528
|
import { WebSocketServer as WebSocketServer2 } from "ws";
|
|
2420
|
-
import
|
|
2421
|
-
import { existsSync as
|
|
2422
|
-
import { fileURLToPath } from "url";
|
|
5529
|
+
import path3 from "path";
|
|
5530
|
+
import { existsSync as existsSync5 } from "fs";
|
|
2423
5531
|
|
|
2424
5532
|
// src/core/dashboard-api.ts
|
|
2425
5533
|
import express from "express";
|
|
@@ -2783,7 +5891,7 @@ function isStandaloneBinary() {
|
|
|
2783
5891
|
return false;
|
|
2784
5892
|
}
|
|
2785
5893
|
function getMimeType(filePath) {
|
|
2786
|
-
const ext =
|
|
5894
|
+
const ext = path3.extname(filePath).toLowerCase();
|
|
2787
5895
|
const mimeTypes = {
|
|
2788
5896
|
".html": "text/html; charset=utf-8",
|
|
2789
5897
|
".js": "application/javascript; charset=utf-8",
|
|
@@ -2856,20 +5964,35 @@ function createEmbeddedDashboardMiddleware() {
|
|
|
2856
5964
|
};
|
|
2857
5965
|
return { staticMiddleware, spaFallback };
|
|
2858
5966
|
}
|
|
2859
|
-
function resolveDashboardDistDir(runtimeDir) {
|
|
5967
|
+
function resolveDashboardDistDir(runtimeDir, options = {}) {
|
|
5968
|
+
const runtimePackageRoot = findCliPackageRoot(runtimeDir);
|
|
5969
|
+
const includePackageRootDistCandidate = runtimePackageRoot !== void 0 && runtimePackageRoot === runtimeDir;
|
|
2860
5970
|
const candidates = [
|
|
5971
|
+
// Package root fallback -> dist/dashboard (only when runtimeDir is package root)
|
|
5972
|
+
...includePackageRootDistCandidate ? [path3.resolve(runtimeDir, "dist", "dashboard")] : [],
|
|
2861
5973
|
// Bundled CLI: dist/index.js -> dist/dashboard
|
|
2862
|
-
|
|
5974
|
+
path3.resolve(runtimeDir, "dashboard"),
|
|
2863
5975
|
// Legacy/unbundled: dist/core -> dist/dashboard
|
|
2864
|
-
|
|
5976
|
+
path3.resolve(runtimeDir, "..", "dashboard"),
|
|
5977
|
+
// Dev from src -> dist/dashboard
|
|
5978
|
+
path3.resolve(runtimeDir, "..", "dist", "dashboard"),
|
|
2865
5979
|
// Dev from src/core -> dist/dashboard
|
|
2866
|
-
|
|
5980
|
+
path3.resolve(runtimeDir, "..", "..", "dist", "dashboard"),
|
|
5981
|
+
// Dev from package root -> apps/dashboard/dist
|
|
5982
|
+
path3.resolve(runtimeDir, "..", "dashboard", "dist"),
|
|
5983
|
+
// Dev from src -> apps/dashboard/dist
|
|
5984
|
+
path3.resolve(runtimeDir, "..", "..", "dashboard", "dist"),
|
|
2867
5985
|
// Dev from src/core -> apps/dashboard/dist
|
|
2868
|
-
|
|
5986
|
+
path3.resolve(runtimeDir, "..", "..", "..", "dashboard", "dist")
|
|
2869
5987
|
];
|
|
5988
|
+
if (options.verbose) {
|
|
5989
|
+
console.debug(
|
|
5990
|
+
`[dashboard] dist resolution candidates: ${candidates.join(", ")}`
|
|
5991
|
+
);
|
|
5992
|
+
}
|
|
2870
5993
|
for (const distDir of candidates) {
|
|
2871
|
-
const indexHtml =
|
|
2872
|
-
if (
|
|
5994
|
+
const indexHtml = path3.join(distDir, "index.html");
|
|
5995
|
+
if (existsSync5(indexHtml)) {
|
|
2873
5996
|
return { distDir, indexHtml };
|
|
2874
5997
|
}
|
|
2875
5998
|
}
|
|
@@ -2914,11 +6037,8 @@ async function startDashboardServer(options = {}) {
|
|
|
2914
6037
|
app.use(staticMiddleware);
|
|
2915
6038
|
app.get("*", spaFallback);
|
|
2916
6039
|
} else {
|
|
2917
|
-
const runtimeDir =
|
|
2918
|
-
|
|
2919
|
-
__dirname
|
|
2920
|
-
) : path.dirname(fileURLToPath(import.meta.url));
|
|
2921
|
-
const { distDir: dashboardDistDir, indexHtml: dashboardIndexHtml } = resolveDashboardDistDir(runtimeDir);
|
|
6040
|
+
const runtimeDir = resolveRuntimeDir();
|
|
6041
|
+
const { distDir: dashboardDistDir, indexHtml: dashboardIndexHtml } = resolveDashboardDistDir(runtimeDir, { verbose: options.verbose });
|
|
2922
6042
|
app.use(express2.static(dashboardDistDir));
|
|
2923
6043
|
app.get("*", (req, res, next) => {
|
|
2924
6044
|
if (req.path.startsWith("/api") || req.path === "/health") return next();
|
|
@@ -2991,82 +6111,80 @@ async function startDashboardServer(options = {}) {
|
|
|
2991
6111
|
}
|
|
2992
6112
|
|
|
2993
6113
|
// src/commands/dashboard.ts
|
|
2994
|
-
var dashboard = new Command6().name("dashboard").description("Start the local dashboard (UI + API + WebSocket) server").option("-p, --port <port>", "Port to listen on", "4000").option("-h, --host <host>", "Host to bind to", "localhost").option("--capture-port <port>", "Capture server port", "3001").option("--capture-host <host>", "Capture server host", "0.0.0.0").option("--no-capture", "Do not start the capture server").option("--captures-dir <dir>", "Override captures directory").option("--templates-dir <dir>", "Override templates base directory").action(
|
|
2995
|
-
|
|
2996
|
-
|
|
2997
|
-
|
|
2998
|
-
|
|
2999
|
-
return;
|
|
3000
|
-
}
|
|
3001
|
-
try {
|
|
3002
|
-
const capturePort = Number.parseInt(String(options.capturePort), 10);
|
|
3003
|
-
if (!Number.isFinite(capturePort) || capturePort < 0 || capturePort > 65535) {
|
|
3004
|
-
console.error(chalk6.red("Invalid capture port number"));
|
|
6114
|
+
var dashboard = new Command6().name("dashboard").description("Start the local dashboard (UI + API + WebSocket) server").option("-p, --port <port>", "Port to listen on", "4000").option("-h, --host <host>", "Host to bind to", "localhost").option("-v, --verbose", "Show dashboard startup debug details").option("--debug", "Alias for --verbose").option("--capture-port <port>", "Capture server port", "3001").option("--capture-host <host>", "Capture server host", "0.0.0.0").option("--no-capture", "Do not start the capture server").option("--captures-dir <dir>", "Override captures directory").option("--templates-dir <dir>", "Override templates base directory").action(
|
|
6115
|
+
async (options) => {
|
|
6116
|
+
const port = Number.parseInt(String(options.port), 10);
|
|
6117
|
+
if (!Number.isFinite(port) || port < 0 || port > 65535) {
|
|
6118
|
+
console.error(source_default.red("Invalid port number"));
|
|
3005
6119
|
process.exitCode = 1;
|
|
3006
6120
|
return;
|
|
3007
6121
|
}
|
|
3008
|
-
|
|
3009
|
-
|
|
3010
|
-
|
|
3011
|
-
|
|
3012
|
-
|
|
3013
|
-
|
|
3014
|
-
|
|
3015
|
-
|
|
3016
|
-
|
|
3017
|
-
|
|
3018
|
-
|
|
3019
|
-
|
|
3020
|
-
|
|
3021
|
-
|
|
3022
|
-
|
|
3023
|
-
|
|
3024
|
-
|
|
3025
|
-
|
|
3026
|
-
console.log(
|
|
3027
|
-
console.log(
|
|
6122
|
+
try {
|
|
6123
|
+
const capturePort = Number.parseInt(String(options.capturePort), 10);
|
|
6124
|
+
if (!Number.isFinite(capturePort) || capturePort < 0 || capturePort > 65535) {
|
|
6125
|
+
console.error(source_default.red("Invalid capture port number"));
|
|
6126
|
+
process.exitCode = 1;
|
|
6127
|
+
return;
|
|
6128
|
+
}
|
|
6129
|
+
const verbose = Boolean(options.verbose || options.debug);
|
|
6130
|
+
const { url, server, capture: capture2 } = await startDashboardServer({
|
|
6131
|
+
host: options.host,
|
|
6132
|
+
port,
|
|
6133
|
+
captureHost: options.captureHost,
|
|
6134
|
+
capturePort,
|
|
6135
|
+
startCapture: options.capture !== false,
|
|
6136
|
+
capturesDir: options.capturesDir,
|
|
6137
|
+
templatesBaseDir: options.templatesDir,
|
|
6138
|
+
verbose
|
|
6139
|
+
});
|
|
6140
|
+
console.log(source_default.bold("\n\u{1F9ED} Dashboard Server\n"));
|
|
6141
|
+
console.log(source_default.gray(` Dashboard: ${url}/`));
|
|
6142
|
+
console.log(source_default.gray(` Health: ${url}/health`));
|
|
6143
|
+
console.log(source_default.gray(` API Base: ${url}/api`));
|
|
3028
6144
|
console.log(
|
|
3029
|
-
|
|
3030
|
-
` Tip: Send webhooks to any path, e.g. ${capture2.url}/webhooks/github`
|
|
3031
|
-
)
|
|
6145
|
+
source_default.gray(` WebSocket: ${url.replace("http://", "ws://")}/ws`)
|
|
3032
6146
|
);
|
|
3033
|
-
}
|
|
3034
|
-
console.log();
|
|
3035
|
-
const shutdown = async () => {
|
|
3036
6147
|
if (capture2) {
|
|
3037
|
-
|
|
6148
|
+
console.log();
|
|
6149
|
+
console.log(source_default.bold("\u{1F3A3} Capture Server"));
|
|
6150
|
+
console.log(source_default.gray(` Capture: ${capture2.url}`));
|
|
6151
|
+
console.log(
|
|
6152
|
+
source_default.gray(
|
|
6153
|
+
` Tip: Send webhooks to any path, e.g. ${capture2.url}/webhooks/github`
|
|
6154
|
+
)
|
|
6155
|
+
);
|
|
3038
6156
|
}
|
|
3039
|
-
|
|
3040
|
-
|
|
3041
|
-
|
|
3042
|
-
|
|
3043
|
-
|
|
3044
|
-
|
|
3045
|
-
|
|
3046
|
-
|
|
3047
|
-
|
|
3048
|
-
)
|
|
3049
|
-
)
|
|
3050
|
-
|
|
6157
|
+
console.log();
|
|
6158
|
+
const shutdown = async () => {
|
|
6159
|
+
if (capture2) {
|
|
6160
|
+
await capture2.server.stop();
|
|
6161
|
+
}
|
|
6162
|
+
await new Promise((resolve) => server.close(() => resolve()));
|
|
6163
|
+
process.exit(0);
|
|
6164
|
+
};
|
|
6165
|
+
process.on("SIGINT", shutdown);
|
|
6166
|
+
process.on("SIGTERM", shutdown);
|
|
6167
|
+
} catch (error) {
|
|
6168
|
+
const message = error instanceof Error ? error.message : String(error);
|
|
6169
|
+
console.error(
|
|
6170
|
+
source_default.red(`Failed to start dashboard server: ${message}`)
|
|
6171
|
+
);
|
|
6172
|
+
process.exitCode = 1;
|
|
6173
|
+
}
|
|
3051
6174
|
}
|
|
3052
|
-
|
|
6175
|
+
);
|
|
3053
6176
|
|
|
3054
6177
|
// src/index.ts
|
|
3055
6178
|
function getVersion() {
|
|
3056
6179
|
if (typeof CLI_VERSION !== "undefined") {
|
|
3057
6180
|
return CLI_VERSION;
|
|
3058
6181
|
}
|
|
3059
|
-
|
|
3060
|
-
|
|
3061
|
-
|
|
3062
|
-
|
|
3063
|
-
const packageJson = JSON.parse(
|
|
3064
|
-
readFileSync5(packageJsonPath, { encoding: "utf8" })
|
|
3065
|
-
);
|
|
3066
|
-
return packageJson.version;
|
|
3067
|
-
} catch {
|
|
3068
|
-
return "0.0.0-unknown";
|
|
6182
|
+
const runtimeDir = resolveRuntimeDir();
|
|
6183
|
+
const runtimeVersion = resolveRuntimePackageVersion(runtimeDir);
|
|
6184
|
+
if (runtimeVersion) {
|
|
6185
|
+
return runtimeVersion;
|
|
3069
6186
|
}
|
|
6187
|
+
return "0.0.0-unknown";
|
|
3070
6188
|
}
|
|
3071
6189
|
var program = new Command7().name("better-webhook").description(
|
|
3072
6190
|
"Modern CLI for developing, capturing, and replaying webhooks locally"
|