@donotdev/cli 0.1.44 → 0.1.46

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.
@@ -5,7 +5,7 @@ var __getOwnPropNames = Object.getOwnPropertyNames;
5
5
  var __getProtoOf = Object.getPrototypeOf;
6
6
  var __hasOwnProp = Object.prototype.hasOwnProperty;
7
7
  var __require = /* @__PURE__ */ ((x) => typeof require !== "undefined" ? require : typeof Proxy !== "undefined" ? new Proxy(x, {
8
- get: (a, b) => (typeof require !== "undefined" ? require : a)[b]
8
+ get: (a2, b) => (typeof require !== "undefined" ? require : a2)[b]
9
9
  }) : x)(function(x) {
10
10
  if (typeof require !== "undefined") return require.apply(this, arguments);
11
11
  throw Error('Dynamic require of "' + x + '" is not supported');
@@ -33,31 +33,40 @@ var __toESM = (mod, isNodeMode, target) => (target = mod != null ? __create(__ge
33
33
  mod
34
34
  ));
35
35
 
36
- // node_modules/.bun/fast-string-truncated-width@1.2.1/node_modules/fast-string-truncated-width/dist/utils.js
37
- var isAmbiguous, isFullWidth, isWide;
36
+ // node_modules/.bun/fast-string-truncated-width@3.0.3/node_modules/fast-string-truncated-width/dist/utils.js
37
+ var getCodePointsLength, isFullWidth, isWideNotCJKTNotEmoji;
38
38
  var init_utils = __esm({
39
- "node_modules/.bun/fast-string-truncated-width@1.2.1/node_modules/fast-string-truncated-width/dist/utils.js"() {
39
+ "node_modules/.bun/fast-string-truncated-width@3.0.3/node_modules/fast-string-truncated-width/dist/utils.js"() {
40
40
  init_utils2();
41
- isAmbiguous = (x) => {
42
- 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;
43
- };
41
+ getCodePointsLength = /* @__PURE__ */ (() => {
42
+ const SURROGATE_PAIR_RE = /[\uD800-\uDBFF][\uDC00-\uDFFF]/g;
43
+ return (input) => {
44
+ let surrogatePairsNr = 0;
45
+ SURROGATE_PAIR_RE.lastIndex = 0;
46
+ while (SURROGATE_PAIR_RE.test(input)) {
47
+ surrogatePairsNr += 1;
48
+ }
49
+ return input.length - surrogatePairsNr;
50
+ };
51
+ })();
44
52
  isFullWidth = (x) => {
45
53
  return x === 12288 || x >= 65281 && x <= 65376 || x >= 65504 && x <= 65510;
46
54
  };
47
- isWide = (x) => {
48
- 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 >= 9800 && x <= 9811 || x === 9855 || 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 <= 12771 || x >= 12783 && x <= 12830 || x >= 12832 && x <= 12871 || x >= 12880 && x <= 19903 || x >= 19968 && 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 === 94193 || x >= 94208 && x <= 100343 || x >= 100352 && x <= 101589 || x >= 101632 && x <= 101640 || 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 === 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 <= 128727 || 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 <= 129672 || x >= 129680 && x <= 129725 || x >= 129727 && x <= 129733 || x >= 129742 && x <= 129755 || x >= 129760 && x <= 129768 || x >= 129776 && x <= 129784 || x >= 131072 && x <= 196605 || x >= 196608 && x <= 262141;
55
+ isWideNotCJKTNotEmoji = (x) => {
56
+ return x === 8987 || x === 9001 || x >= 12272 && x <= 12287 || x >= 12289 && x <= 12350 || x >= 12441 && x <= 12543 || x >= 12549 && x <= 12591 || x >= 12593 && x <= 12686 || x >= 12688 && x <= 12771 || x >= 12783 && x <= 12830 || x >= 12832 && x <= 12871 || x >= 12880 && x <= 19903 || x >= 65040 && x <= 65049 || x >= 65072 && x <= 65106 || x >= 65108 && x <= 65126 || x >= 65128 && x <= 65131 || x >= 127488 && x <= 127490 || x >= 127504 && x <= 127547 || x >= 127552 && x <= 127560 || x >= 131072 && x <= 196605 || x >= 196608 && x <= 262141;
49
57
  };
50
58
  }
51
59
  });
52
60
 
53
- // node_modules/.bun/fast-string-truncated-width@1.2.1/node_modules/fast-string-truncated-width/dist/index.js
54
- var ANSI_RE, CONTROL_RE, TAB_RE, EMOJI_RE, LATIN_RE, MODIFIER_RE, NO_TRUNCATION, getStringTruncatedWidth, dist_default;
61
+ // node_modules/.bun/fast-string-truncated-width@3.0.3/node_modules/fast-string-truncated-width/dist/index.js
62
+ var ANSI_RE, CONTROL_RE, CJKT_WIDE_RE, TAB_RE, EMOJI_RE, LATIN_RE, MODIFIER_RE, NO_TRUNCATION, getStringTruncatedWidth, dist_default;
55
63
  var init_dist = __esm({
56
- "node_modules/.bun/fast-string-truncated-width@1.2.1/node_modules/fast-string-truncated-width/dist/index.js"() {
64
+ "node_modules/.bun/fast-string-truncated-width@3.0.3/node_modules/fast-string-truncated-width/dist/index.js"() {
57
65
  init_utils2();
58
66
  init_utils();
59
- ANSI_RE = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]/y;
67
+ ANSI_RE = /[\u001b\u009b][[()#;?]*(?:[0-9]{1,4}(?:;[0-9]{0,4})*)?[0-9A-ORZcf-nqry=><]|\u001b\]8;[^;]*;.*?(?:\u0007|\u001b\u005c)/y;
60
68
  CONTROL_RE = /[\x00-\x08\x0A-\x1F\x7F-\x9F]{1,1000}/y;
69
+ CJKT_WIDE_RE = /(?:(?![\uFF61-\uFF9F\uFF00-\uFFEF])[\p{Script=Han}\p{Script=Hiragana}\p{Script=Katakana}\p{Script=Hangul}\p{Script=Tangut}]){1,1000}/yu;
61
70
  TAB_RE = /\t{1,1000}/y;
62
71
  EMOJI_RE = new RegExp("[\\u{1F1E6}-\\u{1F1FF}]{2}|\\u{1F3F4}[\\u{E0061}-\\u{E007A}]{2}[\\u{E0030}-\\u{E0039}\\u{E0061}-\\u{E007A}]{1,3}\\u{E007F}|(?:\\p{Emoji}\\uFE0F\\u20E3?|\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation})(?:\\u200D(?:\\p{Emoji_Modifier_Base}\\p{Emoji_Modifier}?|\\p{Emoji_Presentation}|\\p{Emoji}\\uFE0F\\u20E3?))*", "yu");
63
72
  LATIN_RE = /(?:[\x20-\x7E\xA0-\xFF](?!\uFE0F)){1,1000}/y;
@@ -67,14 +76,21 @@ var init_dist = __esm({
67
76
  const LIMIT = truncationOptions.limit ?? Infinity;
68
77
  const ELLIPSIS = truncationOptions.ellipsis ?? "";
69
78
  const ELLIPSIS_WIDTH = truncationOptions?.ellipsisWidth ?? (ELLIPSIS ? getStringTruncatedWidth(ELLIPSIS, NO_TRUNCATION, widthOptions).width : 0);
70
- const ANSI_WIDTH = widthOptions.ansiWidth ?? 0;
79
+ const ANSI_WIDTH = 0;
71
80
  const CONTROL_WIDTH = widthOptions.controlWidth ?? 0;
72
81
  const TAB_WIDTH = widthOptions.tabWidth ?? 8;
73
- const AMBIGUOUS_WIDTH = widthOptions.ambiguousWidth ?? 1;
74
82
  const EMOJI_WIDTH = widthOptions.emojiWidth ?? 2;
75
- const FULL_WIDTH_WIDTH = widthOptions.fullWidthWidth ?? 2;
83
+ const FULL_WIDTH_WIDTH = 2;
76
84
  const REGULAR_WIDTH = widthOptions.regularWidth ?? 1;
77
- const WIDE_WIDTH = widthOptions.wideWidth ?? 2;
85
+ const WIDE_WIDTH = widthOptions.wideWidth ?? FULL_WIDTH_WIDTH;
86
+ const PARSE_BLOCKS = [
87
+ [LATIN_RE, REGULAR_WIDTH],
88
+ [ANSI_RE, ANSI_WIDTH],
89
+ [CONTROL_RE, CONTROL_WIDTH],
90
+ [TAB_RE, TAB_WIDTH],
91
+ [EMOJI_RE, EMOJI_WIDTH],
92
+ [CJKT_WIDE_RE, WIDE_WIDTH]
93
+ ];
78
94
  let indexPrev = 0;
79
95
  let index = 0;
80
96
  let length = input.length;
@@ -94,10 +110,8 @@ var init_dist = __esm({
94
110
  const codePoint = char.codePointAt(0) || 0;
95
111
  if (isFullWidth(codePoint)) {
96
112
  widthExtra = FULL_WIDTH_WIDTH;
97
- } else if (isWide(codePoint)) {
113
+ } else if (isWideNotCJKTNotEmoji(codePoint)) {
98
114
  widthExtra = WIDE_WIDTH;
99
- } else if (AMBIGUOUS_WIDTH !== REGULAR_WIDTH && isAmbiguous(codePoint)) {
100
- widthExtra = AMBIGUOUS_WIDTH;
101
115
  } else {
102
116
  widthExtra = REGULAR_WIDTH;
103
117
  }
@@ -113,88 +127,28 @@ var init_dist = __esm({
113
127
  }
114
128
  unmatchedStart = unmatchedEnd = 0;
115
129
  }
116
- if (index >= length)
117
- break;
118
- LATIN_RE.lastIndex = index;
119
- if (LATIN_RE.test(input)) {
120
- lengthExtra = LATIN_RE.lastIndex - index;
121
- widthExtra = lengthExtra * REGULAR_WIDTH;
122
- if (width + widthExtra > truncationLimit) {
123
- truncationIndex = Math.min(truncationIndex, index + Math.floor((truncationLimit - width) / REGULAR_WIDTH));
124
- }
125
- if (width + widthExtra > LIMIT) {
126
- truncationEnabled = true;
127
- break;
128
- }
129
- width += widthExtra;
130
- unmatchedStart = indexPrev;
131
- unmatchedEnd = index;
132
- index = indexPrev = LATIN_RE.lastIndex;
133
- continue;
134
- }
135
- ANSI_RE.lastIndex = index;
136
- if (ANSI_RE.test(input)) {
137
- if (width + ANSI_WIDTH > truncationLimit) {
138
- truncationIndex = Math.min(truncationIndex, index);
139
- }
140
- if (width + ANSI_WIDTH > LIMIT) {
141
- truncationEnabled = true;
142
- break;
143
- }
144
- width += ANSI_WIDTH;
145
- unmatchedStart = indexPrev;
146
- unmatchedEnd = index;
147
- index = indexPrev = ANSI_RE.lastIndex;
148
- continue;
130
+ if (index >= length) {
131
+ break outer;
149
132
  }
150
- CONTROL_RE.lastIndex = index;
151
- if (CONTROL_RE.test(input)) {
152
- lengthExtra = CONTROL_RE.lastIndex - index;
153
- widthExtra = lengthExtra * CONTROL_WIDTH;
154
- if (width + widthExtra > truncationLimit) {
155
- truncationIndex = Math.min(truncationIndex, index + Math.floor((truncationLimit - width) / CONTROL_WIDTH));
156
- }
157
- if (width + widthExtra > LIMIT) {
158
- truncationEnabled = true;
159
- break;
160
- }
161
- width += widthExtra;
162
- unmatchedStart = indexPrev;
163
- unmatchedEnd = index;
164
- index = indexPrev = CONTROL_RE.lastIndex;
165
- continue;
166
- }
167
- TAB_RE.lastIndex = index;
168
- if (TAB_RE.test(input)) {
169
- lengthExtra = TAB_RE.lastIndex - index;
170
- widthExtra = lengthExtra * TAB_WIDTH;
171
- if (width + widthExtra > truncationLimit) {
172
- truncationIndex = Math.min(truncationIndex, index + Math.floor((truncationLimit - width) / TAB_WIDTH));
173
- }
174
- if (width + widthExtra > LIMIT) {
175
- truncationEnabled = true;
176
- break;
177
- }
178
- width += widthExtra;
179
- unmatchedStart = indexPrev;
180
- unmatchedEnd = index;
181
- index = indexPrev = TAB_RE.lastIndex;
182
- continue;
183
- }
184
- EMOJI_RE.lastIndex = index;
185
- if (EMOJI_RE.test(input)) {
186
- if (width + EMOJI_WIDTH > truncationLimit) {
187
- truncationIndex = Math.min(truncationIndex, index);
188
- }
189
- if (width + EMOJI_WIDTH > LIMIT) {
190
- truncationEnabled = true;
191
- break;
133
+ for (let i2 = 0, l = PARSE_BLOCKS.length; i2 < l; i2++) {
134
+ const [BLOCK_RE, BLOCK_WIDTH] = PARSE_BLOCKS[i2];
135
+ BLOCK_RE.lastIndex = index;
136
+ if (BLOCK_RE.test(input)) {
137
+ lengthExtra = BLOCK_RE === CJKT_WIDE_RE ? getCodePointsLength(input.slice(index, BLOCK_RE.lastIndex)) : BLOCK_RE === EMOJI_RE ? 1 : BLOCK_RE.lastIndex - index;
138
+ widthExtra = lengthExtra * BLOCK_WIDTH;
139
+ if (width + widthExtra > truncationLimit) {
140
+ truncationIndex = Math.min(truncationIndex, index + Math.floor((truncationLimit - width) / BLOCK_WIDTH));
141
+ }
142
+ if (width + widthExtra > LIMIT) {
143
+ truncationEnabled = true;
144
+ break outer;
145
+ }
146
+ width += widthExtra;
147
+ unmatchedStart = indexPrev;
148
+ unmatchedEnd = index;
149
+ index = indexPrev = BLOCK_RE.lastIndex;
150
+ continue outer;
192
151
  }
193
- width += EMOJI_WIDTH;
194
- unmatchedStart = indexPrev;
195
- unmatchedEnd = index;
196
- index = indexPrev = EMOJI_RE.lastIndex;
197
- continue;
198
152
  }
199
153
  index += 1;
200
154
  }
@@ -209,10 +163,10 @@ var init_dist = __esm({
209
163
  }
210
164
  });
211
165
 
212
- // node_modules/.bun/fast-string-width@1.1.0/node_modules/fast-string-width/dist/index.js
166
+ // node_modules/.bun/fast-string-width@3.0.2/node_modules/fast-string-width/dist/index.js
213
167
  var NO_TRUNCATION2, fastStringWidth, dist_default2;
214
168
  var init_dist2 = __esm({
215
- "node_modules/.bun/fast-string-width@1.1.0/node_modules/fast-string-width/dist/index.js"() {
169
+ "node_modules/.bun/fast-string-width@3.0.2/node_modules/fast-string-width/dist/index.js"() {
216
170
  init_utils2();
217
171
  init_dist();
218
172
  NO_TRUNCATION2 = {
@@ -227,13 +181,13 @@ var init_dist2 = __esm({
227
181
  }
228
182
  });
229
183
 
230
- // node_modules/.bun/fast-wrap-ansi@0.1.6/node_modules/fast-wrap-ansi/lib/main.js
184
+ // node_modules/.bun/fast-wrap-ansi@0.2.2/node_modules/fast-wrap-ansi/lib/main.js
231
185
  function wrapAnsi(string, columns, options) {
232
186
  return String(string).normalize().split(CRLF_OR_LF).map((line) => exec(line, columns, options)).join("\n");
233
187
  }
234
188
  var ESC, CSI, END_CODE, ANSI_ESCAPE_BELL, ANSI_CSI, ANSI_OSC, ANSI_SGR_TERMINATOR, ANSI_ESCAPE_LINK, GROUP_REGEX, getClosingCode, wrapAnsiCode, wrapAnsiHyperlink, wrapWord, stringVisibleTrimSpacesRight, exec, CRLF_OR_LF;
235
189
  var init_main = __esm({
236
- "node_modules/.bun/fast-wrap-ansi@0.1.6/node_modules/fast-wrap-ansi/lib/main.js"() {
190
+ "node_modules/.bun/fast-wrap-ansi@0.2.2/node_modules/fast-wrap-ansi/lib/main.js"() {
237
191
  init_utils2();
238
192
  init_dist2();
239
193
  ESC = "\x1B";
@@ -397,16 +351,19 @@ var init_main = __esm({
397
351
  }
398
352
  const preString = rows.join("\n");
399
353
  let inSurrogate = false;
400
- for (let i = 0; i < preString.length; i++) {
401
- const character = preString[i];
354
+ for (let i2 = 0; i2 < preString.length; i2++) {
355
+ const character = preString[i2];
402
356
  returnValue += character;
403
357
  if (!inSurrogate) {
404
358
  inSurrogate = character >= "\uD800" && character <= "\uDBFF";
359
+ if (inSurrogate) {
360
+ continue;
361
+ }
405
362
  } else {
406
- continue;
363
+ inSurrogate = false;
407
364
  }
408
365
  if (character === ESC || character === CSI) {
409
- GROUP_REGEX.lastIndex = i + 1;
366
+ GROUP_REGEX.lastIndex = i2 + 1;
410
367
  const groupsResult = GROUP_REGEX.exec(preString);
411
368
  const groups = groupsResult?.groups;
412
369
  if (groups?.code !== void 0) {
@@ -416,7 +373,7 @@ var init_main = __esm({
416
373
  escapeUrl = groups.uri.length === 0 ? void 0 : groups.uri;
417
374
  }
418
375
  }
419
- if (preString[i + 1] === "\n") {
376
+ if (preString[i2 + 1] === "\n") {
420
377
  if (escapeUrl) {
421
378
  returnValue += wrapAnsiHyperlink("");
422
379
  }
@@ -447,7 +404,7 @@ var require_src = __commonJS({
447
404
  var ESC2 = "\x1B";
448
405
  var CSI2 = `${ESC2}[`;
449
406
  var beep = "\x07";
450
- var cursor = {
407
+ var cursor3 = {
451
408
  to(x, y2) {
452
409
  if (!y2) return `${CSI2}${x + 1}G`;
453
410
  return `${CSI2}${y2 + 1};${x + 1}H`;
@@ -476,7 +433,7 @@ var require_src = __commonJS({
476
433
  up: (count = 1) => `${CSI2}S`.repeat(count),
477
434
  down: (count = 1) => `${CSI2}T`.repeat(count)
478
435
  };
479
- var erase = {
436
+ var erase3 = {
480
437
  screen: `${CSI2}2J`,
481
438
  up: (count = 1) => `${CSI2}1J`.repeat(count),
482
439
  down: (count = 1) => `${CSI2}J`.repeat(count),
@@ -485,67 +442,137 @@ var require_src = __commonJS({
485
442
  lineStart: `${CSI2}1K`,
486
443
  lines(count) {
487
444
  let clear = "";
488
- for (let i = 0; i < count; i++)
489
- clear += this.line + (i < count - 1 ? cursor.up() : "");
445
+ for (let i2 = 0; i2 < count; i2++)
446
+ clear += this.line + (i2 < count - 1 ? cursor3.up() : "");
490
447
  if (count)
491
- clear += cursor.left;
448
+ clear += cursor3.left;
492
449
  return clear;
493
450
  }
494
451
  };
495
- module.exports = { cursor, scroll, erase, beep };
452
+ module.exports = { cursor: cursor3, scroll, erase: erase3, beep };
496
453
  }
497
454
  });
498
455
 
499
- // node_modules/.bun/@clack+core@1.2.0/node_modules/@clack/core/dist/index.mjs
500
- import { styleText as y } from "node:util";
501
- import { stdout as S, stdin as $ } from "node:process";
502
- import P from "node:readline";
503
- import { ReadStream as D } from "node:tty";
504
- function d(r, t2, e) {
505
- if (!e.some((o) => !o.disabled)) return r;
506
- const s = r + t2, i = Math.max(e.length - 1, 0), n = s < 0 ? i : s > i ? 0 : s;
507
- return e[n].disabled ? d(n, t2 < 0 ? -1 : 1, e) : n;
456
+ // node_modules/.bun/@clack+core@1.5.0/node_modules/@clack/core/dist/index.mjs
457
+ import { styleText } from "node:util";
458
+ import { stdout, stdin } from "node:process";
459
+ import l__default from "node:readline";
460
+ import { ReadStream } from "node:tty";
461
+ function findCursor(s, o, l) {
462
+ if (!l.some((r2) => !r2.disabled))
463
+ return s;
464
+ const t2 = s + o, n3 = Math.max(l.length - 1, 0), e = t2 < 0 ? n3 : t2 > n3 ? 0 : t2;
465
+ return l[e]?.disabled ? findCursor(e, o < 0 ? -1 : 1, l) : e;
508
466
  }
509
- function V(r, t2) {
510
- if (typeof r == "string") return u.aliases.get(r) === t2;
511
- for (const e of r) if (e !== void 0 && V(e, t2)) return true;
467
+ function isAccessible(n3) {
468
+ if (n3 !== void 0) return n3;
469
+ if (settings.accessible !== void 0) return settings.accessible;
470
+ const e = process.env.ACCESSIBLE;
471
+ return e !== void 0 && e !== "" && e !== "0" && e !== "false";
472
+ }
473
+ function isActionKey(n3, e) {
474
+ if (typeof n3 == "string")
475
+ return settings.aliases.get(n3) === e;
476
+ for (const s of n3)
477
+ if (s !== void 0 && isActionKey(s, e))
478
+ return true;
512
479
  return false;
513
480
  }
514
- function j(r, t2) {
515
- if (r === t2) return;
516
- const e = r.split(`
517
- `), s = t2.split(`
518
- `), i = Math.max(e.length, s.length), n = [];
519
- for (let o = 0; o < i; o++) e[o] !== s[o] && n.push(o);
520
- return { lines: n, numLinesBefore: e.length, numLinesAfter: s.length, numLines: i };
481
+ function diffLines(i2, s) {
482
+ if (i2 === s) return;
483
+ const e = i2.split(`
484
+ `), t2 = s.split(`
485
+ `), r2 = Math.max(e.length, t2.length), f = [];
486
+ for (let n3 = 0; n3 < r2; n3++)
487
+ e[n3] !== t2[n3] && f.push(n3);
488
+ return {
489
+ lines: f,
490
+ numLinesBefore: e.length,
491
+ numLinesAfter: t2.length,
492
+ numLines: r2
493
+ };
521
494
  }
522
- function q(r) {
523
- return r === C;
495
+ function isCancel(e) {
496
+ return e === CANCEL_SYMBOL;
524
497
  }
525
- function w(r, t2) {
526
- const e = r;
527
- e.isTTY && e.setRawMode(t2);
498
+ function setRawMode(e, r2) {
499
+ const o = e;
500
+ o.isTTY && o.setRawMode(r2);
528
501
  }
529
- function R(r, t2, e, s = e) {
530
- const i = O(r ?? S);
531
- return wrapAnsi(t2, i - e.length, { hard: true, trim: false }).split(`
532
- `).map((n, o) => `${o === 0 ? s : e}${n}`).join(`
502
+ function wrapTextWithPrefix(e, r2, o, n3 = o, s = o, t2) {
503
+ const f = getColumns(e ?? stdout);
504
+ return wrapAnsi(r2, f - o.length, {
505
+ hard: true,
506
+ trim: false
507
+ }).split(`
508
+ `).map((c2, i2, m) => {
509
+ const d = t2 ? t2(c2, i2) : c2;
510
+ return i2 === 0 ? `${n3}${d}` : i2 === m.length - 1 ? `${s}${d}` : `${o}${d}`;
511
+ }).join(`
533
512
  `);
534
513
  }
535
- var import_sisteransi, E, G, u, Y, C, O, A, p, nt;
514
+ function runValidation(e, a2) {
515
+ if ("~standard" in e) {
516
+ const n3 = e["~standard"].validate(a2);
517
+ return n3 instanceof Promise ? n3.then((r2) => r2.issues?.at(0)?.message) : n3.issues?.at(0)?.message;
518
+ }
519
+ return e(a2);
520
+ }
521
+ var import_sisteransi, a$1, t, settings, R, CANCEL_SYMBOL, getColumns, getRows, y, n$1;
536
522
  var init_dist3 = __esm({
537
- "node_modules/.bun/@clack+core@1.2.0/node_modules/@clack/core/dist/index.mjs"() {
523
+ "node_modules/.bun/@clack+core@1.5.0/node_modules/@clack/core/dist/index.mjs"() {
538
524
  init_utils2();
539
525
  init_main();
540
526
  import_sisteransi = __toESM(require_src(), 1);
541
- E = ["up", "down", "left", "right", "space", "enter", "cancel"];
542
- G = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"];
543
- u = { actions: new Set(E), aliases: /* @__PURE__ */ new Map([["k", "up"], ["j", "down"], ["h", "left"], ["l", "right"], ["", "cancel"], ["escape", "cancel"]]), messages: { cancel: "Canceled", error: "Something went wrong" }, withGuide: true, date: { monthNames: [...G], messages: { required: "Please enter a valid date", invalidMonth: "There are only 12 months in a year", invalidDay: (r, t2) => `There are only ${r} days in ${t2}`, afterMin: (r) => `Date must be on or after ${r.toISOString().slice(0, 10)}`, beforeMax: (r) => `Date must be on or before ${r.toISOString().slice(0, 10)}` } } };
544
- Y = globalThis.process.platform.startsWith("win");
545
- C = /* @__PURE__ */ Symbol("clack:cancel");
546
- O = (r) => "columns" in r && typeof r.columns == "number" ? r.columns : 80;
547
- A = (r) => "rows" in r && typeof r.rows == "number" ? r.rows : 20;
548
- p = class {
527
+ a$1 = ["up", "down", "left", "right", "space", "enter", "cancel"];
528
+ t = [
529
+ "January",
530
+ "February",
531
+ "March",
532
+ "April",
533
+ "May",
534
+ "June",
535
+ "July",
536
+ "August",
537
+ "September",
538
+ "October",
539
+ "November",
540
+ "December"
541
+ ];
542
+ settings = {
543
+ actions: new Set(a$1),
544
+ aliases: /* @__PURE__ */ new Map([
545
+ // vim support
546
+ ["k", "up"],
547
+ ["j", "down"],
548
+ ["h", "left"],
549
+ ["l", "right"],
550
+ ["", "cancel"],
551
+ // opinionated defaults!
552
+ ["escape", "cancel"]
553
+ ]),
554
+ messages: {
555
+ cancel: "Canceled",
556
+ error: "Something went wrong"
557
+ },
558
+ withGuide: true,
559
+ accessible: void 0,
560
+ date: {
561
+ monthNames: [...t],
562
+ messages: {
563
+ required: "Please enter a valid date",
564
+ invalidMonth: "There are only 12 months in a year",
565
+ invalidDay: (n3, e) => `There are only ${n3} days in ${e}`,
566
+ afterMin: (n3) => `Date must be on or after ${n3.toISOString().slice(0, 10)}`,
567
+ beforeMax: (n3) => `Date must be on or before ${n3.toISOString().slice(0, 10)}`
568
+ }
569
+ }
570
+ };
571
+ R = globalThis.process.platform.startsWith("win");
572
+ CANCEL_SYMBOL = /* @__PURE__ */ Symbol("clack:cancel");
573
+ getColumns = (e) => "columns" in e && typeof e.columns == "number" ? e.columns : 80;
574
+ getRows = (e) => "rows" in e && typeof e.rows == "number" ? e.rows : 20;
575
+ y = class {
549
576
  input;
550
577
  output;
551
578
  _abortSignal;
@@ -560,46 +587,92 @@ var init_dist3 = __esm({
560
587
  error = "";
561
588
  value;
562
589
  userInput = "";
590
+ /**
591
+ * Whether accessible (static, screen-reader friendly) output is enabled for
592
+ * this prompt, resolved from the `accessible` option, the global setting,
593
+ * and the `ACCESSIBLE` env var.
594
+ */
595
+ get accessible() {
596
+ return isAccessible(this.opts.accessible);
597
+ }
563
598
  constructor(t2, e = true) {
564
- const { input: s = $, output: i = S, render: n, signal: o, ...a } = t2;
565
- this.opts = a, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = n.bind(this), this._track = e, this._abortSignal = o, this.input = s, this.output = i;
599
+ const { input: i2 = stdin, output: s = stdout, render: r2, signal: n3, ...o } = t2;
600
+ this.opts = o, this.onKeypress = this.onKeypress.bind(this), this.close = this.close.bind(this), this.render = this.render.bind(this), this._render = r2.bind(this), this._track = e, this._abortSignal = n3, this.input = i2, this.output = s;
566
601
  }
602
+ /**
603
+ * Unsubscribe all listeners
604
+ */
567
605
  unsubscribe() {
568
606
  this._subscribers.clear();
569
607
  }
608
+ /**
609
+ * Set a subscriber with opts
610
+ * @param event - The event name
611
+ */
570
612
  setSubscriber(t2, e) {
571
- const s = this._subscribers.get(t2) ?? [];
572
- s.push(e), this._subscribers.set(t2, s);
613
+ const i2 = this._subscribers.get(t2) ?? [];
614
+ i2.push(e), this._subscribers.set(t2, i2);
573
615
  }
616
+ /**
617
+ * Subscribe to an event
618
+ * @param event - The event name
619
+ * @param cb - The callback
620
+ */
574
621
  on(t2, e) {
575
622
  this.setSubscriber(t2, { cb: e });
576
623
  }
624
+ /**
625
+ * Subscribe to an event once
626
+ * @param event - The event name
627
+ * @param cb - The callback
628
+ */
577
629
  once(t2, e) {
578
630
  this.setSubscriber(t2, { cb: e, once: true });
579
631
  }
632
+ /**
633
+ * Emit an event with data
634
+ * @param event - The event name
635
+ * @param data - The data to pass to the callback
636
+ */
580
637
  emit(t2, ...e) {
581
- const s = this._subscribers.get(t2) ?? [], i = [];
582
- for (const n of s) n.cb(...e), n.once && i.push(() => s.splice(s.indexOf(n), 1));
583
- for (const n of i) n();
638
+ const i2 = this._subscribers.get(t2) ?? [], s = [];
639
+ for (const r2 of i2)
640
+ r2.cb(...e), r2.once && s.push(() => i2.splice(i2.indexOf(r2), 1));
641
+ for (const r2 of s)
642
+ r2();
584
643
  }
585
644
  prompt() {
586
645
  return new Promise((t2) => {
587
646
  if (this._abortSignal) {
588
- if (this._abortSignal.aborted) return this.state = "cancel", this.close(), t2(C);
589
- this._abortSignal.addEventListener("abort", () => {
590
- this.state = "cancel", this.close();
591
- }, { once: true });
647
+ if (this._abortSignal.aborted)
648
+ return this.state = "cancel", this.close(), t2(CANCEL_SYMBOL);
649
+ this._abortSignal.addEventListener(
650
+ "abort",
651
+ () => {
652
+ this.state = "cancel", this.close();
653
+ },
654
+ { once: true }
655
+ );
592
656
  }
593
- this.rl = P.createInterface({ input: this.input, tabSize: 2, prompt: "", escapeCodeTimeout: 50, terminal: true }), this.rl.prompt(), this.opts.initialUserInput !== void 0 && this._setUserInput(this.opts.initialUserInput, true), this.input.on("keypress", this.onKeypress), w(this.input, true), this.output.on("resize", this.render), this.render(), this.once("submit", () => {
594
- this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), w(this.input, false), t2(this.value);
657
+ this.rl = l__default.createInterface({
658
+ input: this.input,
659
+ tabSize: 2,
660
+ prompt: "",
661
+ escapeCodeTimeout: 50,
662
+ terminal: true
663
+ }), this.rl.prompt(), this.opts.initialUserInput !== void 0 && this._setUserInput(this.opts.initialUserInput, true), this.input.on("keypress", this.onKeypress), setRawMode(this.input, true), this.output.on("resize", this.render), this.render(), this.once("submit", () => {
664
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), setRawMode(this.input, false), t2(this.value);
595
665
  }), this.once("cancel", () => {
596
- this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), w(this.input, false), t2(C);
666
+ this.output.write(import_sisteransi.cursor.show), this.output.off("resize", this.render), setRawMode(this.input, false), t2(CANCEL_SYMBOL);
597
667
  });
598
668
  });
599
669
  }
600
670
  _isActionKey(t2, e) {
601
671
  return t2 === " ";
602
672
  }
673
+ _shouldSubmit(t2, e) {
674
+ return true;
675
+ }
603
676
  _setValue(t2) {
604
677
  this.value = t2, this.emit("value", this.value);
605
678
  }
@@ -609,19 +682,22 @@ var init_dist3 = __esm({
609
682
  _clearUserInput() {
610
683
  this.rl?.write(null, { ctrl: true, name: "u" }), this._setUserInput("");
611
684
  }
612
- onKeypress(t2, e) {
613
- if (this._track && e.name !== "return" && (e.name && this._isActionKey(t2, e) && this.rl?.write(null, { ctrl: true, name: "h" }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), e?.name && (!this._track && u.aliases.has(e.name) && this.emit("cursor", u.aliases.get(e.name)), u.actions.has(e.name) && this.emit("cursor", e.name)), t2 && (t2.toLowerCase() === "y" || t2.toLowerCase() === "n") && this.emit("confirm", t2.toLowerCase() === "y"), this.emit("key", t2?.toLowerCase(), e), e?.name === "return") {
614
- if (this.opts.validate) {
615
- const s = this.opts.validate(this.value);
616
- s && (this.error = s instanceof Error ? s.message : s, this.state = "error", this.rl?.write(this.userInput));
685
+ async onKeypress(t2, e) {
686
+ if (this.state !== "validating") {
687
+ if (this._track && e.name !== "return" && (e.name && this._isActionKey(t2, e) && this.rl?.write(null, { ctrl: true, name: "h" }), this._cursor = this.rl?.cursor ?? 0, this._setUserInput(this.rl?.line)), this.state === "error" && (this.state = "active"), e?.name && (!this._track && settings.aliases.has(e.name) && this.emit("cursor", settings.aliases.get(e.name)), settings.actions.has(e.name) && this.emit("cursor", e.name)), t2 && (t2.toLowerCase() === "y" || t2.toLowerCase() === "n") && this.emit("confirm", t2.toLowerCase() === "y"), this.emit("key", t2, e), e?.name === "return" && this._shouldSubmit(t2, e)) {
688
+ if (this.opts.validate) {
689
+ const i2 = runValidation(this.opts.validate, this.value);
690
+ let s;
691
+ i2 instanceof Promise ? (this.state = "validating", this.render(), s = await i2) : s = i2, s && (this.error = s instanceof Error ? s.message : s, this.state = "error", this.rl?.write(this.userInput));
692
+ }
693
+ this.state !== "error" && (this.state = "submit");
617
694
  }
618
- this.state !== "error" && (this.state = "submit");
695
+ isActionKey([t2, e?.name, e?.sequence], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
619
696
  }
620
- V([t2, e?.name, e?.sequence], "cancel") && (this.state = "cancel"), (this.state === "submit" || this.state === "cancel") && this.emit("finalize"), this.render(), (this.state === "submit" || this.state === "cancel") && this.close();
621
697
  }
622
698
  close() {
623
699
  this.input.unpipe(), this.input.removeListener("keypress", this.onKeypress), this.output.write(`
624
- `), w(this.input, false), this.rl?.close(), this.rl = void 0, this.emit(`${this.state}`, this.value), this.unsubscribe();
700
+ `), setRawMode(this.input, false), this.rl?.close(), this.rl = void 0, this.emit(`${this.state}`, this.value), this.unsubscribe();
625
701
  }
626
702
  restoreCursor() {
627
703
  const t2 = wrapAnsi(this._prevFrame, process.stdout.columns, { hard: true, trim: false }).split(`
@@ -629,34 +705,39 @@ var init_dist3 = __esm({
629
705
  this.output.write(import_sisteransi.cursor.move(-999, t2 * -1));
630
706
  }
631
707
  render() {
632
- const t2 = wrapAnsi(this._render(this) ?? "", process.stdout.columns, { hard: true, trim: false });
708
+ const t2 = wrapAnsi(this._render(this) ?? "", process.stdout.columns, {
709
+ hard: true,
710
+ trim: false
711
+ });
633
712
  if (t2 !== this._prevFrame) {
634
- if (this.state === "initial") this.output.write(import_sisteransi.cursor.hide);
713
+ if (this.state === "initial")
714
+ this.output.write(import_sisteransi.cursor.hide);
635
715
  else {
636
- const e = j(this._prevFrame, t2), s = A(this.output);
716
+ const e = diffLines(this._prevFrame, t2), i2 = getRows(this.output);
637
717
  if (this.restoreCursor(), e) {
638
- const i = Math.max(0, e.numLinesAfter - s), n = Math.max(0, e.numLinesBefore - s);
639
- let o = e.lines.find((a) => a >= i);
640
- if (o === void 0) {
718
+ const s = Math.max(0, e.numLinesAfter - i2), r2 = Math.max(0, e.numLinesBefore - i2);
719
+ let n3 = e.lines.find((o) => o >= s);
720
+ if (n3 === void 0) {
641
721
  this._prevFrame = t2;
642
722
  return;
643
723
  }
644
724
  if (e.lines.length === 1) {
645
- this.output.write(import_sisteransi.cursor.move(0, o - n)), this.output.write(import_sisteransi.erase.lines(1));
646
- const a = t2.split(`
725
+ this.output.write(import_sisteransi.cursor.move(0, n3 - r2)), this.output.write(import_sisteransi.erase.lines(1));
726
+ const o = t2.split(`
647
727
  `);
648
- this.output.write(a[o]), this._prevFrame = t2, this.output.write(import_sisteransi.cursor.move(0, a.length - o - 1));
728
+ this.output.write(o[n3]), this._prevFrame = t2, this.output.write(import_sisteransi.cursor.move(0, o.length - n3 - 1));
649
729
  return;
650
730
  } else if (e.lines.length > 1) {
651
- if (i < n) o = i;
731
+ if (s < r2)
732
+ n3 = s;
652
733
  else {
653
- const h = o - n;
654
- h > 0 && this.output.write(import_sisteransi.cursor.move(0, h));
734
+ const h2 = n3 - r2;
735
+ h2 > 0 && this.output.write(import_sisteransi.cursor.move(0, h2));
655
736
  }
656
737
  this.output.write(import_sisteransi.erase.down());
657
- const a = t2.split(`
658
- `).slice(o);
659
- this.output.write(a.join(`
738
+ const f = t2.split(`
739
+ `).slice(n3);
740
+ this.output.write(f.join(`
660
741
  `)), this._prevFrame = t2;
661
742
  return;
662
743
  }
@@ -667,27 +748,28 @@ var init_dist3 = __esm({
667
748
  }
668
749
  }
669
750
  };
670
- nt = class extends p {
751
+ n$1 = class n extends y {
671
752
  options;
672
753
  cursor = 0;
673
754
  get _selectedValue() {
674
755
  return this.options[this.cursor];
675
756
  }
676
757
  changeValue() {
677
- this.value = this._selectedValue.value;
678
- }
679
- constructor(t2) {
680
- super(t2, false), this.options = t2.options;
681
- const e = this.options.findIndex(({ value: i }) => i === t2.initialValue), s = e === -1 ? 0 : e;
682
- this.cursor = this.options[s].disabled ? d(s, 1, this.options) : s, this.changeValue(), this.on("cursor", (i) => {
683
- switch (i) {
758
+ const e = this._selectedValue;
759
+ this.value = e === void 0 ? void 0 : e.value;
760
+ }
761
+ constructor(e) {
762
+ super(e, false), this.options = e.options;
763
+ const o = this.options.findIndex(({ value: s }) => s === e.initialValue), t2 = o === -1 ? 0 : o;
764
+ this.cursor = this.options[t2]?.disabled ? findCursor(t2, 1, this.options) : t2, this.changeValue(), this.on("cursor", (s) => {
765
+ switch (s) {
684
766
  case "left":
685
767
  case "up":
686
- this.cursor = d(this.cursor, -1, this.options);
768
+ this.cursor = findCursor(this.cursor, -1, this.options);
687
769
  break;
688
770
  case "down":
689
771
  case "right":
690
- this.cursor = d(this.cursor, 1, this.options);
772
+ this.cursor = findCursor(this.cursor, 1, this.options);
691
773
  break;
692
774
  }
693
775
  this.changeValue();
@@ -697,206 +779,323 @@ var init_dist3 = __esm({
697
779
  }
698
780
  });
699
781
 
700
- // node_modules/.bun/@clack+prompts@1.2.0/node_modules/@clack/prompts/dist/index.mjs
701
- import { styleText as t, stripVTControlCharacters as ne } from "node:util";
702
- import P2 from "node:process";
703
- import { existsSync as Xe, lstatSync as we, readdirSync as ze } from "node:fs";
704
- import { dirname as be, join as Qe } from "node:path";
705
- function Ze() {
706
- return P2.platform !== "win32" ? P2.env.TERM !== "linux" : !!P2.env.CI || !!P2.env.WT_SESSION || !!P2.env.TERMINUS_SUBLIME || P2.env.ConEmuTask === "{cmd::Cmder}" || P2.env.TERM_PROGRAM === "Terminus-Sublime" || P2.env.TERM_PROGRAM === "vscode" || P2.env.TERM === "xterm-256color" || P2.env.TERM === "alacritty" || P2.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
782
+ // node_modules/.bun/@clack+prompts@1.8.0/node_modules/@clack/prompts/dist/index.mjs
783
+ import { styleText as styleText2, stripVTControlCharacters } from "node:util";
784
+ import process$1 from "node:process";
785
+ import { existsSync, lstatSync, readdirSync } from "node:fs";
786
+ import { dirname, join } from "node:path";
787
+ function isUnicodeSupported() {
788
+ if (process$1.platform !== "win32") {
789
+ return process$1.env.TERM !== "linux";
790
+ }
791
+ return Boolean(process$1.env.CI) || Boolean(process$1.env.WT_SESSION) || Boolean(process$1.env.TERMINUS_SUBLIME) || process$1.env.ConEmuTask === "{cmd::Cmder}" || process$1.env.TERM_PROGRAM === "Terminus-Sublime" || process$1.env.TERM_PROGRAM === "vscode" || process$1.env.TERM === "xterm-256color" || process$1.env.TERM === "alacritty" || process$1.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
792
+ }
793
+ function formatInstructionFooter(o, e) {
794
+ const r2 = [`${e ? `${styleText2("cyan", S_BAR)} ` : ""}${o.join(" \u2022 ")}`];
795
+ return e && r2.push(styleText2("cyan", S_BAR_END)), r2;
707
796
  }
708
- var import_sisteransi2, ee, w2, _e, oe, ue, F, le, d2, E2, Ie, Ee, z2, H2, te, U, J, xe, se, ce, Ge, $e, de, Oe, he, pe, me, ge, V2, ye, et2, Y2, O2, pt, ft, vt, wt, Ve, re, _t, je;
797
+ var import_sisteransi2, unicode, unicodeOr, S_STEP_ACTIVE, S_STEP_CANCEL, S_STEP_ERROR, S_STEP_SUBMIT, S_BAR_START, S_BAR, S_BAR_END, S_BAR_START_RIGHT, S_BAR_END_RIGHT, S_RADIO_ACTIVE, S_RADIO_INACTIVE, S_CHECKBOX_ACTIVE, S_CHECKBOX_SELECTED, S_CHECKBOX_INACTIVE, S_PASSWORD_MASK, S_BAR_H, S_CORNER_TOP_RIGHT, S_CONNECT_LEFT, S_CORNER_BOTTOM_RIGHT, S_CORNER_BOTTOM_LEFT, S_CORNER_TOP_LEFT, S_INFO, S_SUCCESS, S_WARN, S_ERROR, symbol, symbolBar, I, limitOptions, MULTISELECT_INSTRUCTIONS, log, cancel, W$1, C, note, u2, SELECT_INSTRUCTIONS, c, select, i;
709
798
  var init_dist4 = __esm({
710
- "node_modules/.bun/@clack+prompts@1.2.0/node_modules/@clack/prompts/dist/index.mjs"() {
799
+ "node_modules/.bun/@clack+prompts@1.8.0/node_modules/@clack/prompts/dist/index.mjs"() {
711
800
  init_utils2();
712
801
  init_dist3();
713
802
  init_dist3();
714
803
  init_main();
715
804
  init_dist2();
716
805
  import_sisteransi2 = __toESM(require_src(), 1);
717
- ee = Ze();
718
- w2 = (e, i) => ee ? e : i;
719
- _e = w2("\u25C6", "*");
720
- oe = w2("\u25A0", "x");
721
- ue = w2("\u25B2", "x");
722
- F = w2("\u25C7", "o");
723
- le = w2("\u250C", "T");
724
- d2 = w2("\u2502", "|");
725
- E2 = w2("\u2514", "\u2014");
726
- Ie = w2("\u2510", "T");
727
- Ee = w2("\u2518", "\u2014");
728
- z2 = w2("\u25CF", ">");
729
- H2 = w2("\u25CB", " ");
730
- te = w2("\u25FB", "[\u2022]");
731
- U = w2("\u25FC", "[+]");
732
- J = w2("\u25FB", "[ ]");
733
- xe = w2("\u25AA", "\u2022");
734
- se = w2("\u2500", "-");
735
- ce = w2("\u256E", "+");
736
- Ge = w2("\u251C", "+");
737
- $e = w2("\u256F", "+");
738
- de = w2("\u2570", "+");
739
- Oe = w2("\u256D", "+");
740
- he = w2("\u25CF", "\u2022");
741
- pe = w2("\u25C6", "*");
742
- me = w2("\u25B2", "!");
743
- ge = w2("\u25A0", "x");
744
- V2 = (e) => {
745
- switch (e) {
806
+ unicode = isUnicodeSupported();
807
+ unicodeOr = (o, e) => unicode ? o : e;
808
+ S_STEP_ACTIVE = unicodeOr("\u25C6", "*");
809
+ S_STEP_CANCEL = unicodeOr("\u25A0", "x");
810
+ S_STEP_ERROR = unicodeOr("\u25B2", "x");
811
+ S_STEP_SUBMIT = unicodeOr("\u25C7", "o");
812
+ S_BAR_START = unicodeOr("\u250C", "T");
813
+ S_BAR = unicodeOr("\u2502", "|");
814
+ S_BAR_END = unicodeOr("\u2514", "\u2014");
815
+ S_BAR_START_RIGHT = unicodeOr("\u2510", "T");
816
+ S_BAR_END_RIGHT = unicodeOr("\u2518", "\u2014");
817
+ S_RADIO_ACTIVE = unicodeOr("\u25CF", ">");
818
+ S_RADIO_INACTIVE = unicodeOr("\u25CB", " ");
819
+ S_CHECKBOX_ACTIVE = unicodeOr("\u25FB", "[\u2022]");
820
+ S_CHECKBOX_SELECTED = unicodeOr("\u25FC", "[+]");
821
+ S_CHECKBOX_INACTIVE = unicodeOr("\u25FB", "[ ]");
822
+ S_PASSWORD_MASK = unicodeOr("\u25AA", "\u2022");
823
+ S_BAR_H = unicodeOr("\u2500", "-");
824
+ S_CORNER_TOP_RIGHT = unicodeOr("\u256E", "+");
825
+ S_CONNECT_LEFT = unicodeOr("\u251C", "+");
826
+ S_CORNER_BOTTOM_RIGHT = unicodeOr("\u256F", "+");
827
+ S_CORNER_BOTTOM_LEFT = unicodeOr("\u2570", "+");
828
+ S_CORNER_TOP_LEFT = unicodeOr("\u256D", "+");
829
+ S_INFO = unicodeOr("\u25CF", "\u2022");
830
+ S_SUCCESS = unicodeOr("\u25C6", "*");
831
+ S_WARN = unicodeOr("\u25B2", "!");
832
+ S_ERROR = unicodeOr("\u25A0", "x");
833
+ symbol = (o) => {
834
+ switch (o) {
746
835
  case "initial":
747
836
  case "active":
748
- return t("cyan", _e);
837
+ return styleText2("cyan", S_STEP_ACTIVE);
749
838
  case "cancel":
750
- return t("red", oe);
839
+ return styleText2("red", S_STEP_CANCEL);
751
840
  case "error":
752
- return t("yellow", ue);
841
+ return styleText2("yellow", S_STEP_ERROR);
753
842
  case "submit":
754
- return t("green", F);
843
+ return styleText2("green", S_STEP_SUBMIT);
844
+ case "validating":
845
+ return styleText2("dim", S_STEP_ACTIVE);
755
846
  }
756
847
  };
757
- ye = (e) => {
758
- switch (e) {
848
+ symbolBar = (o) => {
849
+ switch (o) {
759
850
  case "initial":
760
851
  case "active":
761
- return t("cyan", d2);
852
+ return styleText2("cyan", S_BAR);
762
853
  case "cancel":
763
- return t("red", d2);
854
+ return styleText2("red", S_BAR);
764
855
  case "error":
765
- return t("yellow", d2);
856
+ return styleText2("yellow", S_BAR);
766
857
  case "submit":
767
- return t("green", d2);
768
- }
769
- };
770
- et2 = (e, i, s, r, u2) => {
771
- let n = i, o = 0;
772
- for (let c2 = s; c2 < r; c2++) {
773
- const a = e[c2];
774
- if (n = n - a.length, o++, n <= u2) break;
775
- }
776
- return { lineCount: n, removals: o };
777
- };
778
- Y2 = ({ cursor: e, options: i, style: s, output: r = process.stdout, maxItems: u2 = Number.POSITIVE_INFINITY, columnPadding: n = 0, rowPadding: o = 4 }) => {
779
- const c2 = O(r) - n, a = A(r), l = t("dim", "..."), $2 = Math.max(a - o, 0), y2 = Math.max(Math.min(u2, $2), 5);
780
- let p2 = 0;
781
- e >= y2 - 3 && (p2 = Math.max(Math.min(e - y2 + 3, i.length - y2), 0));
782
- let m = y2 < i.length && p2 > 0, g = y2 < i.length && p2 + y2 < i.length;
783
- const S2 = Math.min(p2 + y2, i.length), h = [];
858
+ return styleText2("green", S_BAR);
859
+ }
860
+ };
861
+ I = (l, e, w, p, b, C2 = false) => {
862
+ let r2 = e, O = 0;
863
+ if (C2)
864
+ for (let i2 = p - 1; i2 >= w; i2--) {
865
+ const m = l[i2];
866
+ if (m && (r2 -= m.length), O++, r2 <= b) break;
867
+ }
868
+ else
869
+ for (let i2 = w; i2 < p; i2++) {
870
+ const m = l[i2];
871
+ if (m && (r2 -= m.length), O++, r2 <= b) break;
872
+ }
873
+ return { lineCount: r2, removals: O };
874
+ };
875
+ limitOptions = ({
876
+ cursor: l,
877
+ options: e,
878
+ style: w,
879
+ output: p = process.stdout,
880
+ maxItems: b = Number.POSITIVE_INFINITY,
881
+ columnPadding: C2 = 0,
882
+ rowPadding: r2 = 4
883
+ }) => {
884
+ const i2 = getColumns(p) - C2, m = getRows(p), M = styleText2("dim", "..."), v = Math.max(m - r2, 0), a2 = Math.max(Math.min(b, v), 5);
784
885
  let f = 0;
785
- m && f++, g && f++;
786
- const v = p2 + (m ? 1 : 0), T = S2 - (g ? 1 : 0);
787
- for (let b = v; b < T; b++) {
788
- const x = wrapAnsi(s(i[b], b === e), c2, { hard: true, trim: false }).split(`
886
+ l >= a2 - 3 && (f = Math.max(
887
+ Math.min(l - a2 + 3, e.length - a2),
888
+ 0
889
+ ));
890
+ let d = a2 < e.length && f > 0, c2 = a2 < e.length && f + a2 < e.length;
891
+ const W = Math.min(
892
+ f + a2,
893
+ e.length
894
+ ), s = [];
895
+ let g = 0;
896
+ d && g++, c2 && g++;
897
+ const T = f + (d ? 1 : 0), y2 = W - (c2 ? 1 : 0);
898
+ for (let t2 = T; t2 < y2; t2++) {
899
+ const n3 = e[t2], o = n3 ? w(n3, t2 === l) : "", h2 = wrapAnsi(o, i2, {
900
+ hard: true,
901
+ trim: false
902
+ }).split(`
789
903
  `);
790
- h.push(x), f += x.length;
791
- }
792
- if (f > $2) {
793
- let b = 0, x = 0, G2 = f;
794
- const M2 = e - v, R2 = (j2, D2) => et2(h, G2, j2, D2, $2);
795
- m ? ({ lineCount: G2, removals: b } = R2(0, M2), G2 > $2 && ({ lineCount: G2, removals: x } = R2(M2 + 1, h.length))) : ({ lineCount: G2, removals: x } = R2(M2 + 1, h.length), G2 > $2 && ({ lineCount: G2, removals: b } = R2(0, M2))), b > 0 && (m = true, h.splice(0, b)), x > 0 && (g = true, h.splice(h.length - x, x));
796
- }
797
- const C2 = [];
798
- m && C2.push(l);
799
- for (const b of h) for (const x of b) C2.push(x);
800
- return g && C2.push(l), C2;
801
- };
802
- O2 = { message: (e = [], { symbol: i = t("gray", d2), secondarySymbol: s = t("gray", d2), output: r = process.stdout, spacing: u2 = 1, withGuide: n } = {}) => {
803
- const o = [], c2 = n ?? u.withGuide, a = c2 ? s : "", l = c2 ? `${i} ` : "", $2 = c2 ? `${s} ` : "";
804
- for (let p2 = 0; p2 < u2; p2++) o.push(a);
805
- const y2 = Array.isArray(e) ? e : e.split(`
904
+ s.push(h2), g += h2.length;
905
+ }
906
+ if (g > v) {
907
+ let t2 = 0, n3 = 0, o = g;
908
+ const h2 = l - T;
909
+ let u3 = v;
910
+ const L = () => I(s, o, 0, h2, u3), E = () => I(
911
+ s,
912
+ o,
913
+ h2 + 1,
914
+ s.length,
915
+ u3,
916
+ true
917
+ );
918
+ d ? ({ lineCount: o, removals: t2 } = L(), o > u3 && (c2 || (u3 -= 1), { lineCount: o, removals: n3 } = E())) : (c2 || (u3 -= 1), { lineCount: o, removals: n3 } = E(), o > u3 && (u3 -= 1, { lineCount: o, removals: t2 } = L())), t2 > 0 && (d = true, s.splice(0, t2)), n3 > 0 && (c2 = true, s.splice(s.length - n3, n3));
919
+ }
920
+ const x = [];
921
+ d && x.push(M);
922
+ for (const t2 of s)
923
+ for (const n3 of t2)
924
+ x.push(n3);
925
+ return c2 && x.push(M), x;
926
+ };
927
+ MULTISELECT_INSTRUCTIONS = [
928
+ `${styleText2("dim", "\u2191/\u2193")} to navigate`,
929
+ `${styleText2("dim", "Space:")} select`,
930
+ `${styleText2("dim", "Enter:")} confirm`
931
+ ];
932
+ log = {
933
+ message: (s = [], {
934
+ symbol: e = styleText2("gray", S_BAR),
935
+ secondarySymbol: r2 = styleText2("gray", S_BAR),
936
+ output: m = process.stdout,
937
+ spacing: l = 1,
938
+ withGuide: c2
939
+ } = {}) => {
940
+ const t2 = [], o = c2 ?? settings.withGuide, f = o ? r2 : "", O = o ? `${e} ` : "", u3 = o ? `${r2} ` : "";
941
+ for (let i2 = 0; i2 < l; i2++)
942
+ t2.push(f);
943
+ const g = Array.isArray(s) ? s : s.split(`
806
944
  `);
807
- if (y2.length > 0) {
808
- const [p2, ...m] = y2;
809
- p2.length > 0 ? o.push(`${l}${p2}`) : o.push(c2 ? i : "");
810
- for (const g of m) g.length > 0 ? o.push(`${$2}${g}`) : o.push(c2 ? s : "");
811
- }
812
- r.write(`${o.join(`
945
+ if (g.length > 0) {
946
+ const [i2, ...y2] = g;
947
+ i2.length > 0 ? t2.push(`${O}${i2}`) : t2.push(o ? e : "");
948
+ for (const p of y2)
949
+ p.length > 0 ? t2.push(`${u3}${p}`) : t2.push(o ? r2 : "");
950
+ }
951
+ m.write(`${t2.join(`
813
952
  `)}
814
953
  `);
815
- }, info: (e, i) => {
816
- O2.message(e, { ...i, symbol: t("blue", he) });
817
- }, success: (e, i) => {
818
- O2.message(e, { ...i, symbol: t("green", pe) });
819
- }, step: (e, i) => {
820
- O2.message(e, { ...i, symbol: t("green", F) });
821
- }, warn: (e, i) => {
822
- O2.message(e, { ...i, symbol: t("yellow", me) });
823
- }, warning: (e, i) => {
824
- O2.warn(e, i);
825
- }, error: (e, i) => {
826
- O2.message(e, { ...i, symbol: t("red", ge) });
827
- } };
828
- pt = (e = "", i) => {
829
- const s = i?.output ?? process.stdout, r = i?.withGuide ?? u.withGuide ? `${t("gray", E2)} ` : "";
830
- s.write(`${r}${t("red", e)}
954
+ },
955
+ info: (s, e) => {
956
+ log.message(s, { ...e, symbol: styleText2("blue", S_INFO) });
957
+ },
958
+ success: (s, e) => {
959
+ log.message(s, { ...e, symbol: styleText2("green", S_SUCCESS) });
960
+ },
961
+ step: (s, e) => {
962
+ log.message(s, { ...e, symbol: styleText2("green", S_STEP_SUBMIT) });
963
+ },
964
+ warn: (s, e) => {
965
+ log.message(s, { ...e, symbol: styleText2("yellow", S_WARN) });
966
+ },
967
+ /** alias for `log.warn()`. */
968
+ warning: (s, e) => {
969
+ log.warn(s, e);
970
+ },
971
+ error: (s, e) => {
972
+ log.message(s, { ...e, symbol: styleText2("red", S_ERROR) });
973
+ }
974
+ };
975
+ cancel = (o = "", t2) => {
976
+ const i2 = t2?.output ?? process.stdout, e = t2?.withGuide ?? settings.withGuide ? `${styleText2("gray", S_BAR_END)} ` : "";
977
+ i2.write(`${e}${styleText2("red", o)}
831
978
 
832
979
  `);
833
980
  };
834
- ft = (e) => t("dim", e);
835
- vt = (e, i, s) => {
836
- const r = { hard: true, trim: false }, u2 = wrapAnsi(e, i, r).split(`
837
- `), n = u2.reduce((a, l) => Math.max(dist_default2(l), a), 0), o = u2.map(s).reduce((a, l) => Math.max(dist_default2(l), a), 0), c2 = i - (o - n);
838
- return wrapAnsi(e, c2, r);
839
- };
840
- wt = (e = "", i = "", s) => {
841
- const r = s?.output ?? P2.stdout, u2 = s?.withGuide ?? u.withGuide, n = s?.format ?? ft, o = ["", ...vt(e, O(r) - 6, n).split(`
842
- `).map(n), ""], c2 = dist_default2(i), a = Math.max(o.reduce((p2, m) => {
843
- const g = dist_default2(m);
844
- return g > p2 ? g : p2;
845
- }, 0), c2) + 2, l = o.map((p2) => `${t("gray", d2)} ${p2}${" ".repeat(a - dist_default2(p2))}${t("gray", d2)}`).join(`
846
- `), $2 = u2 ? `${t("gray", d2)}
847
- ` : "", y2 = u2 ? Ge : de;
848
- r.write(`${$2}${t("green", F)} ${t("reset", i)} ${t("gray", se.repeat(Math.max(a - c2 - 1, 1)) + ce)}
849
- ${l}
850
- ${t("gray", y2 + se.repeat(a + 2) + $e)}
851
- `);
981
+ W$1 = (o) => o;
982
+ C = (o, e, s) => {
983
+ const a2 = {
984
+ hard: true,
985
+ trim: false
986
+ }, i2 = wrapAnsi(o, e, a2).split(`
987
+ `), c2 = i2.reduce((n3, t2) => Math.max(dist_default2(t2), n3), 0), u3 = i2.map(s).reduce((n3, t2) => Math.max(dist_default2(t2), n3), 0), g = e - (u3 - c2);
988
+ return wrapAnsi(o, g, a2);
989
+ };
990
+ note = (o = "", e = "", s) => {
991
+ const a2 = s?.output ?? process$1.stdout, i2 = s?.withGuide ?? settings.withGuide, c2 = s?.format ?? W$1, g = ["", ...C(o, getColumns(a2) - 6, c2).split(`
992
+ `).map(c2), ""], n3 = dist_default2(e), t2 = Math.max(
993
+ g.reduce((m, F) => {
994
+ const O = dist_default2(F);
995
+ return O > m ? O : m;
996
+ }, 0),
997
+ n3
998
+ ) + 2, h2 = g.map(
999
+ (m) => `${styleText2("gray", S_BAR)} ${m}${" ".repeat(t2 - dist_default2(m))}${styleText2("gray", S_BAR)}`
1000
+ ).join(`
1001
+ `), T = i2 ? `${styleText2("gray", S_BAR)}
1002
+ ` : "", l$1 = i2 ? S_CONNECT_LEFT : S_CORNER_BOTTOM_LEFT;
1003
+ a2.write(
1004
+ `${T}${styleText2("green", S_STEP_SUBMIT)} ${styleText2("reset", e)} ${styleText2(
1005
+ "gray",
1006
+ S_BAR_H.repeat(Math.max(t2 - n3 - 1, 1)) + S_CORNER_TOP_RIGHT
1007
+ )}
1008
+ ${h2}
1009
+ ${styleText2("gray", l$1 + S_BAR_H.repeat(t2 + 2) + S_CORNER_BOTTOM_RIGHT)}
1010
+ `
1011
+ );
852
1012
  };
853
- Ve = { light: w2("\u2500", "-"), heavy: w2("\u2501", "="), block: w2("\u2588", "#") };
854
- re = (e, i) => e.includes(`
855
- `) ? e.split(`
856
- `).map((s) => i(s)).join(`
857
- `) : i(e);
858
- _t = (e) => {
859
- const i = (s, r) => {
860
- const u2 = s.label ?? String(s.value);
861
- switch (r) {
1013
+ u2 = {
1014
+ light: unicodeOr("\u2500", "-"),
1015
+ heavy: unicodeOr("\u2501", "="),
1016
+ block: unicodeOr("\u2588", "#")
1017
+ };
1018
+ SELECT_INSTRUCTIONS = [
1019
+ `${styleText2("dim", "\u2191/\u2193")} to navigate`,
1020
+ `${styleText2("dim", "Enter:")} confirm`
1021
+ ];
1022
+ c = (t2, o) => t2.includes(`
1023
+ `) ? t2.split(`
1024
+ `).map((d) => o(d)).join(`
1025
+ `) : o(t2);
1026
+ select = (t2) => {
1027
+ const o = (n3, m) => {
1028
+ if (n3 === void 0)
1029
+ return "";
1030
+ const s = n3.label ?? String(n3.value);
1031
+ switch (m) {
862
1032
  case "disabled":
863
- return `${t("gray", H2)} ${re(u2, (n) => t("gray", n))}${s.hint ? ` ${t("dim", `(${s.hint ?? "disabled"})`)}` : ""}`;
1033
+ return `${styleText2("gray", S_RADIO_INACTIVE)} ${c(s, (i2) => styleText2("gray", i2))}${n3.hint ? ` ${styleText2("dim", `(${n3.hint ?? "disabled"})`)}` : ""}`;
864
1034
  case "selected":
865
- return `${re(u2, (n) => t("dim", n))}`;
1035
+ return `${c(s, (i2) => styleText2("dim", i2))}`;
866
1036
  case "active":
867
- return `${t("green", z2)} ${u2}${s.hint ? ` ${t("dim", `(${s.hint})`)}` : ""}`;
1037
+ return `${styleText2("green", S_RADIO_ACTIVE)} ${s}${n3.hint ? ` ${styleText2("dim", `(${n3.hint})`)}` : ""}`;
868
1038
  case "cancelled":
869
- return `${re(u2, (n) => t(["strikethrough", "dim"], n))}`;
1039
+ return `${c(s, (i2) => styleText2(["strikethrough", "dim"], i2))}`;
870
1040
  default:
871
- return `${t("dim", H2)} ${re(u2, (n) => t("dim", n))}`;
872
- }
873
- };
874
- return new nt({ options: e.options, signal: e.signal, input: e.input, output: e.output, initialValue: e.initialValue, render() {
875
- const s = e.withGuide ?? u.withGuide, r = `${V2(this.state)} `, u2 = `${ye(this.state)} `, n = R(e.output, e.message, u2, r), o = `${s ? `${t("gray", d2)}
876
- ` : ""}${n}
1041
+ return `${styleText2("dim", S_RADIO_INACTIVE)} ${c(s, (i2) => styleText2("dim", i2))}`;
1042
+ }
1043
+ }, d = t2.showInstructions ?? true;
1044
+ return new n$1({
1045
+ options: t2.options,
1046
+ signal: t2.signal,
1047
+ input: t2.input,
1048
+ output: t2.output,
1049
+ initialValue: t2.initialValue,
1050
+ render() {
1051
+ const n3 = t2.withGuide ?? settings.withGuide, m = `${symbol(this.state)} `, s = `${symbolBar(this.state)} `, i2 = wrapTextWithPrefix(
1052
+ t2.output,
1053
+ t2.message,
1054
+ s,
1055
+ m
1056
+ ), u3 = `${n3 ? `${styleText2("gray", S_BAR)}
1057
+ ` : ""}${i2}
877
1058
  `;
878
- switch (this.state) {
879
- case "submit": {
880
- const c2 = s ? `${t("gray", d2)} ` : "", a = R(e.output, i(this.options[this.cursor], "selected"), c2);
881
- return `${o}${a}`;
882
- }
883
- case "cancel": {
884
- const c2 = s ? `${t("gray", d2)} ` : "", a = R(e.output, i(this.options[this.cursor], "cancelled"), c2);
885
- return `${o}${a}${s ? `
886
- ${t("gray", d2)}` : ""}`;
887
- }
888
- default: {
889
- const c2 = s ? `${t("cyan", d2)} ` : "", a = s ? t("cyan", E2) : "", l = o.split(`
890
- `).length, $2 = s ? 2 : 1;
891
- return `${o}${c2}${Y2({ output: e.output, cursor: this.cursor, options: this.options, maxItems: e.maxItems, columnPadding: c2.length, rowPadding: l + $2, style: (y2, p2) => i(y2, y2.disabled ? "disabled" : p2 ? "active" : "inactive") }).join(`
892
- ${c2}`)}
893
- ${a}
1059
+ switch (this.state) {
1060
+ case "submit": {
1061
+ const r2 = n3 ? `${styleText2("gray", S_BAR)} ` : "", a2 = wrapTextWithPrefix(
1062
+ t2.output,
1063
+ o(this.options[this.cursor], "selected"),
1064
+ r2
1065
+ );
1066
+ return `${u3}${a2}`;
1067
+ }
1068
+ case "cancel": {
1069
+ const r2 = n3 ? `${styleText2("gray", S_BAR)} ` : "", a2 = wrapTextWithPrefix(
1070
+ t2.output,
1071
+ o(this.options[this.cursor], "cancelled"),
1072
+ r2
1073
+ );
1074
+ return `${u3}${a2}${n3 ? `
1075
+ ${styleText2("gray", S_BAR)}` : ""}`;
1076
+ }
1077
+ default: {
1078
+ const r2 = n3 ? `${styleText2("cyan", S_BAR)} ` : "", a2 = u3.split(`
1079
+ `).length, p = d ? formatInstructionFooter(SELECT_INSTRUCTIONS, n3) : n3 ? [styleText2("cyan", S_BAR_END)] : [], b = p.join(`
1080
+ `), f = p.length + 1;
1081
+ return `${u3}${r2}${limitOptions({
1082
+ output: t2.output,
1083
+ cursor: this.cursor,
1084
+ options: this.options,
1085
+ maxItems: t2.maxItems,
1086
+ columnPadding: r2.length,
1087
+ rowPadding: a2 + f,
1088
+ style: (g, x) => o(g, g.disabled ? "disabled" : x ? "active" : "inactive")
1089
+ }).join(`
1090
+ ${r2}`)}
1091
+ ${b}
894
1092
  `;
1093
+ }
895
1094
  }
896
1095
  }
897
- } }).prompt();
1096
+ }).prompt();
898
1097
  };
899
- je = `${t("gray", d2)} `;
1098
+ i = `${styleText2("gray", S_BAR)} `;
900
1099
  }
901
1100
  });
902
1101
 
@@ -909,9 +1108,9 @@ function supportsColor() {
909
1108
  }
910
1109
  return process.stdout.isTTY === true;
911
1110
  }
912
- function colorize(text, color) {
913
- if (!supportsColor()) return text;
914
- return `${color}${text}${colors.reset}`;
1111
+ function colorize(text2, color) {
1112
+ if (!supportsColor()) return text2;
1113
+ return `${color}${text2}${colors.reset}`;
915
1114
  }
916
1115
  function stringify(value) {
917
1116
  if (typeof value === "string") return value;
@@ -941,7 +1140,7 @@ function stringify(value) {
941
1140
  function formatMessage(...args) {
942
1141
  return args.map(stringify).join(" ");
943
1142
  }
944
- var colors, currentLogLevel, log, error, warn, info, success;
1143
+ var colors, currentLogLevel, log2, error, warn, info, success;
945
1144
  var init_cli_output = __esm({
946
1145
  "packages/tooling/src/utils/cli-output.ts"() {
947
1146
  "use strict";
@@ -974,7 +1173,7 @@ var init_cli_output = __esm({
974
1173
  currentLogLevel = envLevel;
975
1174
  }
976
1175
  }
977
- log = {
1176
+ log2 = {
978
1177
  /**
979
1178
  * Logs an error message (always shows unless Quiet level)
980
1179
  * Uses clack's log.error + explicit red color
@@ -982,7 +1181,7 @@ var init_cli_output = __esm({
982
1181
  error(...args) {
983
1182
  if (currentLogLevel < 0 /* Quiet */) return;
984
1183
  const message = formatMessage(...args);
985
- O2.error(colorize(message, colors.brightRed));
1184
+ log.error(colorize(message, colors.brightRed));
986
1185
  },
987
1186
  /**
988
1187
  * Logs a warning message (shows at Normal level and above)
@@ -991,7 +1190,7 @@ var init_cli_output = __esm({
991
1190
  warn(...args) {
992
1191
  if (currentLogLevel < 1 /* Normal */) return;
993
1192
  const message = formatMessage(...args);
994
- O2.warn(colorize(message, colors.brightYellow));
1193
+ log.warn(colorize(message, colors.brightYellow));
995
1194
  },
996
1195
  /**
997
1196
  * Logs an info message (shows at Normal level and above)
@@ -1000,7 +1199,7 @@ var init_cli_output = __esm({
1000
1199
  info(...args) {
1001
1200
  if (currentLogLevel < 1 /* Normal */) return;
1002
1201
  const message = formatMessage(...args);
1003
- O2.info(colorize(message, colors.brightCyan));
1202
+ log.info(colorize(message, colors.brightCyan));
1004
1203
  },
1005
1204
  /**
1006
1205
  * Logs a success message (shows at Normal level and above)
@@ -1009,7 +1208,7 @@ var init_cli_output = __esm({
1009
1208
  success(...args) {
1010
1209
  if (currentLogLevel < 1 /* Normal */) return;
1011
1210
  const message = formatMessage(...args);
1012
- O2.success(colorize(message, colors.brightGreen));
1211
+ log.success(colorize(message, colors.brightGreen));
1013
1212
  },
1014
1213
  /**
1015
1214
  * Logs a debug message (only shows at Verbose level and above)
@@ -1018,7 +1217,7 @@ var init_cli_output = __esm({
1018
1217
  debug(...args) {
1019
1218
  if (currentLogLevel < 2 /* Verbose */) return;
1020
1219
  const timeStamp = (/* @__PURE__ */ new Date()).toISOString().slice(11, 19);
1021
- O2.message(
1220
+ log.message(
1022
1221
  colorize(
1023
1222
  `[${timeStamp}] \u{1F50D} DEBUG: ${formatMessage(...args)}`,
1024
1223
  colors.gray
@@ -1032,7 +1231,7 @@ var init_cli_output = __esm({
1032
1231
  trace(...args) {
1033
1232
  if (currentLogLevel < 3 /* Debug */) return;
1034
1233
  const timeStamp = (/* @__PURE__ */ new Date()).toISOString().slice(11, 19);
1035
- O2.message(
1234
+ log.message(
1036
1235
  colorize(
1037
1236
  `[${timeStamp}] \u{1F52C} TRACE: ${formatMessage(...args)}`,
1038
1237
  colors.gray
@@ -1040,10 +1239,10 @@ var init_cli_output = __esm({
1040
1239
  );
1041
1240
  }
1042
1241
  };
1043
- error = log.error.bind(log);
1044
- warn = log.warn.bind(log);
1045
- info = log.info.bind(log);
1046
- success = log.success.bind(log);
1242
+ error = log2.error.bind(log2);
1243
+ warn = log2.warn.bind(log2);
1244
+ info = log2.info.bind(log2);
1245
+ success = log2.success.bind(log2);
1047
1246
  }
1048
1247
  });
1049
1248
 
@@ -1403,9 +1602,9 @@ var require_is_glob = __commonJS({
1403
1602
  index += 2;
1404
1603
  var close = chars[open];
1405
1604
  if (close) {
1406
- var n = str.indexOf(close, index);
1407
- if (n !== -1) {
1408
- index = n + 1;
1605
+ var n3 = str.indexOf(close, index);
1606
+ if (n3 !== -1) {
1607
+ index = n3 + 1;
1409
1608
  }
1410
1609
  }
1411
1610
  if (str[index] === "!") {
@@ -1431,9 +1630,9 @@ var require_is_glob = __commonJS({
1431
1630
  index += 2;
1432
1631
  var close = chars[open];
1433
1632
  if (close) {
1434
- var n = str.indexOf(close, index);
1435
- if (n !== -1) {
1436
- index = n + 1;
1633
+ var n3 = str.indexOf(close, index);
1634
+ if (n3 !== -1) {
1635
+ index = n3 + 1;
1437
1636
  }
1438
1637
  }
1439
1638
  if (str[index] === "!") {
@@ -1511,8 +1710,8 @@ var require_utils = __commonJS({
1511
1710
  if (!exports.isInteger(min) || !exports.isInteger(max)) return false;
1512
1711
  return (Number(max) - Number(min)) / Number(step) >= limit;
1513
1712
  };
1514
- exports.escapeNode = (block, n = 0, type) => {
1515
- const node = block.nodes[n];
1713
+ exports.escapeNode = (block2, n3 = 0, type) => {
1714
+ const node = block2.nodes[n3];
1516
1715
  if (!node) return;
1517
1716
  if (type && node.type === type || node.type === "open" || node.type === "close") {
1518
1717
  if (node.escaped !== true) {
@@ -1529,15 +1728,15 @@ var require_utils = __commonJS({
1529
1728
  }
1530
1729
  return false;
1531
1730
  };
1532
- exports.isInvalidBrace = (block) => {
1533
- if (block.type !== "brace") return false;
1534
- if (block.invalid === true || block.dollar) return true;
1535
- if (block.commas >> 0 + block.ranges >> 0 === 0) {
1536
- block.invalid = true;
1731
+ exports.isInvalidBrace = (block2) => {
1732
+ if (block2.type !== "brace") return false;
1733
+ if (block2.invalid === true || block2.dollar) return true;
1734
+ if (block2.commas >> 0 + block2.ranges >> 0 === 0) {
1735
+ block2.invalid = true;
1537
1736
  return true;
1538
1737
  }
1539
- if (block.open !== true || block.close !== true) {
1540
- block.invalid = true;
1738
+ if (block2.open !== true || block2.close !== true) {
1739
+ block2.invalid = true;
1541
1740
  return true;
1542
1741
  }
1543
1742
  return false;
@@ -1556,8 +1755,8 @@ var require_utils = __commonJS({
1556
1755
  exports.flatten = (...args) => {
1557
1756
  const result = [];
1558
1757
  const flat = (arr) => {
1559
- for (let i = 0; i < arr.length; i++) {
1560
- const ele = arr[i];
1758
+ for (let i2 = 0; i2 < arr.length; i2++) {
1759
+ const ele = arr[i2];
1561
1760
  if (Array.isArray(ele)) {
1562
1761
  flat(ele);
1563
1762
  continue;
@@ -1651,9 +1850,9 @@ var require_to_regex_range = __commonJS({
1651
1850
  if (toRegexRange.cache.hasOwnProperty(cacheKey)) {
1652
1851
  return toRegexRange.cache[cacheKey].result;
1653
1852
  }
1654
- let a = Math.min(min, max);
1853
+ let a2 = Math.min(min, max);
1655
1854
  let b = Math.max(min, max);
1656
- if (Math.abs(a - b) === 1) {
1855
+ if (Math.abs(a2 - b) === 1) {
1657
1856
  let result = min + "|" + max;
1658
1857
  if (opts.capture) {
1659
1858
  return `(${result})`;
@@ -1664,20 +1863,20 @@ var require_to_regex_range = __commonJS({
1664
1863
  return `(?:${result})`;
1665
1864
  }
1666
1865
  let isPadded = hasPadding(min) || hasPadding(max);
1667
- let state = { min, max, a, b };
1866
+ let state = { min, max, a: a2, b };
1668
1867
  let positives = [];
1669
1868
  let negatives = [];
1670
1869
  if (isPadded) {
1671
1870
  state.isPadded = isPadded;
1672
1871
  state.maxLen = String(state.max).length;
1673
1872
  }
1674
- if (a < 0) {
1873
+ if (a2 < 0) {
1675
1874
  let newMin = b < 0 ? Math.abs(b) : 1;
1676
- negatives = splitToPatterns(newMin, Math.abs(a), state, opts);
1677
- a = state.a = 0;
1875
+ negatives = splitToPatterns(newMin, Math.abs(a2), state, opts);
1876
+ a2 = state.a = 0;
1678
1877
  }
1679
1878
  if (b >= 0) {
1680
- positives = splitToPatterns(a, b, state, opts);
1879
+ positives = splitToPatterns(a2, b, state, opts);
1681
1880
  }
1682
1881
  state.negatives = negatives;
1683
1882
  state.positives = positives;
@@ -1725,8 +1924,8 @@ var require_to_regex_range = __commonJS({
1725
1924
  let digits = zipped.length;
1726
1925
  let pattern = "";
1727
1926
  let count = 0;
1728
- for (let i = 0; i < digits; i++) {
1729
- let [startDigit, stopDigit] = zipped[i];
1927
+ for (let i2 = 0; i2 < digits; i2++) {
1928
+ let [startDigit, stopDigit] = zipped[i2];
1730
1929
  if (startDigit === stopDigit) {
1731
1930
  pattern += startDigit;
1732
1931
  } else if (startDigit !== "0" || stopDigit !== "9") {
@@ -1745,8 +1944,8 @@ var require_to_regex_range = __commonJS({
1745
1944
  let tokens = [];
1746
1945
  let start = min;
1747
1946
  let prev;
1748
- for (let i = 0; i < ranges.length; i++) {
1749
- let max2 = ranges[i];
1947
+ for (let i2 = 0; i2 < ranges.length; i2++) {
1948
+ let max2 = ranges[i2];
1750
1949
  let obj = rangeToPattern(String(start), String(max2), options);
1751
1950
  let zeros = "";
1752
1951
  if (!tok.isPadded && prev && prev.pattern === obj.pattern) {
@@ -1781,13 +1980,13 @@ var require_to_regex_range = __commonJS({
1781
1980
  }
1782
1981
  return result;
1783
1982
  }
1784
- function zip(a, b) {
1983
+ function zip(a2, b) {
1785
1984
  let arr = [];
1786
- for (let i = 0; i < a.length; i++) arr.push([a[i], b[i]]);
1985
+ for (let i2 = 0; i2 < a2.length; i2++) arr.push([a2[i2], b[i2]]);
1787
1986
  return arr;
1788
1987
  }
1789
- function compare(a, b) {
1790
- return a > b ? 1 : b > a ? -1 : 0;
1988
+ function compare(a2, b) {
1989
+ return a2 > b ? 1 : b > a2 ? -1 : 0;
1791
1990
  }
1792
1991
  function contains(arr, key, val) {
1793
1992
  return arr.some((ele) => ele[key] === val);
@@ -1805,8 +2004,8 @@ var require_to_regex_range = __commonJS({
1805
2004
  }
1806
2005
  return "";
1807
2006
  }
1808
- function toCharacterClass(a, b, options) {
1809
- return `[${a}${b - a === 1 ? "" : "-"}${b}]`;
2007
+ function toCharacterClass(a2, b, options) {
2008
+ return `[${a2}${b - a2 === 1 ? "" : "-"}${b}]`;
1810
2009
  }
1811
2010
  function hasPadding(str) {
1812
2011
  return /^-?(0+)\d/.test(str);
@@ -1885,8 +2084,8 @@ var require_fill_range = __commonJS({
1885
2084
  return negative ? "-" + input : input;
1886
2085
  };
1887
2086
  var toSequence = (parts, options, maxLen) => {
1888
- parts.negatives.sort((a, b) => a < b ? -1 : a > b ? 1 : 0);
1889
- parts.positives.sort((a, b) => a < b ? -1 : a > b ? 1 : 0);
2087
+ parts.negatives.sort((a2, b) => a2 < b ? -1 : a2 > b ? 1 : 0);
2088
+ parts.positives.sort((a2, b) => a2 < b ? -1 : a2 > b ? 1 : 0);
1890
2089
  let prefix = options.capture ? "" : "?:";
1891
2090
  let positives = "";
1892
2091
  let negatives = "";
@@ -1907,12 +2106,12 @@ var require_fill_range = __commonJS({
1907
2106
  }
1908
2107
  return result;
1909
2108
  };
1910
- var toRange = (a, b, isNumbers, options) => {
2109
+ var toRange = (a2, b, isNumbers, options) => {
1911
2110
  if (isNumbers) {
1912
- return toRegexRange(a, b, { wrap: false, ...options });
2111
+ return toRegexRange(a2, b, { wrap: false, ...options });
1913
2112
  }
1914
- let start = String.fromCharCode(a);
1915
- if (a === b) return start;
2113
+ let start = String.fromCharCode(a2);
2114
+ if (a2 === b) return start;
1916
2115
  let stop = String.fromCharCode(b);
1917
2116
  return `[${start}-${stop}]`;
1918
2117
  };
@@ -1938,15 +2137,15 @@ var require_fill_range = __commonJS({
1938
2137
  return [];
1939
2138
  };
1940
2139
  var fillNumbers = (start, end, step = 1, options = {}) => {
1941
- let a = Number(start);
2140
+ let a2 = Number(start);
1942
2141
  let b = Number(end);
1943
- if (!Number.isInteger(a) || !Number.isInteger(b)) {
2142
+ if (!Number.isInteger(a2) || !Number.isInteger(b)) {
1944
2143
  if (options.strictRanges === true) throw rangeError([start, end]);
1945
2144
  return [];
1946
2145
  }
1947
- if (a === 0) a = 0;
2146
+ if (a2 === 0) a2 = 0;
1948
2147
  if (b === 0) b = 0;
1949
- let descending = a > b;
2148
+ let descending = a2 > b;
1950
2149
  let startString = String(start);
1951
2150
  let endString = String(end);
1952
2151
  let stepString = String(step);
@@ -1962,13 +2161,13 @@ var require_fill_range = __commonJS({
1962
2161
  let push = (num) => parts[num < 0 ? "negatives" : "positives"].push(Math.abs(num));
1963
2162
  let range = [];
1964
2163
  let index = 0;
1965
- while (descending ? a >= b : a <= b) {
2164
+ while (descending ? a2 >= b : a2 <= b) {
1966
2165
  if (options.toRegex === true && step > 1) {
1967
- push(a);
2166
+ push(a2);
1968
2167
  } else {
1969
- range.push(pad(format(a, index), maxLen, toNumber));
2168
+ range.push(pad(format(a2, index), maxLen, toNumber));
1970
2169
  }
1971
- a = descending ? a - step : a + step;
2170
+ a2 = descending ? a2 - step : a2 + step;
1972
2171
  index++;
1973
2172
  }
1974
2173
  if (options.toRegex === true) {
@@ -1981,19 +2180,19 @@ var require_fill_range = __commonJS({
1981
2180
  return invalidRange(start, end, options);
1982
2181
  }
1983
2182
  let format = options.transform || ((val) => String.fromCharCode(val));
1984
- let a = `${start}`.charCodeAt(0);
2183
+ let a2 = `${start}`.charCodeAt(0);
1985
2184
  let b = `${end}`.charCodeAt(0);
1986
- let descending = a > b;
1987
- let min = Math.min(a, b);
1988
- let max = Math.max(a, b);
2185
+ let descending = a2 > b;
2186
+ let min = Math.min(a2, b);
2187
+ let max = Math.max(a2, b);
1989
2188
  if (options.toRegex && step === 1) {
1990
2189
  return toRange(min, max, false, options);
1991
2190
  }
1992
2191
  let range = [];
1993
2192
  let index = 0;
1994
- while (descending ? a >= b : a <= b) {
1995
- range.push(format(a, index));
1996
- a = descending ? a - step : a + step;
2193
+ while (descending ? a2 >= b : a2 <= b) {
2194
+ range.push(format(a2, index));
2195
+ a2 = descending ? a2 - step : a2 + step;
1997
2196
  index++;
1998
2197
  }
1999
2198
  if (options.toRegex === true) {
@@ -2116,18 +2315,18 @@ var require_expand = __commonJS({
2116
2315
  const rangeLimit = options.rangeLimit === void 0 ? 1e3 : options.rangeLimit;
2117
2316
  const walk = (node, parent = {}) => {
2118
2317
  node.queue = [];
2119
- let p2 = parent;
2120
- let q2 = parent.queue;
2121
- while (p2.type !== "brace" && p2.type !== "root" && p2.parent) {
2122
- p2 = p2.parent;
2123
- q2 = p2.queue;
2318
+ let p = parent;
2319
+ let q = parent.queue;
2320
+ while (p.type !== "brace" && p.type !== "root" && p.parent) {
2321
+ p = p.parent;
2322
+ q = p.queue;
2124
2323
  }
2125
2324
  if (node.invalid || node.dollar) {
2126
- q2.push(append(q2.pop(), stringify2(node, options)));
2325
+ q.push(append(q.pop(), stringify2(node, options)));
2127
2326
  return;
2128
2327
  }
2129
2328
  if (node.type === "brace" && node.invalid !== true && node.nodes.length === 2) {
2130
- q2.push(append(q2.pop(), ["{}"]));
2329
+ q.push(append(q.pop(), ["{}"]));
2131
2330
  return;
2132
2331
  }
2133
2332
  if (node.nodes && node.ranges > 0) {
@@ -2139,26 +2338,26 @@ var require_expand = __commonJS({
2139
2338
  if (range.length === 0) {
2140
2339
  range = stringify2(node, options);
2141
2340
  }
2142
- q2.push(append(q2.pop(), range));
2341
+ q.push(append(q.pop(), range));
2143
2342
  node.nodes = [];
2144
2343
  return;
2145
2344
  }
2146
2345
  const enclose = utils.encloseBrace(node);
2147
2346
  let queue = node.queue;
2148
- let block = node;
2149
- while (block.type !== "brace" && block.type !== "root" && block.parent) {
2150
- block = block.parent;
2151
- queue = block.queue;
2347
+ let block2 = node;
2348
+ while (block2.type !== "brace" && block2.type !== "root" && block2.parent) {
2349
+ block2 = block2.parent;
2350
+ queue = block2.queue;
2152
2351
  }
2153
- for (let i = 0; i < node.nodes.length; i++) {
2154
- const child = node.nodes[i];
2352
+ for (let i2 = 0; i2 < node.nodes.length; i2++) {
2353
+ const child = node.nodes[i2];
2155
2354
  if (child.type === "comma" && node.type === "brace") {
2156
- if (i === 1) queue.push("");
2355
+ if (i2 === 1) queue.push("");
2157
2356
  queue.push("");
2158
2357
  continue;
2159
2358
  }
2160
2359
  if (child.type === "close") {
2161
- q2.push(append(q2.pop(), queue, enclose));
2360
+ q.push(append(q.pop(), queue, enclose));
2162
2361
  continue;
2163
2362
  }
2164
2363
  if (child.value && child.type !== "open") {
@@ -2325,7 +2524,7 @@ var require_parse = __commonJS({
2325
2524
  }
2326
2525
  const ast = { type: "root", input, nodes: [] };
2327
2526
  const stack = [ast];
2328
- let block = ast;
2527
+ let block2 = ast;
2329
2528
  let prev = ast;
2330
2529
  let brackets = 0;
2331
2530
  const length = input.length;
@@ -2341,15 +2540,15 @@ var require_parse = __commonJS({
2341
2540
  prev.value += node.value;
2342
2541
  return;
2343
2542
  }
2344
- block.nodes.push(node);
2345
- node.parent = block;
2543
+ block2.nodes.push(node);
2544
+ node.parent = block2;
2346
2545
  node.prev = prev;
2347
2546
  prev = node;
2348
2547
  return node;
2349
2548
  };
2350
2549
  push({ type: "bos" });
2351
2550
  while (index < length) {
2352
- block = stack[stack.length - 1];
2551
+ block2 = stack[stack.length - 1];
2353
2552
  value = advance();
2354
2553
  if (value === CHAR_ZERO_WIDTH_NOBREAK_SPACE || value === CHAR_NO_BREAK_SPACE) {
2355
2554
  continue;
@@ -2386,19 +2585,19 @@ var require_parse = __commonJS({
2386
2585
  continue;
2387
2586
  }
2388
2587
  if (value === CHAR_LEFT_PARENTHESES) {
2389
- block = push({ type: "paren", nodes: [] });
2390
- stack.push(block);
2588
+ block2 = push({ type: "paren", nodes: [] });
2589
+ stack.push(block2);
2391
2590
  push({ type: "text", value });
2392
2591
  continue;
2393
2592
  }
2394
2593
  if (value === CHAR_RIGHT_PARENTHESES) {
2395
- if (block.type !== "paren") {
2594
+ if (block2.type !== "paren") {
2396
2595
  push({ type: "text", value });
2397
2596
  continue;
2398
2597
  }
2399
- block = stack.pop();
2598
+ block2 = stack.pop();
2400
2599
  push({ type: "text", value });
2401
- block = stack[stack.length - 1];
2600
+ block2 = stack[stack.length - 1];
2402
2601
  continue;
2403
2602
  }
2404
2603
  if (value === CHAR_DOUBLE_QUOTE || value === CHAR_SINGLE_QUOTE || value === CHAR_BACKTICK) {
@@ -2423,7 +2622,7 @@ var require_parse = __commonJS({
2423
2622
  }
2424
2623
  if (value === CHAR_LEFT_CURLY_BRACE) {
2425
2624
  depth++;
2426
- const dollar = prev.value && prev.value.slice(-1) === "$" || block.dollar === true;
2625
+ const dollar = prev.value && prev.value.slice(-1) === "$" || block2.dollar === true;
2427
2626
  const brace = {
2428
2627
  type: "brace",
2429
2628
  open: true,
@@ -2434,52 +2633,52 @@ var require_parse = __commonJS({
2434
2633
  ranges: 0,
2435
2634
  nodes: []
2436
2635
  };
2437
- block = push(brace);
2438
- stack.push(block);
2636
+ block2 = push(brace);
2637
+ stack.push(block2);
2439
2638
  push({ type: "open", value });
2440
2639
  continue;
2441
2640
  }
2442
2641
  if (value === CHAR_RIGHT_CURLY_BRACE) {
2443
- if (block.type !== "brace") {
2642
+ if (block2.type !== "brace") {
2444
2643
  push({ type: "text", value });
2445
2644
  continue;
2446
2645
  }
2447
2646
  const type = "close";
2448
- block = stack.pop();
2449
- block.close = true;
2647
+ block2 = stack.pop();
2648
+ block2.close = true;
2450
2649
  push({ type, value });
2451
2650
  depth--;
2452
- block = stack[stack.length - 1];
2651
+ block2 = stack[stack.length - 1];
2453
2652
  continue;
2454
2653
  }
2455
2654
  if (value === CHAR_COMMA && depth > 0) {
2456
- if (block.ranges > 0) {
2457
- block.ranges = 0;
2458
- const open = block.nodes.shift();
2459
- block.nodes = [open, { type: "text", value: stringify2(block) }];
2655
+ if (block2.ranges > 0) {
2656
+ block2.ranges = 0;
2657
+ const open = block2.nodes.shift();
2658
+ block2.nodes = [open, { type: "text", value: stringify2(block2) }];
2460
2659
  }
2461
2660
  push({ type: "comma", value });
2462
- block.commas++;
2661
+ block2.commas++;
2463
2662
  continue;
2464
2663
  }
2465
- if (value === CHAR_DOT && depth > 0 && block.commas === 0) {
2466
- const siblings = block.nodes;
2664
+ if (value === CHAR_DOT && depth > 0 && block2.commas === 0) {
2665
+ const siblings = block2.nodes;
2467
2666
  if (depth === 0 || siblings.length === 0) {
2468
2667
  push({ type: "text", value });
2469
2668
  continue;
2470
2669
  }
2471
2670
  if (prev.type === "dot") {
2472
- block.range = [];
2671
+ block2.range = [];
2473
2672
  prev.value += value;
2474
2673
  prev.type = "range";
2475
- if (block.nodes.length !== 3 && block.nodes.length !== 5) {
2476
- block.invalid = true;
2477
- block.ranges = 0;
2674
+ if (block2.nodes.length !== 3 && block2.nodes.length !== 5) {
2675
+ block2.invalid = true;
2676
+ block2.ranges = 0;
2478
2677
  prev.type = "text";
2479
2678
  continue;
2480
2679
  }
2481
- block.ranges++;
2482
- block.args = [];
2680
+ block2.ranges++;
2681
+ block2.args = [];
2483
2682
  continue;
2484
2683
  }
2485
2684
  if (prev.type === "range") {
@@ -2487,7 +2686,7 @@ var require_parse = __commonJS({
2487
2686
  const before = siblings[siblings.length - 1];
2488
2687
  before.value += prev.value + value;
2489
2688
  prev = before;
2490
- block.ranges--;
2689
+ block2.ranges--;
2491
2690
  continue;
2492
2691
  }
2493
2692
  push({ type: "dot", value });
@@ -2496,9 +2695,9 @@ var require_parse = __commonJS({
2496
2695
  push({ type: "text", value });
2497
2696
  }
2498
2697
  do {
2499
- block = stack.pop();
2500
- if (block.type !== "root") {
2501
- block.nodes.forEach((node) => {
2698
+ block2 = stack.pop();
2699
+ if (block2.type !== "root") {
2700
+ block2.nodes.forEach((node) => {
2502
2701
  if (!node.nodes) {
2503
2702
  if (node.type === "open") node.isOpen = true;
2504
2703
  if (node.type === "close") node.isClose = true;
@@ -2507,8 +2706,8 @@ var require_parse = __commonJS({
2507
2706
  }
2508
2707
  });
2509
2708
  const parent = stack[stack.length - 1];
2510
- const index2 = parent.nodes.indexOf(block);
2511
- parent.nodes.splice(index2, 1, ...block.nodes);
2709
+ const index2 = parent.nodes.indexOf(block2);
2710
+ parent.nodes.splice(index2, 1, ...block2.nodes);
2512
2711
  }
2513
2712
  } while (stack.length > 0);
2514
2713
  push({ type: "eos" });
@@ -3141,9 +3340,9 @@ var require_scan = __commonJS({
3141
3340
  if (opts.parts === true || opts.tokens === true) {
3142
3341
  let prevIndex;
3143
3342
  for (let idx = 0; idx < slashes.length; idx++) {
3144
- const n = prevIndex ? prevIndex + 1 : start;
3145
- const i = slashes[idx];
3146
- const value = input.slice(n, i);
3343
+ const n3 = prevIndex ? prevIndex + 1 : start;
3344
+ const i2 = slashes[idx];
3345
+ const value = input.slice(n3, i2);
3147
3346
  if (opts.tokens) {
3148
3347
  if (idx === 0 && start !== 0) {
3149
3348
  tokens[idx].isPrefix = true;
@@ -3157,7 +3356,7 @@ var require_scan = __commonJS({
3157
3356
  if (idx !== 0 || value !== "") {
3158
3357
  parts.push(value);
3159
3358
  }
3160
- prevIndex = i;
3359
+ prevIndex = i2;
3161
3360
  }
3162
3361
  if (prevIndex && prevIndex + 1 < input.length) {
3163
3362
  const value = input.slice(prevIndex + 1);
@@ -3286,15 +3485,15 @@ var require_parse2 = __commonJS({
3286
3485
  };
3287
3486
  var hasRepeatedCharPrefixOverlap = (branches) => {
3288
3487
  const values = branches.map(normalizeSimpleBranch).filter(Boolean);
3289
- for (let i = 0; i < values.length; i++) {
3290
- for (let j2 = i + 1; j2 < values.length; j2++) {
3291
- const a = values[i];
3292
- const b = values[j2];
3293
- const char = a[0];
3294
- if (!char || a !== char.repeat(a.length) || b !== char.repeat(b.length)) {
3488
+ for (let i2 = 0; i2 < values.length; i2++) {
3489
+ for (let j = i2 + 1; j < values.length; j++) {
3490
+ const a2 = values[i2];
3491
+ const b = values[j];
3492
+ const char = a2[0];
3493
+ if (!char || a2 !== char.repeat(a2.length) || b !== char.repeat(b.length)) {
3295
3494
  continue;
3296
3495
  }
3297
- if (a === b || a.startsWith(b) || b.startsWith(a)) {
3496
+ if (a2 === b || a2.startsWith(b) || b.startsWith(a2)) {
3298
3497
  return true;
3299
3498
  }
3300
3499
  }
@@ -3309,8 +3508,8 @@ var require_parse2 = __commonJS({
3309
3508
  let paren = 0;
3310
3509
  let quote = 0;
3311
3510
  let escaped = false;
3312
- for (let i = 1; i < pattern.length; i++) {
3313
- const ch = pattern[i];
3511
+ for (let i2 = 1; i2 < pattern.length; i2++) {
3512
+ const ch = pattern[i2];
3314
3513
  if (escaped === true) {
3315
3514
  escaped = false;
3316
3515
  continue;
@@ -3344,13 +3543,13 @@ var require_parse2 = __commonJS({
3344
3543
  if (ch === ")") {
3345
3544
  paren--;
3346
3545
  if (paren === 0) {
3347
- if (requireEnd === true && i !== pattern.length - 1) {
3546
+ if (requireEnd === true && i2 !== pattern.length - 1) {
3348
3547
  return;
3349
3548
  }
3350
3549
  return {
3351
3550
  type: pattern[0],
3352
- body: pattern.slice(2, i),
3353
- end: i
3551
+ body: pattern.slice(2, i2),
3552
+ end: i2
3354
3553
  };
3355
3554
  }
3356
3555
  }
@@ -3482,7 +3681,7 @@ var require_parse2 = __commonJS({
3482
3681
  let prev = bos;
3483
3682
  let value;
3484
3683
  const eos = () => state.index === len - 1;
3485
- const peek = state.peek = (n = 1) => input[state.index + n];
3684
+ const peek = state.peek = (n3 = 1) => input[state.index + n3];
3486
3685
  const advance = state.advance = () => input[++state.index] || "";
3487
3686
  const remaining = () => input.slice(state.index + 1);
3488
3687
  const consume = (value2 = "", num = 0) => {
@@ -3563,10 +3762,10 @@ var require_parse2 = __commonJS({
3563
3762
  open.type = "text";
3564
3763
  open.value = literal;
3565
3764
  open.output = safeOutput || utils.escapeRegex(literal);
3566
- for (let i = token.tokensIndex + 1; i < tokens.length; i++) {
3567
- tokens[i].value = "";
3568
- tokens[i].output = "";
3569
- delete tokens[i].suffix;
3765
+ for (let i2 = token.tokensIndex + 1; i2 < tokens.length; i2++) {
3766
+ tokens[i2].value = "";
3767
+ tokens[i2].output = "";
3768
+ delete tokens[i2].suffix;
3570
3769
  }
3571
3770
  state.output = token.output + open.output;
3572
3771
  state.backtrack = true;
@@ -3809,13 +4008,13 @@ var require_parse2 = __commonJS({
3809
4008
  if (brace.dots === true) {
3810
4009
  const arr = tokens.slice();
3811
4010
  const range = [];
3812
- for (let i = arr.length - 1; i >= 0; i--) {
4011
+ for (let i2 = arr.length - 1; i2 >= 0; i2--) {
3813
4012
  tokens.pop();
3814
- if (arr[i].type === "brace") {
4013
+ if (arr[i2].type === "brace") {
3815
4014
  break;
3816
4015
  }
3817
- if (arr[i].type !== "dots") {
3818
- range.unshift(arr[i].value);
4016
+ if (arr[i2].type !== "dots") {
4017
+ range.unshift(arr[i2].value);
3819
4018
  }
3820
4019
  }
3821
4020
  output = expandRange(range, opts);
@@ -4274,7 +4473,7 @@ var require_picomatch = __commonJS({
4274
4473
  };
4275
4474
  picomatch.isMatch = (str, patterns, options) => picomatch(patterns, options)(str);
4276
4475
  picomatch.parse = (pattern, options) => {
4277
- if (Array.isArray(pattern)) return pattern.map((p2) => picomatch.parse(p2, options));
4476
+ if (Array.isArray(pattern)) return pattern.map((p) => picomatch.parse(p, options));
4278
4477
  return parse2(pattern, { ...options, fastpaths: false });
4279
4478
  };
4280
4479
  picomatch.scan = (input, options) => scan(input, options);
@@ -4358,8 +4557,8 @@ var require_micromatch = __commonJS({
4358
4557
  options.onResult(state);
4359
4558
  }
4360
4559
  };
4361
- for (let i = 0; i < patterns.length; i++) {
4362
- let isMatch = picomatch(String(patterns[i]), { ...options, onResult }, true);
4560
+ for (let i2 = 0; i2 < patterns.length; i2++) {
4561
+ let isMatch = picomatch(String(patterns[i2]), { ...options, onResult }, true);
4363
4562
  let negated = isMatch.state.negated || isMatch.state.negatedExtglob;
4364
4563
  if (negated) negatives++;
4365
4564
  for (let item of list) {
@@ -4381,7 +4580,7 @@ var require_micromatch = __commonJS({
4381
4580
  throw new Error(`No matches found for "${patterns.join(", ")}"`);
4382
4581
  }
4383
4582
  if (options.nonull === true || options.nullglob === true) {
4384
- return options.unescape ? patterns.map((p2) => p2.replace(/\\/g, "")) : patterns;
4583
+ return options.unescape ? patterns.map((p) => p.replace(/\\/g, "")) : patterns;
4385
4584
  }
4386
4585
  }
4387
4586
  return matches;
@@ -4411,7 +4610,7 @@ var require_micromatch = __commonJS({
4411
4610
  throw new TypeError(`Expected a string: "${util.inspect(str)}"`);
4412
4611
  }
4413
4612
  if (Array.isArray(pattern)) {
4414
- return pattern.some((p2) => micromatch.contains(str, p2, options));
4613
+ return pattern.some((p) => micromatch.contains(str, p, options));
4415
4614
  }
4416
4615
  if (typeof pattern === "string") {
4417
4616
  if (isEmptyString(str) || isEmptyString(pattern)) {
@@ -4456,7 +4655,7 @@ var require_micromatch = __commonJS({
4456
4655
  if (typeof str !== "string") {
4457
4656
  throw new TypeError(`Expected a string: "${util.inspect(str)}"`);
4458
4657
  }
4459
- return [].concat(patterns).every((p2) => picomatch(p2, options)(str));
4658
+ return [].concat(patterns).every((p) => picomatch(p, options)(str));
4460
4659
  };
4461
4660
  micromatch.capture = (glob, input, options) => {
4462
4661
  let posix = utils.isWindows(options);
@@ -4607,7 +4806,7 @@ var require_pattern = __commonJS({
4607
4806
  exports.expandPatternsWithBraceExpansion = expandPatternsWithBraceExpansion;
4608
4807
  function expandBraceExpansion(pattern) {
4609
4808
  const patterns = micromatch.braces(pattern, { expand: true, nodupes: true, keepEscaping: true });
4610
- patterns.sort((a, b) => a.length - b.length);
4809
+ patterns.sort((a2, b) => a2.length - b.length);
4611
4810
  return patterns.filter((pattern2) => pattern2 !== "");
4612
4811
  }
4613
4812
  exports.expandBraceExpansion = expandBraceExpansion;
@@ -4688,8 +4887,8 @@ var require_merge2 = __commonJS({
4688
4887
  }
4689
4888
  const mergedStream = PassThrough(options);
4690
4889
  function addStream() {
4691
- for (let i = 0, len = arguments.length; i < len; i++) {
4692
- streamsQueue.push(pauseStreams(arguments[i], options));
4890
+ for (let i2 = 0, len = arguments.length; i2 < len; i2++) {
4891
+ streamsQueue.push(pauseStreams(arguments[i2], options));
4693
4892
  }
4694
4893
  mergeStream();
4695
4894
  return this;
@@ -4738,8 +4937,8 @@ var require_merge2 = __commonJS({
4738
4937
  stream.pipe(mergedStream, { end: false });
4739
4938
  stream.resume();
4740
4939
  }
4741
- for (let i = 0; i < streams.length; i++) {
4742
- pipe(streams[i]);
4940
+ for (let i2 = 0; i2 < streams.length; i2++) {
4941
+ pipe(streams[i2]);
4743
4942
  }
4744
4943
  next();
4745
4944
  }
@@ -4770,8 +4969,8 @@ var require_merge2 = __commonJS({
4770
4969
  }
4771
4970
  streams.pause();
4772
4971
  } else {
4773
- for (let i = 0, len = streams.length; i < len; i++) {
4774
- streams[i] = pauseStreams(streams[i], options);
4972
+ for (let i2 = 0, len = streams.length; i2 < len; i2++) {
4973
+ streams[i2] = pauseStreams(streams[i2], options);
4775
4974
  }
4776
4975
  }
4777
4976
  return streams;
@@ -4853,13 +5052,13 @@ var require_tasks = __commonJS({
4853
5052
  Object.defineProperty(exports, "__esModule", { value: true });
4854
5053
  exports.convertPatternGroupToTask = exports.convertPatternGroupsToTasks = exports.groupPatternsByBaseDirectory = exports.getNegativePatternsAsPositive = exports.getPositivePatterns = exports.convertPatternsToTasks = exports.generate = void 0;
4855
5054
  var utils = require_utils3();
4856
- function generate(input, settings) {
4857
- const patterns = processPatterns(input, settings);
4858
- const ignore = processPatterns(settings.ignore, settings);
5055
+ function generate(input, settings2) {
5056
+ const patterns = processPatterns(input, settings2);
5057
+ const ignore = processPatterns(settings2.ignore, settings2);
4859
5058
  const positivePatterns = getPositivePatterns(patterns);
4860
5059
  const negativePatterns = getNegativePatternsAsPositive(patterns, ignore);
4861
- const staticPatterns = positivePatterns.filter((pattern) => utils.pattern.isStaticPattern(pattern, settings));
4862
- const dynamicPatterns = positivePatterns.filter((pattern) => utils.pattern.isDynamicPattern(pattern, settings));
5060
+ const staticPatterns = positivePatterns.filter((pattern) => utils.pattern.isStaticPattern(pattern, settings2));
5061
+ const dynamicPatterns = positivePatterns.filter((pattern) => utils.pattern.isDynamicPattern(pattern, settings2));
4863
5062
  const staticTasks = convertPatternsToTasks(
4864
5063
  staticPatterns,
4865
5064
  negativePatterns,
@@ -4875,12 +5074,12 @@ var require_tasks = __commonJS({
4875
5074
  return staticTasks.concat(dynamicTasks);
4876
5075
  }
4877
5076
  exports.generate = generate;
4878
- function processPatterns(input, settings) {
5077
+ function processPatterns(input, settings2) {
4879
5078
  let patterns = input;
4880
- if (settings.braceExpansion) {
5079
+ if (settings2.braceExpansion) {
4881
5080
  patterns = utils.pattern.expandPatternsWithBraceExpansion(patterns);
4882
5081
  }
4883
- if (settings.baseNameMatch) {
5082
+ if (settings2.baseNameMatch) {
4884
5083
  patterns = patterns.map((pattern) => pattern.includes("/") ? pattern : `**/${pattern}`);
4885
5084
  }
4886
5085
  return patterns.map((pattern) => utils.pattern.removeDuplicateSlashes(pattern));
@@ -4911,7 +5110,7 @@ var require_tasks = __commonJS({
4911
5110
  }
4912
5111
  exports.getNegativePatternsAsPositive = getNegativePatternsAsPositive;
4913
5112
  function groupPatternsByBaseDirectory(patterns) {
4914
- const group = {};
5113
+ const group2 = {};
4915
5114
  return patterns.reduce((collection, pattern) => {
4916
5115
  const base = utils.pattern.getBaseDirectory(pattern);
4917
5116
  if (base in collection) {
@@ -4920,7 +5119,7 @@ var require_tasks = __commonJS({
4920
5119
  collection[base] = [pattern];
4921
5120
  }
4922
5121
  return collection;
4923
- }, group);
5122
+ }, group2);
4924
5123
  }
4925
5124
  exports.groupPatternsByBaseDirectory = groupPatternsByBaseDirectory;
4926
5125
  function convertPatternGroupsToTasks(positive, negative, dynamic) {
@@ -4949,26 +5148,26 @@ var require_async = __commonJS({
4949
5148
  init_utils2();
4950
5149
  Object.defineProperty(exports, "__esModule", { value: true });
4951
5150
  exports.read = void 0;
4952
- function read(path, settings, callback) {
4953
- settings.fs.lstat(path, (lstatError, lstat) => {
5151
+ function read(path, settings2, callback) {
5152
+ settings2.fs.lstat(path, (lstatError, lstat) => {
4954
5153
  if (lstatError !== null) {
4955
5154
  callFailureCallback(callback, lstatError);
4956
5155
  return;
4957
5156
  }
4958
- if (!lstat.isSymbolicLink() || !settings.followSymbolicLink) {
5157
+ if (!lstat.isSymbolicLink() || !settings2.followSymbolicLink) {
4959
5158
  callSuccessCallback(callback, lstat);
4960
5159
  return;
4961
5160
  }
4962
- settings.fs.stat(path, (statError, stat) => {
5161
+ settings2.fs.stat(path, (statError, stat) => {
4963
5162
  if (statError !== null) {
4964
- if (settings.throwErrorOnBrokenSymbolicLink) {
5163
+ if (settings2.throwErrorOnBrokenSymbolicLink) {
4965
5164
  callFailureCallback(callback, statError);
4966
5165
  return;
4967
5166
  }
4968
5167
  callSuccessCallback(callback, lstat);
4969
5168
  return;
4970
5169
  }
4971
- if (settings.markSymbolicLink) {
5170
+ if (settings2.markSymbolicLink) {
4972
5171
  stat.isSymbolicLink = () => true;
4973
5172
  }
4974
5173
  callSuccessCallback(callback, stat);
@@ -4992,19 +5191,19 @@ var require_sync = __commonJS({
4992
5191
  init_utils2();
4993
5192
  Object.defineProperty(exports, "__esModule", { value: true });
4994
5193
  exports.read = void 0;
4995
- function read(path, settings) {
4996
- const lstat = settings.fs.lstatSync(path);
4997
- if (!lstat.isSymbolicLink() || !settings.followSymbolicLink) {
5194
+ function read(path, settings2) {
5195
+ const lstat = settings2.fs.lstatSync(path);
5196
+ if (!lstat.isSymbolicLink() || !settings2.followSymbolicLink) {
4998
5197
  return lstat;
4999
5198
  }
5000
5199
  try {
5001
- const stat = settings.fs.statSync(path);
5002
- if (settings.markSymbolicLink) {
5200
+ const stat = settings2.fs.statSync(path);
5201
+ if (settings2.markSymbolicLink) {
5003
5202
  stat.isSymbolicLink = () => true;
5004
5203
  }
5005
5204
  return stat;
5006
5205
  } catch (error2) {
5007
- if (!settings.throwErrorOnBrokenSymbolicLink) {
5206
+ if (!settings2.throwErrorOnBrokenSymbolicLink) {
5008
5207
  return lstat;
5009
5208
  }
5010
5209
  throw error2;
@@ -5081,8 +5280,8 @@ var require_out = __commonJS({
5081
5280
  }
5082
5281
  exports.stat = stat;
5083
5282
  function statSync3(path, optionsOrSettings) {
5084
- const settings = getSettings(optionsOrSettings);
5085
- return sync.read(path, settings);
5283
+ const settings2 = getSettings(optionsOrSettings);
5284
+ return sync.read(path, settings2);
5086
5285
  }
5087
5286
  exports.statSync = statSync3;
5088
5287
  function getSettings(settingsOrOptions = {}) {
@@ -5130,8 +5329,8 @@ var require_run_parallel = __commonJS({
5130
5329
  if (isSync) queueMicrotask2(end);
5131
5330
  else end();
5132
5331
  }
5133
- function each(i, err, result) {
5134
- results[i] = result;
5332
+ function each(i2, err, result) {
5333
+ results[i2] = result;
5135
5334
  if (--pending === 0 || err) {
5136
5335
  done(err);
5137
5336
  }
@@ -5145,9 +5344,9 @@ var require_run_parallel = __commonJS({
5145
5344
  });
5146
5345
  });
5147
5346
  } else {
5148
- tasks.forEach(function(task, i) {
5347
+ tasks.forEach(function(task, i2) {
5149
5348
  task(function(err, result) {
5150
- each(i, err, result);
5349
+ each(i2, err, result);
5151
5350
  });
5152
5351
  });
5153
5352
  }
@@ -5222,11 +5421,11 @@ var require_common = __commonJS({
5222
5421
  init_utils2();
5223
5422
  Object.defineProperty(exports, "__esModule", { value: true });
5224
5423
  exports.joinPathSegments = void 0;
5225
- function joinPathSegments(a, b, separator) {
5226
- if (a.endsWith(separator)) {
5227
- return a + b;
5424
+ function joinPathSegments(a2, b, separator) {
5425
+ if (a2.endsWith(separator)) {
5426
+ return a2 + b;
5228
5427
  }
5229
- return a + separator + b;
5428
+ return a2 + separator + b;
5230
5429
  }
5231
5430
  exports.joinPathSegments = joinPathSegments;
5232
5431
  }
@@ -5244,16 +5443,16 @@ var require_async2 = __commonJS({
5244
5443
  var constants_1 = require_constants3();
5245
5444
  var utils = require_utils4();
5246
5445
  var common = require_common();
5247
- function read(directory, settings, callback) {
5248
- if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
5249
- readdirWithFileTypes(directory, settings, callback);
5446
+ function read(directory, settings2, callback) {
5447
+ if (!settings2.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
5448
+ readdirWithFileTypes(directory, settings2, callback);
5250
5449
  return;
5251
5450
  }
5252
- readdir(directory, settings, callback);
5451
+ readdir(directory, settings2, callback);
5253
5452
  }
5254
5453
  exports.read = read;
5255
- function readdirWithFileTypes(directory, settings, callback) {
5256
- settings.fs.readdir(directory, { withFileTypes: true }, (readdirError, dirents) => {
5454
+ function readdirWithFileTypes(directory, settings2, callback) {
5455
+ settings2.fs.readdir(directory, { withFileTypes: true }, (readdirError, dirents) => {
5257
5456
  if (readdirError !== null) {
5258
5457
  callFailureCallback(callback, readdirError);
5259
5458
  return;
@@ -5261,13 +5460,13 @@ var require_async2 = __commonJS({
5261
5460
  const entries = dirents.map((dirent) => ({
5262
5461
  dirent,
5263
5462
  name: dirent.name,
5264
- path: common.joinPathSegments(directory, dirent.name, settings.pathSegmentSeparator)
5463
+ path: common.joinPathSegments(directory, dirent.name, settings2.pathSegmentSeparator)
5265
5464
  }));
5266
- if (!settings.followSymbolicLinks) {
5465
+ if (!settings2.followSymbolicLinks) {
5267
5466
  callSuccessCallback(callback, entries);
5268
5467
  return;
5269
5468
  }
5270
- const tasks = entries.map((entry) => makeRplTaskEntry(entry, settings));
5469
+ const tasks = entries.map((entry) => makeRplTaskEntry(entry, settings2));
5271
5470
  rpl(tasks, (rplError, rplEntries) => {
5272
5471
  if (rplError !== null) {
5273
5472
  callFailureCallback(callback, rplError);
@@ -5278,15 +5477,15 @@ var require_async2 = __commonJS({
5278
5477
  });
5279
5478
  }
5280
5479
  exports.readdirWithFileTypes = readdirWithFileTypes;
5281
- function makeRplTaskEntry(entry, settings) {
5480
+ function makeRplTaskEntry(entry, settings2) {
5282
5481
  return (done) => {
5283
5482
  if (!entry.dirent.isSymbolicLink()) {
5284
5483
  done(null, entry);
5285
5484
  return;
5286
5485
  }
5287
- settings.fs.stat(entry.path, (statError, stats) => {
5486
+ settings2.fs.stat(entry.path, (statError, stats) => {
5288
5487
  if (statError !== null) {
5289
- if (settings.throwErrorOnBrokenSymbolicLink) {
5488
+ if (settings2.throwErrorOnBrokenSymbolicLink) {
5290
5489
  done(statError);
5291
5490
  return;
5292
5491
  }
@@ -5298,16 +5497,16 @@ var require_async2 = __commonJS({
5298
5497
  });
5299
5498
  };
5300
5499
  }
5301
- function readdir(directory, settings, callback) {
5302
- settings.fs.readdir(directory, (readdirError, names) => {
5500
+ function readdir(directory, settings2, callback) {
5501
+ settings2.fs.readdir(directory, (readdirError, names) => {
5303
5502
  if (readdirError !== null) {
5304
5503
  callFailureCallback(callback, readdirError);
5305
5504
  return;
5306
5505
  }
5307
5506
  const tasks = names.map((name) => {
5308
- const path = common.joinPathSegments(directory, name, settings.pathSegmentSeparator);
5507
+ const path = common.joinPathSegments(directory, name, settings2.pathSegmentSeparator);
5309
5508
  return (done) => {
5310
- fsStat.stat(path, settings.fsStatSettings, (error2, stats) => {
5509
+ fsStat.stat(path, settings2.fsStatSettings, (error2, stats) => {
5311
5510
  if (error2 !== null) {
5312
5511
  done(error2);
5313
5512
  return;
@@ -5317,7 +5516,7 @@ var require_async2 = __commonJS({
5317
5516
  path,
5318
5517
  dirent: utils.fs.createDirentFromStats(name, stats)
5319
5518
  };
5320
- if (settings.stats) {
5519
+ if (settings2.stats) {
5321
5520
  entry.stats = stats;
5322
5521
  }
5323
5522
  done(null, entry);
@@ -5354,27 +5553,27 @@ var require_sync2 = __commonJS({
5354
5553
  var constants_1 = require_constants3();
5355
5554
  var utils = require_utils4();
5356
5555
  var common = require_common();
5357
- function read(directory, settings) {
5358
- if (!settings.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
5359
- return readdirWithFileTypes(directory, settings);
5556
+ function read(directory, settings2) {
5557
+ if (!settings2.stats && constants_1.IS_SUPPORT_READDIR_WITH_FILE_TYPES) {
5558
+ return readdirWithFileTypes(directory, settings2);
5360
5559
  }
5361
- return readdir(directory, settings);
5560
+ return readdir(directory, settings2);
5362
5561
  }
5363
5562
  exports.read = read;
5364
- function readdirWithFileTypes(directory, settings) {
5365
- const dirents = settings.fs.readdirSync(directory, { withFileTypes: true });
5563
+ function readdirWithFileTypes(directory, settings2) {
5564
+ const dirents = settings2.fs.readdirSync(directory, { withFileTypes: true });
5366
5565
  return dirents.map((dirent) => {
5367
5566
  const entry = {
5368
5567
  dirent,
5369
5568
  name: dirent.name,
5370
- path: common.joinPathSegments(directory, dirent.name, settings.pathSegmentSeparator)
5569
+ path: common.joinPathSegments(directory, dirent.name, settings2.pathSegmentSeparator)
5371
5570
  };
5372
- if (entry.dirent.isSymbolicLink() && settings.followSymbolicLinks) {
5571
+ if (entry.dirent.isSymbolicLink() && settings2.followSymbolicLinks) {
5373
5572
  try {
5374
- const stats = settings.fs.statSync(entry.path);
5573
+ const stats = settings2.fs.statSync(entry.path);
5375
5574
  entry.dirent = utils.fs.createDirentFromStats(entry.name, stats);
5376
5575
  } catch (error2) {
5377
- if (settings.throwErrorOnBrokenSymbolicLink) {
5576
+ if (settings2.throwErrorOnBrokenSymbolicLink) {
5378
5577
  throw error2;
5379
5578
  }
5380
5579
  }
@@ -5383,17 +5582,17 @@ var require_sync2 = __commonJS({
5383
5582
  });
5384
5583
  }
5385
5584
  exports.readdirWithFileTypes = readdirWithFileTypes;
5386
- function readdir(directory, settings) {
5387
- const names = settings.fs.readdirSync(directory);
5585
+ function readdir(directory, settings2) {
5586
+ const names = settings2.fs.readdirSync(directory);
5388
5587
  return names.map((name) => {
5389
- const entryPath = common.joinPathSegments(directory, name, settings.pathSegmentSeparator);
5390
- const stats = fsStat.statSync(entryPath, settings.fsStatSettings);
5588
+ const entryPath = common.joinPathSegments(directory, name, settings2.pathSegmentSeparator);
5589
+ const stats = fsStat.statSync(entryPath, settings2.fsStatSettings);
5391
5590
  const entry = {
5392
5591
  name,
5393
5592
  path: entryPath,
5394
5593
  dirent: utils.fs.createDirentFromStats(name, stats)
5395
5594
  };
5396
- if (settings.stats) {
5595
+ if (settings2.stats) {
5397
5596
  entry.stats = stats;
5398
5597
  }
5399
5598
  return entry;
@@ -5480,8 +5679,8 @@ var require_out2 = __commonJS({
5480
5679
  }
5481
5680
  exports.scandir = scandir;
5482
5681
  function scandirSync(path, optionsOrSettings) {
5483
- const settings = getSettings(optionsOrSettings);
5484
- return sync.read(path, settings);
5682
+ const settings2 = getSettings(optionsOrSettings);
5683
+ return sync.read(path, settings2);
5485
5684
  }
5486
5685
  exports.scandirSync = scandirSync;
5487
5686
  function getSettings(settingsOrOptions = {}) {
@@ -5762,7 +5961,7 @@ var require_queue = __commonJS({
5762
5961
  queue.drained = drained;
5763
5962
  return queue;
5764
5963
  function push(value) {
5765
- var p2 = new Promise(function(resolve4, reject) {
5964
+ var p = new Promise(function(resolve4, reject) {
5766
5965
  pushCb(value, function(err, result) {
5767
5966
  if (err) {
5768
5967
  reject(err);
@@ -5771,11 +5970,11 @@ var require_queue = __commonJS({
5771
5970
  resolve4(result);
5772
5971
  });
5773
5972
  });
5774
- p2.catch(noop);
5775
- return p2;
5973
+ p.catch(noop);
5974
+ return p;
5776
5975
  }
5777
5976
  function unshift(value) {
5778
- var p2 = new Promise(function(resolve4, reject) {
5977
+ var p = new Promise(function(resolve4, reject) {
5779
5978
  unshiftCb(value, function(err, result) {
5780
5979
  if (err) {
5781
5980
  reject(err);
@@ -5784,11 +5983,11 @@ var require_queue = __commonJS({
5784
5983
  resolve4(result);
5785
5984
  });
5786
5985
  });
5787
- p2.catch(noop);
5788
- return p2;
5986
+ p.catch(noop);
5987
+ return p;
5789
5988
  }
5790
5989
  function drained() {
5791
- var p2 = new Promise(function(resolve4) {
5990
+ var p = new Promise(function(resolve4) {
5792
5991
  process.nextTick(function() {
5793
5992
  if (queue.idle()) {
5794
5993
  resolve4();
@@ -5802,7 +6001,7 @@ var require_queue = __commonJS({
5802
6001
  }
5803
6002
  });
5804
6003
  });
5805
- return p2;
6004
+ return p;
5806
6005
  }
5807
6006
  }
5808
6007
  module.exports = fastqueue;
@@ -5817,11 +6016,11 @@ var require_common2 = __commonJS({
5817
6016
  init_utils2();
5818
6017
  Object.defineProperty(exports, "__esModule", { value: true });
5819
6018
  exports.joinPathSegments = exports.replacePathSegmentSeparator = exports.isAppliedFilter = exports.isFatalError = void 0;
5820
- function isFatalError(settings, error2) {
5821
- if (settings.errorFilter === null) {
6019
+ function isFatalError(settings2, error2) {
6020
+ if (settings2.errorFilter === null) {
5822
6021
  return true;
5823
6022
  }
5824
- return !settings.errorFilter(error2);
6023
+ return !settings2.errorFilter(error2);
5825
6024
  }
5826
6025
  exports.isFatalError = isFatalError;
5827
6026
  function isAppliedFilter(filter, value) {
@@ -5832,14 +6031,14 @@ var require_common2 = __commonJS({
5832
6031
  return filepath.split(/[/\\]/).join(separator);
5833
6032
  }
5834
6033
  exports.replacePathSegmentSeparator = replacePathSegmentSeparator;
5835
- function joinPathSegments(a, b, separator) {
5836
- if (a === "") {
6034
+ function joinPathSegments(a2, b, separator) {
6035
+ if (a2 === "") {
5837
6036
  return b;
5838
6037
  }
5839
- if (a.endsWith(separator)) {
5840
- return a + b;
6038
+ if (a2.endsWith(separator)) {
6039
+ return a2 + b;
5841
6040
  }
5842
- return a + separator + b;
6041
+ return a2 + separator + b;
5843
6042
  }
5844
6043
  exports.joinPathSegments = joinPathSegments;
5845
6044
  }
@@ -6186,14 +6385,14 @@ var require_out3 = __commonJS({
6186
6385
  }
6187
6386
  exports.walk = walk;
6188
6387
  function walkSync(directory, optionsOrSettings) {
6189
- const settings = getSettings(optionsOrSettings);
6190
- const provider = new sync_1.default(directory, settings);
6388
+ const settings2 = getSettings(optionsOrSettings);
6389
+ const provider = new sync_1.default(directory, settings2);
6191
6390
  return provider.read();
6192
6391
  }
6193
6392
  exports.walkSync = walkSync;
6194
6393
  function walkStream(directory, optionsOrSettings) {
6195
- const settings = getSettings(optionsOrSettings);
6196
- const provider = new stream_1.default(directory, settings);
6394
+ const settings2 = getSettings(optionsOrSettings);
6395
+ const provider = new stream_1.default(directory, settings2);
6197
6396
  return provider.read();
6198
6397
  }
6199
6398
  exports.walkStream = walkStream;
@@ -6279,8 +6478,8 @@ var require_stream3 = __commonJS({
6279
6478
  done();
6280
6479
  }).catch(done);
6281
6480
  };
6282
- for (let i = 0; i < filepaths.length; i++) {
6283
- stream.write(i);
6481
+ for (let i2 = 0; i2 < filepaths.length; i2++) {
6482
+ stream.write(i2);
6284
6483
  }
6285
6484
  return stream;
6286
6485
  }
@@ -6941,14 +7140,14 @@ var require_out4 = __commonJS({
6941
7140
  function generateTasks(source, options) {
6942
7141
  assertPatternsInput(source);
6943
7142
  const patterns = [].concat(source);
6944
- const settings = new settings_1.default(options);
6945
- return taskManager.generate(patterns, settings);
7143
+ const settings2 = new settings_1.default(options);
7144
+ return taskManager.generate(patterns, settings2);
6946
7145
  }
6947
7146
  FastGlob2.generateTasks = generateTasks;
6948
7147
  function isDynamicPattern(source, options) {
6949
7148
  assertPatternsInput(source);
6950
- const settings = new settings_1.default(options);
6951
- return utils.pattern.isDynamicPattern(source, settings);
7149
+ const settings2 = new settings_1.default(options);
7150
+ return utils.pattern.isDynamicPattern(source, settings2);
6952
7151
  }
6953
7152
  FastGlob2.isDynamicPattern = isDynamicPattern;
6954
7153
  function escapePath(source) {
@@ -6990,9 +7189,9 @@ var require_out4 = __commonJS({
6990
7189
  })(FastGlob || (FastGlob = {}));
6991
7190
  function getWorks(source, _Provider, options) {
6992
7191
  const patterns = [].concat(source);
6993
- const settings = new settings_1.default(options);
6994
- const tasks = taskManager.generate(patterns, settings);
6995
- const provider = new _Provider(settings);
7192
+ const settings2 = new settings_1.default(options);
7193
+ const tasks = taskManager.generate(patterns, settings2);
7194
+ const provider = new _Provider(settings2);
6996
7195
  return tasks.map(provider.read, provider);
6997
7196
  }
6998
7197
  function assertPatternsInput(input) {
@@ -7170,8 +7369,8 @@ import "node:fs";
7170
7369
  import { createRequire } from "node:module";
7171
7370
  import {
7172
7371
  resolve,
7173
- join,
7174
- dirname,
7372
+ join as join2,
7373
+ dirname as dirname2,
7175
7374
  relative,
7176
7375
  normalize,
7177
7376
  sep,
@@ -7185,7 +7384,7 @@ function safeExecuteAsync(fn, message) {
7185
7384
  );
7186
7385
  });
7187
7386
  }
7188
- var import_fast_glob, constants, log2, PACKAGE_PATHS, PathResolver;
7387
+ var import_fast_glob, constants, log3, PACKAGE_PATHS, PathResolver;
7189
7388
  var init_PathResolver = __esm({
7190
7389
  "packages/core/config/utils/PathResolver.ts"() {
7191
7390
  "use strict";
@@ -7198,7 +7397,7 @@ var init_PathResolver = __esm({
7198
7397
  getPatternsFor: getPatternsFor || void 0,
7199
7398
  I18N_PATHS: I18N_PATHS || void 0
7200
7399
  };
7201
- log2 = {
7400
+ log3 = {
7202
7401
  error: (message, error2) => {
7203
7402
  },
7204
7403
  warn: (message, error2) => {
@@ -7319,7 +7518,7 @@ var init_PathResolver = __esm({
7319
7518
  */
7320
7519
  getDirname(path) {
7321
7520
  if (!path) return "";
7322
- return this.normalizePath(dirname(path));
7521
+ return this.normalizePath(dirname2(path));
7323
7522
  }
7324
7523
  /**
7325
7524
  * Resolve package path using Node's module resolution
@@ -7331,7 +7530,7 @@ var init_PathResolver = __esm({
7331
7530
  resolvePackage(packageSpecifier, fromPath = null) {
7332
7531
  try {
7333
7532
  const basePath = fromPath || this.getAppRoot();
7334
- const require3 = createRequire(join(basePath, "package.json"));
7533
+ const require3 = createRequire(join2(basePath, "package.json"));
7335
7534
  const resolved = require3.resolve(packageSpecifier);
7336
7535
  return this.normalizePath(resolved);
7337
7536
  } catch (error2) {
@@ -7483,7 +7682,7 @@ var init_PathResolver = __esm({
7483
7682
  return cleanContent;
7484
7683
  } catch (error2) {
7485
7684
  if (this.options.debug) {
7486
- log2.warn(`Failed to read file: ${filePath}`, error2);
7685
+ log3.warn(`Failed to read file: ${filePath}`, error2);
7487
7686
  }
7488
7687
  return null;
7489
7688
  }
@@ -7511,7 +7710,7 @@ var init_PathResolver = __esm({
7511
7710
  return cleanContent;
7512
7711
  } catch (error2) {
7513
7712
  if (this.options.debug) {
7514
- log2.warn(`Failed to read file: ${filePath}`, error2);
7713
+ log3.warn(`Failed to read file: ${filePath}`, error2);
7515
7714
  }
7516
7715
  return null;
7517
7716
  }
@@ -7533,16 +7732,16 @@ var init_PathResolver = __esm({
7533
7732
  verbose = false
7534
7733
  } = options;
7535
7734
  const normalizedPath = this.normalizePath(filePath);
7536
- const dir = this.normalizePath(dirname(normalizedPath));
7735
+ const dir = this.normalizePath(dirname2(normalizedPath));
7537
7736
  const fileExists = this.pathExists(normalizedPath);
7538
7737
  if (fileExists && !overwrite) {
7539
7738
  if (verbose) {
7540
- log2.info(`Skipping existing file: ${normalizedPath}`);
7739
+ log3.info(`Skipping existing file: ${normalizedPath}`);
7541
7740
  }
7542
7741
  return false;
7543
7742
  }
7544
7743
  if (dryRun) {
7545
- log2.info(`[DRY RUN] Would write file: ${normalizedPath}`);
7744
+ log3.info(`[DRY RUN] Would write file: ${normalizedPath}`);
7546
7745
  return true;
7547
7746
  }
7548
7747
  try {
@@ -7567,7 +7766,7 @@ var init_PathResolver = __esm({
7567
7766
  await fs.promises.writeFile(normalizedPath, writeContent, "utf8");
7568
7767
  }
7569
7768
  if (verbose) {
7570
- log2.info(
7769
+ log3.info(
7571
7770
  `${fileExists ? "Updated" : "Created"} file: ${normalizedPath}`
7572
7771
  );
7573
7772
  }
@@ -7594,16 +7793,16 @@ var init_PathResolver = __esm({
7594
7793
  verbose = false
7595
7794
  } = options;
7596
7795
  const normalizedPath = this.normalizePath(filePath);
7597
- const dir = this.normalizePath(dirname(normalizedPath));
7796
+ const dir = this.normalizePath(dirname2(normalizedPath));
7598
7797
  const fileExists = this.pathExists(normalizedPath);
7599
7798
  if (fileExists && !overwrite) {
7600
7799
  if (verbose) {
7601
- log2.info(`Skipping existing file: ${normalizedPath}`);
7800
+ log3.info(`Skipping existing file: ${normalizedPath}`);
7602
7801
  }
7603
7802
  return false;
7604
7803
  }
7605
7804
  if (dryRun) {
7606
- log2.info(`[DRY RUN] Would write file: ${normalizedPath}`);
7805
+ log3.info(`[DRY RUN] Would write file: ${normalizedPath}`);
7607
7806
  return true;
7608
7807
  }
7609
7808
  try {
@@ -7627,7 +7826,7 @@ var init_PathResolver = __esm({
7627
7826
  fs.writeFileSync(normalizedPath, writeContent, "utf8");
7628
7827
  }
7629
7828
  if (verbose) {
7630
- log2.info(
7829
+ log3.info(
7631
7830
  `${fileExists ? "Updated" : "Created"} file: ${normalizedPath}`
7632
7831
  );
7633
7832
  }
@@ -7652,15 +7851,15 @@ var init_PathResolver = __esm({
7652
7851
  const fileExists = this.pathExists(normalizedDestPath);
7653
7852
  if (fileExists && !overwrite) {
7654
7853
  if (verbose) {
7655
- log2.info(`Skipping existing file: ${normalizedDestPath}`);
7854
+ log3.info(`Skipping existing file: ${normalizedDestPath}`);
7656
7855
  }
7657
7856
  return false;
7658
7857
  }
7659
7858
  if (dryRun) {
7660
- log2.info(`[DRY RUN] Would copy file: ${normalizedDestPath}`);
7859
+ log3.info(`[DRY RUN] Would copy file: ${normalizedDestPath}`);
7661
7860
  return true;
7662
7861
  }
7663
- const dir = this.normalizePath(dirname(normalizedDestPath));
7862
+ const dir = this.normalizePath(dirname2(normalizedDestPath));
7664
7863
  try {
7665
7864
  await fs.promises.mkdir(dir, { recursive: true });
7666
7865
  } catch (error2) {
@@ -7670,7 +7869,7 @@ var init_PathResolver = __esm({
7670
7869
  return await safeExecuteAsync(async () => {
7671
7870
  await fs.promises.copyFile(srcPath, normalizedDestPath);
7672
7871
  if (verbose) {
7673
- log2.info(
7872
+ log3.info(
7674
7873
  `${fileExists ? "Updated" : "Created"} file: ${normalizedDestPath}`
7675
7874
  );
7676
7875
  }
@@ -7694,15 +7893,15 @@ var init_PathResolver = __esm({
7694
7893
  const fileExists = this.pathExists(normalizedDestPath);
7695
7894
  if (fileExists && !overwrite) {
7696
7895
  if (verbose) {
7697
- log2.info(`Skipping existing file: ${normalizedDestPath}`);
7896
+ log3.info(`Skipping existing file: ${normalizedDestPath}`);
7698
7897
  }
7699
7898
  return false;
7700
7899
  }
7701
7900
  if (dryRun) {
7702
- log2.info(`[DRY RUN] Would copy file: ${normalizedDestPath}`);
7901
+ log3.info(`[DRY RUN] Would copy file: ${normalizedDestPath}`);
7703
7902
  return true;
7704
7903
  }
7705
- const dir = this.normalizePath(dirname(normalizedDestPath));
7904
+ const dir = this.normalizePath(dirname2(normalizedDestPath));
7706
7905
  try {
7707
7906
  fs.mkdirSync(dir, { recursive: true });
7708
7907
  } catch (error2) {
@@ -7711,7 +7910,7 @@ var init_PathResolver = __esm({
7711
7910
  try {
7712
7911
  fs.copyFileSync(srcPath, normalizedDestPath);
7713
7912
  if (verbose) {
7714
- log2.info(
7913
+ log3.info(
7715
7914
  `${fileExists ? "Updated" : "Created"} file: ${normalizedDestPath}`
7716
7915
  );
7717
7916
  }
@@ -7728,7 +7927,7 @@ var init_PathResolver = __esm({
7728
7927
  return fs.existsSync(filePath);
7729
7928
  } catch (error2) {
7730
7929
  if (!silent) {
7731
- log2.error(`Error checking path existence: ${filePath}`, error2);
7930
+ log3.error(`Error checking path existence: ${filePath}`, error2);
7732
7931
  }
7733
7932
  return false;
7734
7933
  }
@@ -7754,7 +7953,7 @@ var init_PathResolver = __esm({
7754
7953
  return fs.readdirSync(dirPath, options);
7755
7954
  } catch (error2) {
7756
7955
  if (this.options.debug) {
7757
- log2.warn(`Failed to read directory: ${dirPath}`, error2);
7956
+ log3.warn(`Failed to read directory: ${dirPath}`, error2);
7758
7957
  }
7759
7958
  const isObjectOptions = options && typeof options === "object" && "withFileTypes" in options;
7760
7959
  return isObjectOptions && options.withFileTypes ? [] : [];
@@ -7772,7 +7971,7 @@ var init_PathResolver = __esm({
7772
7971
  return fs.statSync(filePath);
7773
7972
  } catch (error2) {
7774
7973
  if (this.options.debug) {
7775
- log2.warn(`Failed to stat file: ${filePath}`, error2);
7974
+ log3.warn(`Failed to stat file: ${filePath}`, error2);
7776
7975
  }
7777
7976
  return null;
7778
7977
  }
@@ -7789,7 +7988,7 @@ var init_PathResolver = __esm({
7789
7988
  return fs.lstatSync(filePath);
7790
7989
  } catch (error2) {
7791
7990
  if (this.options.debug) {
7792
- log2.warn(`Failed to lstat file: ${filePath}`, error2);
7991
+ log3.warn(`Failed to lstat file: ${filePath}`, error2);
7793
7992
  }
7794
7993
  return null;
7795
7994
  }
@@ -7878,7 +8077,7 @@ var init_PathResolver = __esm({
7878
8077
  * @returns True if repoRoot is the monorepo (has packages directory)
7879
8078
  */
7880
8079
  isMonorepo() {
7881
- const packagesDir = join(this._repoRoot, "packages");
8080
+ const packagesDir = join2(this._repoRoot, "packages");
7882
8081
  return this.pathExists(packagesDir);
7883
8082
  }
7884
8083
  /**
@@ -7895,7 +8094,7 @@ var init_PathResolver = __esm({
7895
8094
  * Find files matching pattern within directory
7896
8095
  */
7897
8096
  async findFiles(directory, pattern, options = {}) {
7898
- const searchPattern = this.normalizePath(join(directory, pattern));
8097
+ const searchPattern = this.normalizePath(join2(directory, pattern));
7899
8098
  const appRoot = this.getAppRoot();
7900
8099
  const normalizeAppRoot = this.normalizePath(appRoot);
7901
8100
  const relativePattern = searchPattern.startsWith(normalizeAppRoot) ? searchPattern.slice(normalizeAppRoot.length + 1) : searchPattern;
@@ -7942,7 +8141,7 @@ var init_PathResolver = __esm({
7942
8141
  return null;
7943
8142
  }
7944
8143
  const resolvedPath = this.normalizePath(
7945
- join(corePackageRoot, I18N_PATHS2.PUBLISHED_ROOT, i18nSubpath)
8144
+ join2(corePackageRoot, I18N_PATHS2.PUBLISHED_ROOT, i18nSubpath)
7946
8145
  );
7947
8146
  const resolvedDir = resolvedPath.replace(/\/[^/]*\*.*$/, "");
7948
8147
  if (this.pathExists(resolvedDir)) {
@@ -8138,13 +8337,13 @@ var init_PathResolver = __esm({
8138
8337
  const maxLevels = this.options.maxLevels;
8139
8338
  while (levelsChecked < maxLevels) {
8140
8339
  const toolingPath = this.normalizePath(
8141
- join(currentDir, PACKAGE_PATHS.TOOLING)
8340
+ join2(currentDir, PACKAGE_PATHS.TOOLING)
8142
8341
  );
8143
- const corePath = this.normalizePath(join(currentDir, PACKAGE_PATHS.CORE));
8342
+ const corePath = this.normalizePath(join2(currentDir, PACKAGE_PATHS.CORE));
8144
8343
  if (this.pathExists(toolingPath) && this.pathExists(corePath)) {
8145
8344
  return currentDir;
8146
8345
  }
8147
- const appsDir = join(currentDir, "apps");
8346
+ const appsDir = join2(currentDir, "apps");
8148
8347
  if (this.pathExists(appsDir)) {
8149
8348
  const appsDirStat = this.statSync(appsDir);
8150
8349
  if (appsDirStat?.isDirectory()) {
@@ -8152,15 +8351,15 @@ var init_PathResolver = __esm({
8152
8351
  }
8153
8352
  }
8154
8353
  const packageJsonPath = this.normalizePath(
8155
- join(currentDir, "package.json")
8354
+ join2(currentDir, "package.json")
8156
8355
  );
8157
8356
  if (this.pathExists(packageJsonPath)) {
8158
- const parentDir2 = this.normalizePath(dirname(currentDir));
8357
+ const parentDir2 = this.normalizePath(dirname2(currentDir));
8159
8358
  if (parentDir2 === currentDir) {
8160
8359
  return currentDir;
8161
8360
  }
8162
8361
  }
8163
- const parentDir = this.normalizePath(dirname(currentDir));
8362
+ const parentDir = this.normalizePath(dirname2(currentDir));
8164
8363
  if (parentDir === currentDir) {
8165
8364
  break;
8166
8365
  }
@@ -8176,8 +8375,8 @@ var init_PathResolver = __esm({
8176
8375
  // packages/tooling/src/utils/pathResolver.ts
8177
8376
  import { createRequire as createRequire2 } from "node:module";
8178
8377
  import {
8179
- join as join2,
8180
- dirname as dirname2,
8378
+ join as join3,
8379
+ dirname as dirname3,
8181
8380
  basename as basename2,
8182
8381
  extname as extname2,
8183
8382
  relative as relative2,
@@ -8186,7 +8385,7 @@ import {
8186
8385
  isAbsolute as pathIsAbsolute
8187
8386
  } from "node:path";
8188
8387
  import { fileURLToPath as fileURLToPath2 } from "node:url";
8189
- function readdirSync2(dirPath, options) {
8388
+ function readdirSync3(dirPath, options) {
8190
8389
  return pathResolverInstance.readdirSync(dirPath, options);
8191
8390
  }
8192
8391
  var pathResolverInstance, getRepoRoot, normalizePath, pathExists, readSync, statSync2, getRelativePathBetween, getDirname, joinPath;
@@ -8198,7 +8397,7 @@ var init_pathResolver = __esm({
8198
8397
  pathResolverInstance = PathResolver.getInstance({ debug: false });
8199
8398
  getRepoRoot = () => pathResolverInstance.getRepoRoot();
8200
8399
  normalizePath = (...pathSegments) => {
8201
- return pathResolverInstance.normalizePath(join2(...pathSegments));
8400
+ return pathResolverInstance.normalizePath(join3(...pathSegments));
8202
8401
  };
8203
8402
  pathExists = (filePath, silent = false) => pathResolverInstance.pathExists(filePath, silent);
8204
8403
  readSync = (filePath, options) => pathResolverInstance.readSync(filePath, options);
@@ -8207,7 +8406,7 @@ var init_pathResolver = __esm({
8207
8406
  return normalizePath(relative2(from, to));
8208
8407
  };
8209
8408
  getDirname = (filePath) => {
8210
- return normalizePath(dirname2(filePath));
8409
+ return normalizePath(dirname3(filePath));
8211
8410
  };
8212
8411
  joinPath = (...pathSegments) => {
8213
8412
  return normalizePath(...pathSegments);
@@ -8219,7 +8418,7 @@ var init_pathResolver = __esm({
8219
8418
  import { Buffer } from "node:buffer";
8220
8419
  import { copyFileSync as copyFileSync2, readFileSync as readFileSync2, writeFileSync as writeFileSync2, mkdirSync as mkdirSync2 } from "node:fs";
8221
8420
  import { createRequire as createRequire3 } from "node:module";
8222
- import { dirname as dirname3, resolve as resolve3 } from "node:path";
8421
+ import { dirname as dirname4, resolve as resolve3 } from "node:path";
8223
8422
  import process from "node:process";
8224
8423
  import { fileURLToPath as fileURLToPath3 } from "node:url";
8225
8424
  var require2, __filename, __dirname;
@@ -8228,7 +8427,7 @@ var init_utils2 = __esm({
8228
8427
  "use strict";
8229
8428
  require2 = createRequire3(import.meta.url);
8230
8429
  __filename = fileURLToPath3(import.meta.url);
8231
- __dirname = dirname3(__filename);
8430
+ __dirname = dirname4(__filename);
8232
8431
  if (typeof globalThis !== "undefined") {
8233
8432
  globalThis.require = require2;
8234
8433
  globalThis.__filename = __filename;
@@ -8249,13 +8448,13 @@ async function askForSelection(message, choices, defaultValue = 0) {
8249
8448
  label: choice.title,
8250
8449
  hint: choice.hint
8251
8450
  }));
8252
- const result = await _t({
8451
+ const result = await select({
8253
8452
  message,
8254
8453
  options,
8255
8454
  initialValue: choices[defaultValue]?.value
8256
8455
  });
8257
- if (q(result)) {
8258
- pt("Operation cancelled.");
8456
+ if (isCancel(result)) {
8457
+ cancel("Operation cancelled.");
8259
8458
  process.exit(0);
8260
8459
  }
8261
8460
  return result;
@@ -8323,9 +8522,9 @@ async function validateToken(token) {
8323
8522
  return { username: data.user.username, email: data.user.email };
8324
8523
  }
8325
8524
  async function fetchProjectDetails(token, projectId, orgId) {
8326
- const q2 = orgId ? `?teamId=${encodeURIComponent(orgId)}` : "";
8525
+ const q = orgId ? `?teamId=${encodeURIComponent(orgId)}` : "";
8327
8526
  const res = await fetch(
8328
- `${VERCEL_API}/v9/projects/${encodeURIComponent(projectId)}${q2}`,
8527
+ `${VERCEL_API}/v9/projects/${encodeURIComponent(projectId)}${q}`,
8329
8528
  {
8330
8529
  headers: { Authorization: `Bearer ${token}` }
8331
8530
  }
@@ -8426,7 +8625,7 @@ function resolveSecret(name, projectRoot, opts) {
8426
8625
  if (value) {
8427
8626
  if (!opts?.silent && !warnedLegacy.has(name)) {
8428
8627
  warnedLegacy.add(name);
8429
- log.warn(
8628
+ log2.warn(
8430
8629
  `${name} found in ${relPath} (legacy). Move it to .dndev.secrets at project root.`
8431
8630
  );
8432
8631
  }
@@ -8437,7 +8636,7 @@ function resolveSecret(name, projectRoot, opts) {
8437
8636
  if (aliasValue) {
8438
8637
  if (!opts?.silent && !warnedLegacy.has(name)) {
8439
8638
  warnedLegacy.add(name);
8440
- log.warn(
8639
+ log2.warn(
8441
8640
  `${name} found in ${relPath} (legacy). Move it to .dndev.secrets at project root.`
8442
8641
  );
8443
8642
  }
@@ -8516,7 +8715,7 @@ function parseEnvFile2(filePath) {
8516
8715
  }
8517
8716
  const result = parseEnvFile(filePath);
8518
8717
  if (Object.keys(result).length === 0) {
8519
- log.debug(`No key-value pairs found in ${filePath}`);
8718
+ log2.debug(`No key-value pairs found in ${filePath}`);
8520
8719
  }
8521
8720
  return result;
8522
8721
  }
@@ -8525,7 +8724,7 @@ function parseSecretsWithFallback(envFilePath, projectRoot) {
8525
8724
  if (pathExists(dndevSecretsPath)) {
8526
8725
  const secrets = parseEnvFile(dndevSecretsPath);
8527
8726
  if (Object.keys(secrets).length > 0) {
8528
- log.info(`Reading secrets from: ${dndevSecretsPath}`);
8727
+ log2.info(`Reading secrets from: ${dndevSecretsPath}`);
8529
8728
  return secrets;
8530
8729
  }
8531
8730
  }
@@ -8539,7 +8738,7 @@ function detectPlatform() {
8539
8738
  if (pathExists(joinPath(currentDir, "vercel.json")) || pathExists(joinPath(currentDir, ".vercel"))) {
8540
8739
  return "vercel";
8541
8740
  }
8542
- log.warn("No platform detected, defaulting to Firebase");
8741
+ log2.warn("No platform detected, defaulting to Firebase");
8543
8742
  return "firebase";
8544
8743
  }
8545
8744
  function findFirebaseProjectDir(envFilePath) {
@@ -8618,7 +8817,7 @@ function detectAppsWithFunctions() {
8618
8817
  }
8619
8818
  const apps = [];
8620
8819
  try {
8621
- const appsList = readdirSync2(appsDir).filter((item) => {
8820
+ const appsList = readdirSync3(appsDir).filter((item) => {
8622
8821
  const itemPath = joinPath(appsDir, item);
8623
8822
  const stat = statSync2(itemPath);
8624
8823
  return stat?.isDirectory() === true;
@@ -8635,7 +8834,7 @@ function detectAppsWithFunctions() {
8635
8834
  }
8636
8835
  } catch {
8637
8836
  }
8638
- return apps.sort((a, b) => a.name.localeCompare(b.name));
8837
+ return apps.sort((a2, b) => a2.name.localeCompare(b.name));
8639
8838
  }
8640
8839
  async function setFirebaseSecret(key, value, projectId, dryRun = false, cwd) {
8641
8840
  if (isFirebaseReservedKey(key)) {
@@ -8645,11 +8844,11 @@ async function setFirebaseSecret(key, value, projectId, dryRun = false, cwd) {
8645
8844
  "FIREBASE_AUTH_DOMAIN"
8646
8845
  ];
8647
8846
  if (configOnlyKeys.includes(key)) {
8648
- log.debug(
8847
+ log2.debug(
8649
8848
  `\u23ED\uFE0F Skipping ${key}: Configuration variable (stays in .env, not synced as secret)`
8650
8849
  );
8651
8850
  } else {
8652
- log.warn(
8851
+ log2.warn(
8653
8852
  `\u23ED\uFE0F Skipping ${key}: Reserved Firebase prefix (X_GOOGLE_, FIREBASE_, EXT_, GCLOUD_)`
8654
8853
  );
8655
8854
  }
@@ -8657,7 +8856,7 @@ async function setFirebaseSecret(key, value, projectId, dryRun = false, cwd) {
8657
8856
  }
8658
8857
  const finalProjectId = projectId || detectFirebaseProjectId(cwd);
8659
8858
  if (dryRun) {
8660
- log.info(
8859
+ log2.info(
8661
8860
  `[DRY RUN] Would set Firebase secret: ${key}${finalProjectId ? ` (project: ${finalProjectId})` : ""}`
8662
8861
  );
8663
8862
  return;
@@ -8677,7 +8876,7 @@ async function setFirebaseSecret(key, value, projectId, dryRun = false, cwd) {
8677
8876
  );
8678
8877
  }
8679
8878
  try {
8680
- log.info(`Setting Firebase secret: ${key} (project: ${finalProjectId})`);
8879
+ log2.info(`Setting Firebase secret: ${key} (project: ${finalProjectId})`);
8681
8880
  const tempFile = "";
8682
8881
  try {
8683
8882
  const args = ["functions:secrets:set", key, "--project", finalProjectId];
@@ -8700,8 +8899,8 @@ async function setFirebaseSecret(key, value, projectId, dryRun = false, cwd) {
8700
8899
  }
8701
8900
  if (result.status !== 0) {
8702
8901
  const stderr = result.stderr?.toString() || "";
8703
- const stdout = result.stdout?.toString() || "";
8704
- const errorOutput = stderr || stdout;
8902
+ const stdout2 = result.stdout?.toString() || "";
8903
+ const errorOutput = stderr || stdout2;
8705
8904
  const errorLower = errorOutput.toLowerCase();
8706
8905
  if (errorLower.includes("not logged in") || errorLower.includes("authentication required") || errorLower.includes("please login") || errorLower.includes("run firebase login") || errorLower.includes("unauthorized") || errorOutput.includes("401")) {
8707
8906
  throw new DoNotDevError(
@@ -8751,12 +8950,12 @@ async function setFirebaseSecret(key, value, projectId, dryRun = false, cwd) {
8751
8950
  ${errorOutput}`
8752
8951
  );
8753
8952
  }
8754
- log.success(`Firebase secret ${key} set successfully`);
8953
+ log2.success(`Firebase secret ${key} set successfully`);
8755
8954
  } finally {
8756
8955
  }
8757
8956
  } catch (err) {
8758
8957
  if (err instanceof DoNotDevError) throw err;
8759
- log.error(`Failed to set Firebase secret ${key}:`, err);
8958
+ log2.error(`Failed to set Firebase secret ${key}:`, err);
8760
8959
  throw new DoNotDevError(
8761
8960
  `Failed to set Firebase secret ${key}`,
8762
8961
  "command-failed",
@@ -8793,24 +8992,24 @@ async function resolveVercelCredentialsForSync(appDir, projectIdOverride, dryRun
8793
8992
  projectId: projectIdOverride ?? credResult.credentials.projectId
8794
8993
  };
8795
8994
  if (!dryRun) {
8796
- log.info("Validating Vercel credentials...");
8995
+ log2.info("Validating Vercel credentials...");
8797
8996
  const user = await validateToken(credentials.token);
8798
- log.success(`Vercel token valid (${user.username})`);
8997
+ log2.success(`Vercel token valid (${user.username})`);
8799
8998
  const project = await validateProject(
8800
8999
  credentials.token,
8801
9000
  credentials.projectId,
8802
9001
  credentials.orgId
8803
9002
  );
8804
- log.success(`Vercel project accessible (${project.projectName})`);
9003
+ log2.success(`Vercel project accessible (${project.projectName})`);
8805
9004
  }
8806
9005
  return credentials;
8807
9006
  }
8808
9007
  async function setVercelSecret(key, value, credentials, dryRun = false) {
8809
9008
  if (dryRun) {
8810
- log.info(`[DRY RUN] Would set Vercel environment variable: ${key}`);
9009
+ log2.info(`[DRY RUN] Would set Vercel environment variable: ${key}`);
8811
9010
  return;
8812
9011
  }
8813
- log.info(`Setting Vercel environment variable: ${key}`);
9012
+ log2.info(`Setting Vercel environment variable: ${key}`);
8814
9013
  try {
8815
9014
  const { token, orgId, projectId } = credentials;
8816
9015
  const params = ["upsert=true"];
@@ -8835,9 +9034,9 @@ async function setVercelSecret(key, value, credentials, dryRun = false) {
8835
9034
  const body = await res.text();
8836
9035
  throw formatVercelError(res.status, body, `set env var ${key}`);
8837
9036
  }
8838
- log.success(`Vercel environment variable ${key} set successfully`);
9037
+ log2.success(`Vercel environment variable ${key} set successfully`);
8839
9038
  } catch (err) {
8840
- log.error(`Failed to set Vercel environment variable ${key}:`, err);
9039
+ log2.error(`Failed to set Vercel environment variable ${key}:`, err);
8841
9040
  if (err instanceof DoNotDevError) throw err;
8842
9041
  throw new DoNotDevError(
8843
9042
  `Failed to set Vercel environment variable ${key}`,
@@ -8871,13 +9070,13 @@ function detectGitHubRepo() {
8871
9070
  }
8872
9071
  function setGitHubSecret(key, value, repo, dryRun = false) {
8873
9072
  if (dryRun) {
8874
- log.info(
9073
+ log2.info(
8875
9074
  `[DRY RUN] Would set GitHub secret: ${key}${repo ? ` (repo: ${repo})` : ""}`
8876
9075
  );
8877
9076
  return;
8878
9077
  }
8879
9078
  try {
8880
- log.info(`Setting GitHub secret: ${key}${repo ? ` (repo: ${repo})` : ""}`);
9079
+ log2.info(`Setting GitHub secret: ${key}${repo ? ` (repo: ${repo})` : ""}`);
8881
9080
  const args = ["secret", "set", key];
8882
9081
  if (repo) {
8883
9082
  args.push("--repo", repo);
@@ -8892,8 +9091,8 @@ function setGitHubSecret(key, value, repo, dryRun = false) {
8892
9091
  }
8893
9092
  if (result.status !== 0) {
8894
9093
  const stderr = result.stderr?.toString() || "";
8895
- const stdout = result.stdout?.toString() || "";
8896
- const errorOutput = stderr || stdout;
9094
+ const stdout2 = result.stdout?.toString() || "";
9095
+ const errorOutput = stderr || stdout2;
8897
9096
  if (errorOutput.includes("not logged in") || errorOutput.includes("authentication")) {
8898
9097
  throw new DoNotDevError(
8899
9098
  `GitHub CLI authentication required. Run 'gh auth login' to authenticate.`,
@@ -8906,10 +9105,10 @@ function setGitHubSecret(key, value, repo, dryRun = false) {
8906
9105
  ${errorOutput}`
8907
9106
  );
8908
9107
  }
8909
- log.success(`GitHub secret ${key} set successfully`);
9108
+ log2.success(`GitHub secret ${key} set successfully`);
8910
9109
  } catch (err) {
8911
9110
  if (err instanceof DoNotDevError) throw err;
8912
- log.error(`Failed to set GitHub secret ${key}:`, err);
9111
+ log2.error(`Failed to set GitHub secret ${key}:`, err);
8913
9112
  throw new DoNotDevError(
8914
9113
  `Failed to set GitHub secret ${key}`,
8915
9114
  "command-failed",
@@ -8928,7 +9127,7 @@ function uploadServiceAccountToGitHub(appDir, repo, dryRun = false, staging = fa
8928
9127
  const secretName = staging ? "FIREBASE_SERVICE_ACCOUNT_STAGING" : "FIREBASE_SERVICE_ACCOUNT";
8929
9128
  const filePath = joinPath(appDir, fileName);
8930
9129
  if (!pathExists(filePath)) {
8931
- log.debug(`No ${fileName} found in ${appDir}, skipping GitHub upload`);
9130
+ log2.debug(`No ${fileName} found in ${appDir}, skipping GitHub upload`);
8932
9131
  return;
8933
9132
  }
8934
9133
  const contentRaw = readSync(filePath, { format: "text" });
@@ -8949,7 +9148,7 @@ async function main(options = {}) {
8949
9148
  verbose: options.verbose ?? false
8950
9149
  };
8951
9150
  if (process.argv.includes("--help")) {
8952
- log.info(`
9151
+ log2.info(`
8953
9152
  Secrets Sync Tool
8954
9153
 
8955
9154
  Usage: bun run sync-secrets [options]
@@ -8984,7 +9183,7 @@ Examples:
8984
9183
  let selectedApp;
8985
9184
  if (appsWithFunctions.length === 1) {
8986
9185
  selectedApp = appsWithFunctions[0];
8987
- wt(`Using app: ${selectedApp.name}`, "Auto-detected");
9186
+ note(`Using app: ${selectedApp.name}`, "Auto-detected");
8988
9187
  } else {
8989
9188
  const appName = await askForSelection(
8990
9189
  "Which app would you like to sync secrets for?",
@@ -8994,7 +9193,7 @@ Examples:
8994
9193
  hint: `functions/.env in ${app.name}`
8995
9194
  }))
8996
9195
  );
8997
- selectedApp = appsWithFunctions.find((a) => a.name === appName);
9196
+ selectedApp = appsWithFunctions.find((a2) => a2.name === appName);
8998
9197
  }
8999
9198
  if (selectedApp) {
9000
9199
  const envFileAbsolute = normalizePath(selectedApp.envFile);
@@ -9015,19 +9214,19 @@ Examples:
9015
9214
  if (syncTarget === "github") {
9016
9215
  const repo = config.repo || detectGitHubRepo();
9017
9216
  if (!repo) {
9018
- log.error(
9217
+ log2.error(
9019
9218
  "Could not detect GitHub repository. Use --repo owner/repo or ensure a GitHub remote is configured."
9020
9219
  );
9021
9220
  return 1;
9022
9221
  }
9023
- log.info(`Syncing secrets to GitHub repository: ${repo}`);
9222
+ log2.info(`Syncing secrets to GitHub repository: ${repo}`);
9024
9223
  const secrets2 = parseSecretsWithFallback(envFilePath, currentDir);
9025
9224
  const secretKeys2 = Object.keys(secrets2);
9026
9225
  if (secretKeys2.length === 0) {
9027
- log.info("No secrets found in .env file");
9226
+ log2.info("No secrets found in .env file");
9028
9227
  } else {
9029
- log.info(`Found ${secretKeys2.length} secrets to sync to GitHub:`);
9030
- secretKeys2.forEach((key) => log.info(` ${key}`));
9228
+ log2.info(`Found ${secretKeys2.length} secrets to sync to GitHub:`);
9229
+ secretKeys2.forEach((key) => log2.info(` ${key}`));
9031
9230
  for (const [key, value] of Object.entries(secrets2)) {
9032
9231
  setGitHubSecret(key, value, repo, config.dryRun);
9033
9232
  }
@@ -9050,37 +9249,37 @@ Examples:
9050
9249
  uploadServiceAccountToGitHub(currentDir, repo, config.dryRun, true);
9051
9250
  }
9052
9251
  if (config.dryRun) {
9053
- log.success("\nDry run completed. No GitHub secrets were set.");
9252
+ log2.success("\nDry run completed. No GitHub secrets were set.");
9054
9253
  } else {
9055
- log.success("\nAll secrets synced to GitHub successfully!");
9254
+ log2.success("\nAll secrets synced to GitHub successfully!");
9056
9255
  }
9057
9256
  return 0;
9058
9257
  }
9059
9258
  const platform = config.platform || detectPlatform();
9060
9259
  if (config.verbose) {
9061
- log.debug(`Working directory: ${currentDir}`);
9062
- log.debug(`Environment file: ${envFilePath}`);
9063
- log.debug(`Platform: ${platform}`);
9064
- log.debug(`Dry run mode: ${config.dryRun}`);
9260
+ log2.debug(`Working directory: ${currentDir}`);
9261
+ log2.debug(`Environment file: ${envFilePath}`);
9262
+ log2.debug(`Platform: ${platform}`);
9263
+ log2.debug(`Dry run mode: ${config.dryRun}`);
9065
9264
  }
9066
9265
  const secrets = parseSecretsWithFallback(envFilePath, currentDir);
9067
9266
  const secretKeys = Object.keys(secrets);
9068
9267
  if (secretKeys.length === 0) {
9069
- log.info("No secrets found in .env file");
9268
+ log2.info("No secrets found in .env file");
9070
9269
  return 0;
9071
9270
  }
9072
- log.info(`Found ${secretKeys.length} secrets to sync to ${platform}:`);
9271
+ log2.info(`Found ${secretKeys.length} secrets to sync to ${platform}:`);
9073
9272
  secretKeys.forEach((key) => {
9074
9273
  if (config.verbose) {
9075
9274
  const value = secrets[key];
9076
- log.debug(` ${key}: ${value ? "***" : "undefined"}`);
9275
+ log2.debug(` ${key}: ${value ? "***" : "undefined"}`);
9077
9276
  } else {
9078
- log.info(` ${key}`);
9277
+ log2.info(` ${key}`);
9079
9278
  }
9080
9279
  });
9081
9280
  const finalFirebaseProjectDir = platform === "firebase" ? firebaseProjectDir || findFirebaseProjectDir(config.envFile) : void 0;
9082
9281
  if (config.verbose && finalFirebaseProjectDir) {
9083
- log.debug(`Firebase project directory: ${finalFirebaseProjectDir}`);
9282
+ log2.debug(`Firebase project directory: ${finalFirebaseProjectDir}`);
9084
9283
  }
9085
9284
  const vercelCredentials = platform === "vercel" ? await resolveVercelCredentialsForSync(
9086
9285
  currentDir,
@@ -9101,17 +9300,17 @@ Examples:
9101
9300
  }
9102
9301
  }
9103
9302
  if (config.dryRun) {
9104
- log.success(
9303
+ log2.success(
9105
9304
  `
9106
9305
  Dry run completed. No secrets were actually set to ${platform}.`
9107
9306
  );
9108
9307
  } else {
9109
- log.success(`
9308
+ log2.success(`
9110
9309
  All secrets synced successfully to ${platform}!`);
9111
9310
  }
9112
9311
  return 0;
9113
9312
  } catch (err) {
9114
- log.error(
9313
+ log2.error(
9115
9314
  "Error syncing secrets:",
9116
9315
  DoNotDevError.from(err, "Sync-secrets failed", "cli-execution-error")
9117
9316
  );
@@ -9122,13 +9321,13 @@ var init_sync_secrets = __esm({
9122
9321
  "packages/tooling/src/apps/sync-secrets.ts"() {
9123
9322
  "use strict";
9124
9323
  init_utils2();
9324
+ init_vercel_api();
9325
+ init_vercel_token();
9125
9326
  init_cli_input();
9126
9327
  init_cli_output();
9127
9328
  init_errors();
9128
9329
  init_pathResolver();
9129
9330
  init_secrets_resolver();
9130
- init_vercel_token();
9131
- init_vercel_api();
9132
9331
  }
9133
9332
  });
9134
9333