@simon_he/pi 0.0.92 → 0.0.94

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -62,20 +62,19 @@ var __privateWrapper = (obj, member, setter, getter) => ({
62
62
  }
63
63
  });
64
64
 
65
- // node_modules/picocolors/picocolors.js
65
+ // node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js
66
66
  var require_picocolors = __commonJS({
67
- "node_modules/picocolors/picocolors.js"(exports, module) {
68
- var argv = process.argv || [];
69
- var env3 = process.env;
70
- var isColorSupported = !("NO_COLOR" in env3 || argv.includes("--no-color")) && ("FORCE_COLOR" in env3 || argv.includes("--color") || process.platform === "win32" || __require != null && __require("tty").isatty(1) && env3.TERM !== "dumb" || "CI" in env3);
67
+ "node_modules/.pnpm/picocolors@1.1.1/node_modules/picocolors/picocolors.js"(exports, module) {
68
+ var p = process || {};
69
+ var argv = p.argv || [];
70
+ var env3 = p.env || {};
71
+ var isColorSupported = !(!!env3.NO_COLOR || argv.includes("--no-color")) && (!!env3.FORCE_COLOR || argv.includes("--color") || p.platform === "win32" || (p.stdout || {}).isTTY && env3.TERM !== "dumb" || !!env3.CI);
71
72
  var formatter = (open, close, replace = open) => (input) => {
72
- let string = "" + input;
73
- let index = string.indexOf(close, open.length);
73
+ let string = "" + input, index = string.indexOf(close, open.length);
74
74
  return ~index ? open + replaceClose(string, close, replace, index) + close : open + string + close;
75
75
  };
76
76
  var replaceClose = (string, close, replace, index) => {
77
- let result = "";
78
- let cursor = 0;
77
+ let result = "", cursor = 0;
79
78
  do {
80
79
  result += string.substring(cursor, index) + replace;
81
80
  cursor = index + close.length;
@@ -84,50 +83,50 @@ var require_picocolors = __commonJS({
84
83
  return result + string.substring(cursor);
85
84
  };
86
85
  var createColors = (enabled = isColorSupported) => {
87
- let init = enabled ? formatter : () => String;
86
+ let f = enabled ? formatter : () => String;
88
87
  return {
89
88
  isColorSupported: enabled,
90
- reset: init("\x1B[0m", "\x1B[0m"),
91
- bold: init("\x1B[1m", "\x1B[22m", "\x1B[22m\x1B[1m"),
92
- dim: init("\x1B[2m", "\x1B[22m", "\x1B[22m\x1B[2m"),
93
- italic: init("\x1B[3m", "\x1B[23m"),
94
- underline: init("\x1B[4m", "\x1B[24m"),
95
- inverse: init("\x1B[7m", "\x1B[27m"),
96
- hidden: init("\x1B[8m", "\x1B[28m"),
97
- strikethrough: init("\x1B[9m", "\x1B[29m"),
98
- black: init("\x1B[30m", "\x1B[39m"),
99
- red: init("\x1B[31m", "\x1B[39m"),
100
- green: init("\x1B[32m", "\x1B[39m"),
101
- yellow: init("\x1B[33m", "\x1B[39m"),
102
- blue: init("\x1B[34m", "\x1B[39m"),
103
- magenta: init("\x1B[35m", "\x1B[39m"),
104
- cyan: init("\x1B[36m", "\x1B[39m"),
105
- white: init("\x1B[37m", "\x1B[39m"),
106
- gray: init("\x1B[90m", "\x1B[39m"),
107
- bgBlack: init("\x1B[40m", "\x1B[49m"),
108
- bgRed: init("\x1B[41m", "\x1B[49m"),
109
- bgGreen: init("\x1B[42m", "\x1B[49m"),
110
- bgYellow: init("\x1B[43m", "\x1B[49m"),
111
- bgBlue: init("\x1B[44m", "\x1B[49m"),
112
- bgMagenta: init("\x1B[45m", "\x1B[49m"),
113
- bgCyan: init("\x1B[46m", "\x1B[49m"),
114
- bgWhite: init("\x1B[47m", "\x1B[49m"),
115
- blackBright: init("\x1B[90m", "\x1B[39m"),
116
- redBright: init("\x1B[91m", "\x1B[39m"),
117
- greenBright: init("\x1B[92m", "\x1B[39m"),
118
- yellowBright: init("\x1B[93m", "\x1B[39m"),
119
- blueBright: init("\x1B[94m", "\x1B[39m"),
120
- magentaBright: init("\x1B[95m", "\x1B[39m"),
121
- cyanBright: init("\x1B[96m", "\x1B[39m"),
122
- whiteBright: init("\x1B[97m", "\x1B[39m"),
123
- bgBlackBright: init("\x1B[100m", "\x1B[49m"),
124
- bgRedBright: init("\x1B[101m", "\x1B[49m"),
125
- bgGreenBright: init("\x1B[102m", "\x1B[49m"),
126
- bgYellowBright: init("\x1B[103m", "\x1B[49m"),
127
- bgBlueBright: init("\x1B[104m", "\x1B[49m"),
128
- bgMagentaBright: init("\x1B[105m", "\x1B[49m"),
129
- bgCyanBright: init("\x1B[106m", "\x1B[49m"),
130
- bgWhiteBright: init("\x1B[107m", "\x1B[49m")
89
+ reset: f("\x1B[0m", "\x1B[0m"),
90
+ bold: f("\x1B[1m", "\x1B[22m", "\x1B[22m\x1B[1m"),
91
+ dim: f("\x1B[2m", "\x1B[22m", "\x1B[22m\x1B[2m"),
92
+ italic: f("\x1B[3m", "\x1B[23m"),
93
+ underline: f("\x1B[4m", "\x1B[24m"),
94
+ inverse: f("\x1B[7m", "\x1B[27m"),
95
+ hidden: f("\x1B[8m", "\x1B[28m"),
96
+ strikethrough: f("\x1B[9m", "\x1B[29m"),
97
+ black: f("\x1B[30m", "\x1B[39m"),
98
+ red: f("\x1B[31m", "\x1B[39m"),
99
+ green: f("\x1B[32m", "\x1B[39m"),
100
+ yellow: f("\x1B[33m", "\x1B[39m"),
101
+ blue: f("\x1B[34m", "\x1B[39m"),
102
+ magenta: f("\x1B[35m", "\x1B[39m"),
103
+ cyan: f("\x1B[36m", "\x1B[39m"),
104
+ white: f("\x1B[37m", "\x1B[39m"),
105
+ gray: f("\x1B[90m", "\x1B[39m"),
106
+ bgBlack: f("\x1B[40m", "\x1B[49m"),
107
+ bgRed: f("\x1B[41m", "\x1B[49m"),
108
+ bgGreen: f("\x1B[42m", "\x1B[49m"),
109
+ bgYellow: f("\x1B[43m", "\x1B[49m"),
110
+ bgBlue: f("\x1B[44m", "\x1B[49m"),
111
+ bgMagenta: f("\x1B[45m", "\x1B[49m"),
112
+ bgCyan: f("\x1B[46m", "\x1B[49m"),
113
+ bgWhite: f("\x1B[47m", "\x1B[49m"),
114
+ blackBright: f("\x1B[90m", "\x1B[39m"),
115
+ redBright: f("\x1B[91m", "\x1B[39m"),
116
+ greenBright: f("\x1B[92m", "\x1B[39m"),
117
+ yellowBright: f("\x1B[93m", "\x1B[39m"),
118
+ blueBright: f("\x1B[94m", "\x1B[39m"),
119
+ magentaBright: f("\x1B[95m", "\x1B[39m"),
120
+ cyanBright: f("\x1B[96m", "\x1B[39m"),
121
+ whiteBright: f("\x1B[97m", "\x1B[39m"),
122
+ bgBlackBright: f("\x1B[100m", "\x1B[49m"),
123
+ bgRedBright: f("\x1B[101m", "\x1B[49m"),
124
+ bgGreenBright: f("\x1B[102m", "\x1B[49m"),
125
+ bgYellowBright: f("\x1B[103m", "\x1B[49m"),
126
+ bgBlueBright: f("\x1B[104m", "\x1B[49m"),
127
+ bgMagentaBright: f("\x1B[105m", "\x1B[49m"),
128
+ bgCyanBright: f("\x1B[106m", "\x1B[49m"),
129
+ bgWhiteBright: f("\x1B[107m", "\x1B[49m")
131
130
  };
132
131
  };
133
132
  module.exports = createColors();
@@ -135,9 +134,9 @@ var require_picocolors = __commonJS({
135
134
  }
136
135
  });
137
136
 
138
- // node_modules/restore-cursor/node_modules/onetime/node_modules/mimic-fn/index.js
137
+ // node_modules/.pnpm/mimic-fn@2.1.0/node_modules/mimic-fn/index.js
139
138
  var require_mimic_fn = __commonJS({
140
- "node_modules/restore-cursor/node_modules/onetime/node_modules/mimic-fn/index.js"(exports, module) {
139
+ "node_modules/.pnpm/mimic-fn@2.1.0/node_modules/mimic-fn/index.js"(exports, module) {
141
140
  "use strict";
142
141
  var mimicFn = (to, from) => {
143
142
  for (const prop of Reflect.ownKeys(from)) {
@@ -150,9 +149,9 @@ var require_mimic_fn = __commonJS({
150
149
  }
151
150
  });
152
151
 
153
- // node_modules/restore-cursor/node_modules/onetime/index.js
152
+ // node_modules/.pnpm/onetime@5.1.2/node_modules/onetime/index.js
154
153
  var require_onetime = __commonJS({
155
- "node_modules/restore-cursor/node_modules/onetime/index.js"(exports, module) {
154
+ "node_modules/.pnpm/onetime@5.1.2/node_modules/onetime/index.js"(exports, module) {
156
155
  "use strict";
157
156
  var mimicFn = require_mimic_fn();
158
157
  var calledFunctions = /* @__PURE__ */ new WeakMap();
@@ -188,9 +187,9 @@ var require_onetime = __commonJS({
188
187
  }
189
188
  });
190
189
 
191
- // node_modules/signal-exit/signals.js
190
+ // node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js
192
191
  var require_signals = __commonJS({
193
- "node_modules/signal-exit/signals.js"(exports, module) {
192
+ "node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/signals.js"(exports, module) {
194
193
  module.exports = [
195
194
  "SIGABRT",
196
195
  "SIGALRM",
@@ -225,9 +224,9 @@ var require_signals = __commonJS({
225
224
  }
226
225
  });
227
226
 
228
- // node_modules/signal-exit/index.js
227
+ // node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js
229
228
  var require_signal_exit = __commonJS({
230
- "node_modules/signal-exit/index.js"(exports, module) {
229
+ "node_modules/.pnpm/signal-exit@3.0.7/node_modules/signal-exit/index.js"(exports, module) {
231
230
  var process13 = global.process;
232
231
  var processOk = function(process14) {
233
232
  return process14 && typeof process14 === "object" && typeof process14.removeListener === "function" && typeof process14.emit === "function" && typeof process14.reallyExit === "function" && typeof process14.listeners === "function" && typeof process14.kill === "function" && typeof process14.pid === "number" && typeof process14.on === "function";
@@ -384,9 +383,9 @@ var require_signal_exit = __commonJS({
384
383
  }
385
384
  });
386
385
 
387
- // node_modules/cli-spinners/spinners.json
386
+ // node_modules/.pnpm/cli-spinners@2.9.1/node_modules/cli-spinners/spinners.json
388
387
  var require_spinners = __commonJS({
389
- "node_modules/cli-spinners/spinners.json"(exports, module) {
388
+ "node_modules/.pnpm/cli-spinners@2.9.1/node_modules/cli-spinners/spinners.json"(exports, module) {
390
389
  module.exports = {
391
390
  dots: {
392
391
  interval: 80,
@@ -2012,9 +2011,9 @@ var require_spinners = __commonJS({
2012
2011
  }
2013
2012
  });
2014
2013
 
2015
- // node_modules/cli-spinners/index.js
2014
+ // node_modules/.pnpm/cli-spinners@2.9.1/node_modules/cli-spinners/index.js
2016
2015
  var require_cli_spinners = __commonJS({
2017
- "node_modules/cli-spinners/index.js"(exports, module) {
2016
+ "node_modules/.pnpm/cli-spinners@2.9.1/node_modules/cli-spinners/index.js"(exports, module) {
2018
2017
  "use strict";
2019
2018
  var spinners = Object.assign({}, require_spinners());
2020
2019
  var spinnersList = Object.keys(spinners);
@@ -2029,9 +2028,9 @@ var require_cli_spinners = __commonJS({
2029
2028
  }
2030
2029
  });
2031
2030
 
2032
- // node_modules/clone/clone.js
2031
+ // node_modules/.pnpm/clone@1.0.4/node_modules/clone/clone.js
2033
2032
  var require_clone = __commonJS({
2034
- "node_modules/clone/clone.js"(exports, module) {
2033
+ "node_modules/.pnpm/clone@1.0.4/node_modules/clone/clone.js"(exports, module) {
2035
2034
  var clone = function() {
2036
2035
  "use strict";
2037
2036
  function clone2(parent, circular, depth, prototype) {
@@ -2154,9 +2153,9 @@ var require_clone = __commonJS({
2154
2153
  }
2155
2154
  });
2156
2155
 
2157
- // node_modules/defaults/index.js
2156
+ // node_modules/.pnpm/defaults@1.0.4/node_modules/defaults/index.js
2158
2157
  var require_defaults = __commonJS({
2159
- "node_modules/defaults/index.js"(exports, module) {
2158
+ "node_modules/.pnpm/defaults@1.0.4/node_modules/defaults/index.js"(exports, module) {
2160
2159
  var clone = require_clone();
2161
2160
  module.exports = function(options, defaults) {
2162
2161
  options = options || {};
@@ -2170,9 +2169,9 @@ var require_defaults = __commonJS({
2170
2169
  }
2171
2170
  });
2172
2171
 
2173
- // node_modules/wcwidth/combining.js
2172
+ // node_modules/.pnpm/wcwidth@1.0.1/node_modules/wcwidth/combining.js
2174
2173
  var require_combining = __commonJS({
2175
- "node_modules/wcwidth/combining.js"(exports, module) {
2174
+ "node_modules/.pnpm/wcwidth@1.0.1/node_modules/wcwidth/combining.js"(exports, module) {
2176
2175
  module.exports = [
2177
2176
  [768, 879],
2178
2177
  [1155, 1158],
@@ -2320,9 +2319,9 @@ var require_combining = __commonJS({
2320
2319
  }
2321
2320
  });
2322
2321
 
2323
- // node_modules/wcwidth/index.js
2322
+ // node_modules/.pnpm/wcwidth@1.0.1/node_modules/wcwidth/index.js
2324
2323
  var require_wcwidth = __commonJS({
2325
- "node_modules/wcwidth/index.js"(exports, module) {
2324
+ "node_modules/.pnpm/wcwidth@1.0.1/node_modules/wcwidth/index.js"(exports, module) {
2326
2325
  "use strict";
2327
2326
  var defaults = require_defaults();
2328
2327
  var combining = require_combining();
@@ -2387,16 +2386,16 @@ var require_wcwidth = __commonJS({
2387
2386
  }
2388
2387
  });
2389
2388
 
2390
- // node_modules/readable-stream/lib/internal/streams/stream.js
2389
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/stream.js
2391
2390
  var require_stream = __commonJS({
2392
- "node_modules/readable-stream/lib/internal/streams/stream.js"(exports, module) {
2391
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/stream.js"(exports, module) {
2393
2392
  module.exports = __require("stream");
2394
2393
  }
2395
2394
  });
2396
2395
 
2397
- // node_modules/readable-stream/lib/internal/streams/buffer_list.js
2396
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/buffer_list.js
2398
2397
  var require_buffer_list = __commonJS({
2399
- "node_modules/readable-stream/lib/internal/streams/buffer_list.js"(exports, module) {
2398
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/buffer_list.js"(exports, module) {
2400
2399
  "use strict";
2401
2400
  function ownKeys(object, enumerableOnly) {
2402
2401
  var keys = Object.keys(object);
@@ -2656,9 +2655,9 @@ var require_buffer_list = __commonJS({
2656
2655
  }
2657
2656
  });
2658
2657
 
2659
- // node_modules/readable-stream/lib/internal/streams/destroy.js
2658
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/destroy.js
2660
2659
  var require_destroy = __commonJS({
2661
- "node_modules/readable-stream/lib/internal/streams/destroy.js"(exports, module) {
2660
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/destroy.js"(exports, module) {
2662
2661
  "use strict";
2663
2662
  function destroy(err, cb) {
2664
2663
  var _this = this;
@@ -2749,9 +2748,9 @@ var require_destroy = __commonJS({
2749
2748
  }
2750
2749
  });
2751
2750
 
2752
- // node_modules/readable-stream/errors.js
2751
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/errors.js
2753
2752
  var require_errors = __commonJS({
2754
- "node_modules/readable-stream/errors.js"(exports, module) {
2753
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/errors.js"(exports, module) {
2755
2754
  "use strict";
2756
2755
  var codes = {};
2757
2756
  function createErrorType(code, message, Base) {
@@ -2849,9 +2848,9 @@ var require_errors = __commonJS({
2849
2848
  }
2850
2849
  });
2851
2850
 
2852
- // node_modules/readable-stream/lib/internal/streams/state.js
2851
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/state.js
2853
2852
  var require_state = __commonJS({
2854
- "node_modules/readable-stream/lib/internal/streams/state.js"(exports, module) {
2853
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/state.js"(exports, module) {
2855
2854
  "use strict";
2856
2855
  var ERR_INVALID_OPT_VALUE = require_errors().codes.ERR_INVALID_OPT_VALUE;
2857
2856
  function highWaterMarkFrom(options, isDuplex, duplexKey) {
@@ -2874,9 +2873,9 @@ var require_state = __commonJS({
2874
2873
  }
2875
2874
  });
2876
2875
 
2877
- // node_modules/inherits/inherits_browser.js
2876
+ // node_modules/.pnpm/inherits@2.0.4/node_modules/inherits/inherits_browser.js
2878
2877
  var require_inherits_browser = __commonJS({
2879
- "node_modules/inherits/inherits_browser.js"(exports, module) {
2878
+ "node_modules/.pnpm/inherits@2.0.4/node_modules/inherits/inherits_browser.js"(exports, module) {
2880
2879
  if (typeof Object.create === "function") {
2881
2880
  module.exports = function inherits(ctor, superCtor) {
2882
2881
  if (superCtor) {
@@ -2906,9 +2905,9 @@ var require_inherits_browser = __commonJS({
2906
2905
  }
2907
2906
  });
2908
2907
 
2909
- // node_modules/inherits/inherits.js
2908
+ // node_modules/.pnpm/inherits@2.0.4/node_modules/inherits/inherits.js
2910
2909
  var require_inherits = __commonJS({
2911
- "node_modules/inherits/inherits.js"(exports, module) {
2910
+ "node_modules/.pnpm/inherits@2.0.4/node_modules/inherits/inherits.js"(exports, module) {
2912
2911
  try {
2913
2912
  util = __require("util");
2914
2913
  if (typeof util.inherits !== "function")
@@ -2921,16 +2920,16 @@ var require_inherits = __commonJS({
2921
2920
  }
2922
2921
  });
2923
2922
 
2924
- // node_modules/util-deprecate/node.js
2923
+ // node_modules/.pnpm/util-deprecate@1.0.2/node_modules/util-deprecate/node.js
2925
2924
  var require_node = __commonJS({
2926
- "node_modules/util-deprecate/node.js"(exports, module) {
2925
+ "node_modules/.pnpm/util-deprecate@1.0.2/node_modules/util-deprecate/node.js"(exports, module) {
2927
2926
  module.exports = __require("util").deprecate;
2928
2927
  }
2929
2928
  });
2930
2929
 
2931
- // node_modules/readable-stream/lib/_stream_writable.js
2930
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_writable.js
2932
2931
  var require_stream_writable = __commonJS({
2933
- "node_modules/readable-stream/lib/_stream_writable.js"(exports, module) {
2932
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_writable.js"(exports, module) {
2934
2933
  "use strict";
2935
2934
  module.exports = Writable;
2936
2935
  function CorkedRequest(state) {
@@ -3428,9 +3427,9 @@ var require_stream_writable = __commonJS({
3428
3427
  }
3429
3428
  });
3430
3429
 
3431
- // node_modules/readable-stream/lib/_stream_duplex.js
3430
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_duplex.js
3432
3431
  var require_stream_duplex = __commonJS({
3433
- "node_modules/readable-stream/lib/_stream_duplex.js"(exports, module) {
3432
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_duplex.js"(exports, module) {
3434
3433
  "use strict";
3435
3434
  var objectKeys = Object.keys || function(obj) {
3436
3435
  var keys2 = [];
@@ -3527,9 +3526,9 @@ var require_stream_duplex = __commonJS({
3527
3526
  }
3528
3527
  });
3529
3528
 
3530
- // node_modules/safe-buffer/index.js
3529
+ // node_modules/.pnpm/safe-buffer@5.2.1/node_modules/safe-buffer/index.js
3531
3530
  var require_safe_buffer = __commonJS({
3532
- "node_modules/safe-buffer/index.js"(exports, module) {
3531
+ "node_modules/.pnpm/safe-buffer@5.2.1/node_modules/safe-buffer/index.js"(exports, module) {
3533
3532
  var buffer = __require("buffer");
3534
3533
  var Buffer2 = buffer.Buffer;
3535
3534
  function copyProps(src, dst) {
@@ -3585,9 +3584,9 @@ var require_safe_buffer = __commonJS({
3585
3584
  }
3586
3585
  });
3587
3586
 
3588
- // node_modules/string_decoder/lib/string_decoder.js
3587
+ // node_modules/.pnpm/string_decoder@1.3.0/node_modules/string_decoder/lib/string_decoder.js
3589
3588
  var require_string_decoder = __commonJS({
3590
- "node_modules/string_decoder/lib/string_decoder.js"(exports) {
3589
+ "node_modules/.pnpm/string_decoder@1.3.0/node_modules/string_decoder/lib/string_decoder.js"(exports) {
3591
3590
  "use strict";
3592
3591
  var Buffer2 = require_safe_buffer().Buffer;
3593
3592
  var isEncoding = Buffer2.isEncoding || function(encoding) {
@@ -3845,9 +3844,9 @@ var require_string_decoder = __commonJS({
3845
3844
  }
3846
3845
  });
3847
3846
 
3848
- // node_modules/readable-stream/lib/internal/streams/end-of-stream.js
3847
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/end-of-stream.js
3849
3848
  var require_end_of_stream = __commonJS({
3850
- "node_modules/readable-stream/lib/internal/streams/end-of-stream.js"(exports, module) {
3849
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/end-of-stream.js"(exports, module) {
3851
3850
  "use strict";
3852
3851
  var ERR_STREAM_PREMATURE_CLOSE = require_errors().codes.ERR_STREAM_PREMATURE_CLOSE;
3853
3852
  function once(callback) {
@@ -3946,9 +3945,9 @@ var require_end_of_stream = __commonJS({
3946
3945
  }
3947
3946
  });
3948
3947
 
3949
- // node_modules/readable-stream/lib/internal/streams/async_iterator.js
3948
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/async_iterator.js
3950
3949
  var require_async_iterator = __commonJS({
3951
- "node_modules/readable-stream/lib/internal/streams/async_iterator.js"(exports, module) {
3950
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/async_iterator.js"(exports, module) {
3952
3951
  "use strict";
3953
3952
  var _Object$setPrototypeO;
3954
3953
  function _defineProperty(obj, key, value) {
@@ -4131,9 +4130,9 @@ var require_async_iterator = __commonJS({
4131
4130
  }
4132
4131
  });
4133
4132
 
4134
- // node_modules/readable-stream/lib/internal/streams/from.js
4133
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/from.js
4135
4134
  var require_from = __commonJS({
4136
- "node_modules/readable-stream/lib/internal/streams/from.js"(exports, module) {
4135
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/from.js"(exports, module) {
4137
4136
  "use strict";
4138
4137
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
4139
4138
  try {
@@ -4257,9 +4256,9 @@ var require_from = __commonJS({
4257
4256
  }
4258
4257
  });
4259
4258
 
4260
- // node_modules/readable-stream/lib/_stream_readable.js
4259
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_readable.js
4261
4260
  var require_stream_readable = __commonJS({
4262
- "node_modules/readable-stream/lib/_stream_readable.js"(exports, module) {
4261
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_readable.js"(exports, module) {
4263
4262
  "use strict";
4264
4263
  module.exports = Readable;
4265
4264
  var Duplex;
@@ -5053,9 +5052,9 @@ var require_stream_readable = __commonJS({
5053
5052
  }
5054
5053
  });
5055
5054
 
5056
- // node_modules/readable-stream/lib/_stream_transform.js
5055
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_transform.js
5057
5056
  var require_stream_transform = __commonJS({
5058
- "node_modules/readable-stream/lib/_stream_transform.js"(exports, module) {
5057
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_transform.js"(exports, module) {
5059
5058
  "use strict";
5060
5059
  module.exports = Transform;
5061
5060
  var _require$codes = require_errors().codes;
@@ -5161,9 +5160,9 @@ var require_stream_transform = __commonJS({
5161
5160
  }
5162
5161
  });
5163
5162
 
5164
- // node_modules/readable-stream/lib/_stream_passthrough.js
5163
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_passthrough.js
5165
5164
  var require_stream_passthrough = __commonJS({
5166
- "node_modules/readable-stream/lib/_stream_passthrough.js"(exports, module) {
5165
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/_stream_passthrough.js"(exports, module) {
5167
5166
  "use strict";
5168
5167
  module.exports = PassThrough;
5169
5168
  var Transform = require_stream_transform();
@@ -5179,9 +5178,9 @@ var require_stream_passthrough = __commonJS({
5179
5178
  }
5180
5179
  });
5181
5180
 
5182
- // node_modules/readable-stream/lib/internal/streams/pipeline.js
5181
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/pipeline.js
5183
5182
  var require_pipeline = __commonJS({
5184
- "node_modules/readable-stream/lib/internal/streams/pipeline.js"(exports, module) {
5183
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/lib/internal/streams/pipeline.js"(exports, module) {
5185
5184
  "use strict";
5186
5185
  var eos;
5187
5186
  function once(callback) {
@@ -5278,9 +5277,9 @@ var require_pipeline = __commonJS({
5278
5277
  }
5279
5278
  });
5280
5279
 
5281
- // node_modules/readable-stream/readable.js
5280
+ // node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/readable.js
5282
5281
  var require_readable = __commonJS({
5283
- "node_modules/readable-stream/readable.js"(exports, module) {
5282
+ "node_modules/.pnpm/readable-stream@3.6.2/node_modules/readable-stream/readable.js"(exports, module) {
5284
5283
  var Stream = __require("stream");
5285
5284
  if (process.env.READABLE_STREAM === "disable" && Stream) {
5286
5285
  module.exports = Stream.Readable;
@@ -5300,9 +5299,9 @@ var require_readable = __commonJS({
5300
5299
  }
5301
5300
  });
5302
5301
 
5303
- // node_modules/bl/BufferList.js
5302
+ // node_modules/.pnpm/bl@5.1.0/node_modules/bl/BufferList.js
5304
5303
  var require_BufferList = __commonJS({
5305
- "node_modules/bl/BufferList.js"(exports, module) {
5304
+ "node_modules/.pnpm/bl@5.1.0/node_modules/bl/BufferList.js"(exports, module) {
5306
5305
  "use strict";
5307
5306
  var { Buffer: Buffer2 } = __require("buffer");
5308
5307
  var symbol = Symbol.for("BufferList");
@@ -5604,9 +5603,9 @@ var require_BufferList = __commonJS({
5604
5603
  }
5605
5604
  });
5606
5605
 
5607
- // node_modules/bl/bl.js
5606
+ // node_modules/.pnpm/bl@5.1.0/node_modules/bl/bl.js
5608
5607
  var require_bl = __commonJS({
5609
- "node_modules/bl/bl.js"(exports, module) {
5608
+ "node_modules/.pnpm/bl@5.1.0/node_modules/bl/bl.js"(exports, module) {
5610
5609
  "use strict";
5611
5610
  var DuplexStream = require_readable().Duplex;
5612
5611
  var inherits = require_inherits();
@@ -5678,26 +5677,20 @@ var require_bl = __commonJS({
5678
5677
  // src/index.ts
5679
5678
  var import_picocolors8 = __toESM(require_picocolors(), 1);
5680
5679
  import process12 from "process";
5681
- import {
5682
- hasPkg,
5683
- isGo,
5684
- isRust,
5685
- isWin,
5686
- jsShell as jsShell12,
5687
- spaceFormat,
5688
- useNodeWorker as useNodeWorker4
5689
- } from "lazy-js-utils";
5680
+ import { hasPkg, jsShell as jsShell12, useNodeWorker as useNodeWorker4 } from "lazy-js-utils/dist/node";
5681
+ import { isGo, isRust, isWin, spaceFormat } from "lazy-js-utils";
5690
5682
  import fg from "fast-glob";
5691
5683
  import { ccommand as ccommand3 } from "ccommand";
5692
5684
 
5693
5685
  // src/utils.ts
5694
5686
  import path from "path";
5695
- import { getPkg, getPkgTool, isFile, jsShell } from "lazy-js-utils";
5687
+ import { getPkg, getPkgTool, jsShell } from "lazy-js-utils/dist/node";
5688
+ import { isFile } from "lazy-js-utils";
5696
5689
 
5697
- // node_modules/ora/index.js
5690
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/index.js
5698
5691
  import process8 from "process";
5699
5692
 
5700
- // node_modules/ora/node_modules/chalk/source/vendor/ansi-styles/index.js
5693
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/node_modules/chalk/source/vendor/ansi-styles/index.js
5701
5694
  var ANSI_BACKGROUND_OFFSET = 10;
5702
5695
  var wrapAnsi16 = (offset = 0) => (code) => `\x1B[${code + offset}m`;
5703
5696
  var wrapAnsi256 = (offset = 0) => (code) => `\x1B[${38 + offset};5;${code}m`;
@@ -5883,7 +5876,7 @@ function assembleStyles() {
5883
5876
  var ansiStyles = assembleStyles();
5884
5877
  var ansi_styles_default = ansiStyles;
5885
5878
 
5886
- // node_modules/ora/node_modules/chalk/source/vendor/supports-color/index.js
5879
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/node_modules/chalk/source/vendor/supports-color/index.js
5887
5880
  import process2 from "process";
5888
5881
  import os from "os";
5889
5882
  import tty from "tty";
@@ -6009,7 +6002,7 @@ var supportsColor = {
6009
6002
  };
6010
6003
  var supports_color_default = supportsColor;
6011
6004
 
6012
- // node_modules/ora/node_modules/chalk/source/utilities.js
6005
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/node_modules/chalk/source/utilities.js
6013
6006
  function stringReplaceAll(string, substring, replacer) {
6014
6007
  let index = string.indexOf(substring);
6015
6008
  if (index === -1) {
@@ -6039,7 +6032,7 @@ function stringEncaseCRLFWithFirstIndex(string, prefix, postfix, index) {
6039
6032
  return returnValue;
6040
6033
  }
6041
6034
 
6042
- // node_modules/ora/node_modules/chalk/source/index.js
6035
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/node_modules/chalk/source/index.js
6043
6036
  var { stdout: stdoutColor, stderr: stderrColor } = supports_color_default;
6044
6037
  var GENERATOR = Symbol("GENERATOR");
6045
6038
  var STYLER = Symbol("STYLER");
@@ -6186,10 +6179,10 @@ var chalk = createChalk();
6186
6179
  var chalkStderr = createChalk({ level: stderrColor ? stderrColor.level : 0 });
6187
6180
  var source_default = chalk;
6188
6181
 
6189
- // node_modules/cli-cursor/index.js
6182
+ // node_modules/.pnpm/cli-cursor@4.0.0/node_modules/cli-cursor/index.js
6190
6183
  import process4 from "process";
6191
6184
 
6192
- // node_modules/restore-cursor/index.js
6185
+ // node_modules/.pnpm/restore-cursor@4.0.0/node_modules/restore-cursor/index.js
6193
6186
  var import_onetime = __toESM(require_onetime(), 1);
6194
6187
  var import_signal_exit = __toESM(require_signal_exit(), 1);
6195
6188
  import process3 from "process";
@@ -6200,7 +6193,7 @@ var restoreCursor = (0, import_onetime.default)(() => {
6200
6193
  });
6201
6194
  var restore_cursor_default = restoreCursor;
6202
6195
 
6203
- // node_modules/cli-cursor/index.js
6196
+ // node_modules/.pnpm/cli-cursor@4.0.0/node_modules/cli-cursor/index.js
6204
6197
  var isHidden = false;
6205
6198
  var cliCursor = {};
6206
6199
  cliCursor.show = (writableStream = process4.stderr) => {
@@ -6230,10 +6223,10 @@ cliCursor.toggle = (force, writableStream) => {
6230
6223
  };
6231
6224
  var cli_cursor_default = cliCursor;
6232
6225
 
6233
- // node_modules/ora/index.js
6226
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/index.js
6234
6227
  var import_cli_spinners = __toESM(require_cli_spinners(), 1);
6235
6228
 
6236
- // node_modules/log-symbols/node_modules/chalk/source/vendor/ansi-styles/index.js
6229
+ // node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/vendor/ansi-styles/index.js
6237
6230
  var ANSI_BACKGROUND_OFFSET2 = 10;
6238
6231
  var wrapAnsi162 = (offset = 0) => (code) => `\x1B[${code + offset}m`;
6239
6232
  var wrapAnsi2562 = (offset = 0) => (code) => `\x1B[${38 + offset};5;${code}m`;
@@ -6419,7 +6412,7 @@ function assembleStyles2() {
6419
6412
  var ansiStyles2 = assembleStyles2();
6420
6413
  var ansi_styles_default2 = ansiStyles2;
6421
6414
 
6422
- // node_modules/log-symbols/node_modules/chalk/source/vendor/supports-color/index.js
6415
+ // node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/vendor/supports-color/index.js
6423
6416
  import process5 from "process";
6424
6417
  import os2 from "os";
6425
6418
  import tty2 from "tty";
@@ -6545,7 +6538,7 @@ var supportsColor2 = {
6545
6538
  };
6546
6539
  var supports_color_default2 = supportsColor2;
6547
6540
 
6548
- // node_modules/log-symbols/node_modules/chalk/source/utilities.js
6541
+ // node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/utilities.js
6549
6542
  function stringReplaceAll2(string, substring, replacer) {
6550
6543
  let index = string.indexOf(substring);
6551
6544
  if (index === -1) {
@@ -6575,7 +6568,7 @@ function stringEncaseCRLFWithFirstIndex2(string, prefix, postfix, index) {
6575
6568
  return returnValue;
6576
6569
  }
6577
6570
 
6578
- // node_modules/log-symbols/node_modules/chalk/source/index.js
6571
+ // node_modules/.pnpm/chalk@5.3.0/node_modules/chalk/source/index.js
6579
6572
  var { stdout: stdoutColor2, stderr: stderrColor2 } = supports_color_default2;
6580
6573
  var GENERATOR2 = Symbol("GENERATOR");
6581
6574
  var STYLER2 = Symbol("STYLER");
@@ -6722,7 +6715,7 @@ var chalk2 = createChalk2();
6722
6715
  var chalkStderr2 = createChalk2({ level: stderrColor2 ? stderrColor2.level : 0 });
6723
6716
  var source_default2 = chalk2;
6724
6717
 
6725
- // node_modules/is-unicode-supported/index.js
6718
+ // node_modules/.pnpm/is-unicode-supported@1.3.0/node_modules/is-unicode-supported/index.js
6726
6719
  import process6 from "process";
6727
6720
  function isUnicodeSupported() {
6728
6721
  if (process6.platform !== "win32") {
@@ -6731,7 +6724,7 @@ function isUnicodeSupported() {
6731
6724
  return Boolean(process6.env.CI) || Boolean(process6.env.WT_SESSION) || Boolean(process6.env.TERMINUS_SUBLIME) || process6.env.ConEmuTask === "{cmd::Cmder}" || process6.env.TERM_PROGRAM === "Terminus-Sublime" || process6.env.TERM_PROGRAM === "vscode" || process6.env.TERM === "xterm-256color" || process6.env.TERM === "alacritty" || process6.env.TERMINAL_EMULATOR === "JetBrains-JediTerm";
6732
6725
  }
6733
6726
 
6734
- // node_modules/log-symbols/index.js
6727
+ // node_modules/.pnpm/log-symbols@5.1.0/node_modules/log-symbols/index.js
6735
6728
  var main = {
6736
6729
  info: source_default2.blue("\u2139"),
6737
6730
  success: source_default2.green("\u2714"),
@@ -6747,7 +6740,7 @@ var fallback = {
6747
6740
  var logSymbols = isUnicodeSupported() ? main : fallback;
6748
6741
  var log_symbols_default = logSymbols;
6749
6742
 
6750
- // node_modules/ora/node_modules/strip-ansi/node_modules/ansi-regex/index.js
6743
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/node_modules/strip-ansi/node_modules/ansi-regex/index.js
6751
6744
  function ansiRegex({ onlyFirst = false } = {}) {
6752
6745
  const ST = "(?:\\u0007|\\u001B\\u005C|\\u009C)";
6753
6746
  const pattern = [
@@ -6757,7 +6750,7 @@ function ansiRegex({ onlyFirst = false } = {}) {
6757
6750
  return new RegExp(pattern, onlyFirst ? void 0 : "g");
6758
6751
  }
6759
6752
 
6760
- // node_modules/ora/node_modules/strip-ansi/index.js
6753
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/node_modules/strip-ansi/index.js
6761
6754
  var regex = ansiRegex();
6762
6755
  function stripAnsi(string) {
6763
6756
  if (typeof string !== "string") {
@@ -6766,17 +6759,17 @@ function stripAnsi(string) {
6766
6759
  return string.replace(regex, "");
6767
6760
  }
6768
6761
 
6769
- // node_modules/ora/index.js
6762
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/index.js
6770
6763
  var import_wcwidth = __toESM(require_wcwidth(), 1);
6771
6764
 
6772
- // node_modules/is-interactive/index.js
6765
+ // node_modules/.pnpm/is-interactive@2.0.0/node_modules/is-interactive/index.js
6773
6766
  function isInteractive({ stream = process.stdout } = {}) {
6774
6767
  return Boolean(
6775
6768
  stream && stream.isTTY && process.env.TERM !== "dumb" && !("CI" in process.env)
6776
6769
  );
6777
6770
  }
6778
6771
 
6779
- // node_modules/stdin-discarder/index.js
6772
+ // node_modules/.pnpm/stdin-discarder@0.1.0/node_modules/stdin-discarder/index.js
6780
6773
  var import_bl = __toESM(require_bl(), 1);
6781
6774
  import process7 from "process";
6782
6775
  import readline from "readline";
@@ -6853,7 +6846,7 @@ _rl = new WeakMap();
6853
6846
  var stdinDiscarder = new StdinDiscarder();
6854
6847
  var stdin_discarder_default = stdinDiscarder;
6855
6848
 
6856
- // node_modules/ora/index.js
6849
+ // node_modules/.pnpm/ora@6.3.1/node_modules/ora/index.js
6857
6850
  var import_cli_spinners2 = __toESM(require_cli_spinners(), 1);
6858
6851
  var _linesToClear, _isDiscardingStdin, _lineCount, _frameIndex, _options, _spinner, _stream, _id, _initialInterval, _isEnabled, _isSilent, _indent, _text, _prefixText, _suffixText;
6859
6852
  var Ora = class {
@@ -7248,11 +7241,15 @@ async function getStyle() {
7248
7241
  spinner
7249
7242
  };
7250
7243
  }
7251
- function getLatestVersion(pkg, isZh6 = true) {
7244
+ async function getLatestVersion(pkg, isZh6 = true) {
7252
7245
  const data = [];
7253
7246
  for (const p of pkg.replace(/\s+/, " ").split(" ")) {
7254
7247
  const [pName, v] = p.split("$");
7255
- let { status, result } = jsShell(`npm view ${pName}`, "pipe");
7248
+ let { status, result } = await jsShell(`npm view ${pName}`, [
7249
+ "inherit",
7250
+ "pipe",
7251
+ "inherit"
7252
+ ]);
7256
7253
  if (status === 0) {
7257
7254
  if (result.startsWith("@"))
7258
7255
  result = result.slice(1);
@@ -7266,10 +7263,10 @@ function getLatestVersion(pkg, isZh6 = true) {
7266
7263
  }
7267
7264
 
7268
7265
  // src/help.ts
7269
- import { jsShell as jsShell2 } from "lazy-js-utils";
7266
+ import { jsShell as jsShell2 } from "lazy-js-utils/dist/node";
7270
7267
 
7271
7268
  // package.json
7272
- var version = "0.0.92";
7269
+ var version = "0.0.94";
7273
7270
 
7274
7271
  // src/help.ts
7275
7272
  var isZh2 = process.env.PI_Lang === "zh";
@@ -7291,11 +7288,15 @@ function help(argv) {
7291
7288
 
7292
7289
  // src/installDeps.ts
7293
7290
  var import_picocolors2 = __toESM(require_picocolors(), 1);
7294
- import { isInstallPkg, jsShell as jsShell3 } from "lazy-js-utils";
7291
+ import { isInstallPkg, jsShell as jsShell3 } from "lazy-js-utils/dist/node";
7295
7292
  async function installDeps() {
7296
- if (!isInstallPkg("gum")) {
7293
+ if (!await isInstallPkg("gum")) {
7297
7294
  console.log(import_picocolors2.default.cyan("\u6B63\u5728\u4E3A\u60A8\u5B89\u88C5\u5FC5\u8981\u7684\u4F9D\u8D56gum..."));
7298
- const { status } = await jsShell3("brew install gum", "pipe");
7295
+ const { status } = await jsShell3("brew install gum", [
7296
+ "inherit",
7297
+ "pipe",
7298
+ "inherit"
7299
+ ]);
7299
7300
  if (status === 0) {
7300
7301
  console.log(import_picocolors2.default.cyan("gum \u5B89\u88C5\u6210\u529F!"));
7301
7302
  } else {
@@ -7307,9 +7308,13 @@ async function installDeps() {
7307
7308
  process.exit(1);
7308
7309
  }
7309
7310
  }
7310
- if (!isInstallPkg("ni")) {
7311
+ if (!await isInstallPkg("ni")) {
7311
7312
  console.log(import_picocolors2.default.cyan("\u6B63\u5728\u4E3A\u60A8\u5B89\u88C5\u5FC5\u8981\u7684\u4F9D\u8D56ni..."));
7312
- const { status } = await jsShell3("npm i -g @antfu/ni", "pipe");
7313
+ const { status } = await jsShell3("npm i -g @antfu/ni", [
7314
+ "inherit",
7315
+ "pipe",
7316
+ "inherit"
7317
+ ]);
7313
7318
  if (status === 0) {
7314
7319
  console.log(import_picocolors2.default.cyan("ni \u5B89\u88C5\u6210\u529F!"));
7315
7320
  } else {
@@ -7327,12 +7332,12 @@ async function installDeps() {
7327
7332
  var import_picocolors4 = __toESM(require_picocolors(), 1);
7328
7333
  import process10 from "process";
7329
7334
  import { log } from "console";
7330
- import { getPkgTool as getPkgTool2, jsShell as jsShell5, useNodeWorker } from "lazy-js-utils";
7335
+ import { getPkgTool as getPkgTool2, jsShell as jsShell5, useNodeWorker } from "lazy-js-utils/dist/node";
7331
7336
 
7332
7337
  // src/detectNode.ts
7333
7338
  var import_picocolors3 = __toESM(require_picocolors(), 1);
7334
7339
  import process9 from "process";
7335
- import { getPkg as getPkg2, jsShell as jsShell4 } from "lazy-js-utils";
7340
+ import { getPkg as getPkg2, jsShell as jsShell4 } from "lazy-js-utils/dist/node";
7336
7341
  async function detectNode() {
7337
7342
  var _a;
7338
7343
  let pkg;
@@ -7352,7 +7357,7 @@ async function detectNode() {
7352
7357
  const { result, status } = await jsShell4(
7353
7358
  `echo "yes
7354
7359
  no" | gum filter --placeholder=" \u5F53\u524Dnode\u7248\u672C\u4E0D\u6EE1\u8DB3 ${pkg.engines.node}\uFF0C\u662F\u5426\u5207\u6362node\u7248\u672C"`,
7355
- "pipe"
7360
+ ["inherit", "pipe", "inherit"]
7356
7361
  );
7357
7362
  if (status === 0 && result === "yes") {
7358
7363
  await jsShell4(
@@ -7364,7 +7369,7 @@ no" | gum filter --placeholder=" \u5F53\u524Dnode\u7248\u672C\u4E0D\u6EE1\u8DB3
7364
7369
  fnm use \${registery% -*}
7365
7370
  fi
7366
7371
  `,
7367
- "pipe"
7372
+ ["inherit", "pipe", "inherit"]
7368
7373
  );
7369
7374
  }
7370
7375
  }
@@ -7381,13 +7386,13 @@ async function pi(params, pkg, executor = "ni") {
7381
7386
  const start = Date.now();
7382
7387
  let successMsg = "";
7383
7388
  if (isLatest) {
7384
- successMsg = getLatestVersion(pkg, isZh3);
7389
+ successMsg = await getLatestVersion(pkg, isZh3);
7385
7390
  } else {
7386
7391
  successMsg = pkg ? isZh3 ? `${pkg} \u5B89\u88C5\u6210\u529F! \u{1F60A}` : `Installed ${pkg} successfully! \u{1F60A}` : isZh3 ? "\u4F9D\u8D56\u66F4\u65B0\u6210\u529F! \u{1F60A}" : "Updated dependency successfully! \u{1F60A}";
7387
7392
  }
7388
7393
  const failMsg = pkg ? isZh3 ? `${params} \u5B89\u88C5\u5931\u8D25 \u{1F62D}` : `Failed to install ${params} \u{1F62D}` : isZh3 ? "\u4F9D\u8D56\u66F4\u65B0\u5931\u8D25 \u{1F62D}" : "Failed to update dependency \u{1F62D}";
7389
7394
  const newParams = isLatest ? params : await getParams(params);
7390
- let stdio = "pipe";
7395
+ let stdio = ["inherit", "pipe", "inherit"];
7391
7396
  let loading_status;
7392
7397
  const { PI_DEFAULT, PI_MaxSockets: sockets } = process10.env;
7393
7398
  const pkgTool = await getPkgTool2();
@@ -7418,7 +7423,7 @@ async function pi(params, pkg, executor = "ni") {
7418
7423
  isZh3 ? "\u6B63\u5728\u5C1D\u8BD5\u4F7F\u7528 npm \u518D\u6B21\u6267\u884C..." : "Trying to use npm to run again..."
7419
7424
  )
7420
7425
  );
7421
- const { status: newStatus, result: newResult } = jsShell5(
7426
+ const { status: newStatus, result: newResult } = await jsShell5(
7422
7427
  `npm install${newParams ? ` ${newParams}` : runSockets}`,
7423
7428
  {
7424
7429
  stdio
@@ -7455,7 +7460,7 @@ ${result}` : failMsg));
7455
7460
  }
7456
7461
 
7457
7462
  // src/pa.ts
7458
- import { jsShell as jsShell6 } from "lazy-js-utils";
7463
+ import { jsShell as jsShell6 } from "lazy-js-utils/dist/node";
7459
7464
  function pa() {
7460
7465
  return jsShell6("na");
7461
7466
  }
@@ -7473,7 +7478,7 @@ function pfind(params) {
7473
7478
 
7474
7479
  // src/pil.ts
7475
7480
  var import_picocolors5 = __toESM(require_picocolors(), 1);
7476
- import { getPkg as getPkg3, jsShell as jsShell7 } from "lazy-js-utils";
7481
+ import { getPkg as getPkg3, jsShell as jsShell7 } from "lazy-js-utils/dist/node";
7477
7482
  async function pil(params) {
7478
7483
  const { dependencies = {}, devDependencies = {} } = await getPkg3();
7479
7484
  if (!params) {
@@ -7483,11 +7488,13 @@ async function pil(params) {
7483
7488
  (key) => `${key}: ${devDependencies[key]}`
7484
7489
  )
7485
7490
  ];
7486
- const { result: choose, status } = jsShell7(
7491
+ const { result: choose, status } = await jsShell7(
7487
7492
  `echo ${deps.join(
7488
7493
  ","
7489
7494
  )} | sed "s/,/\\n/g" | gum filter --no-limit --placeholder=" \u{1F914}${process.env.PI_Lang === "zh" ? "\u8BF7\u9009\u62E9\u4E00\u4E2A\u9700\u8981\u83B7\u53D6\u6700\u65B0\u7248\u672C\u7684\u4F9D\u8D56" : "Please select a dependency that needs to obtain the latest version."}"`,
7490
- "pipe"
7495
+ {
7496
+ stdio: ["inherit", "pipe", "inherit"]
7497
+ }
7491
7498
  );
7492
7499
  if (status === 130) {
7493
7500
  console.log(import_picocolors5.default.dim("\u5DF2\u53D6\u6D88"));
@@ -7522,7 +7529,7 @@ async function pil(params) {
7522
7529
  }
7523
7530
 
7524
7531
  // src/pinit.ts
7525
- import { getPkgTool as getPkgTool3, jsShell as jsShell8 } from "lazy-js-utils";
7532
+ import { getPkgTool as getPkgTool3, jsShell as jsShell8 } from "lazy-js-utils/dist/node";
7526
7533
  async function pinit() {
7527
7534
  console.log("Initializing project...");
7528
7535
  switch (await getPkgTool3()) {
@@ -7541,7 +7548,7 @@ async function pinit() {
7541
7548
  }
7542
7549
 
7543
7550
  // src/pix.ts
7544
- import { getPkgTool as getPkgTool4, jsShell as jsShell9 } from "lazy-js-utils";
7551
+ import { getPkgTool as getPkgTool4, jsShell as jsShell9 } from "lazy-js-utils/dist/node";
7545
7552
  async function pix(params) {
7546
7553
  switch (await getPkgTool4()) {
7547
7554
  case "bun":
@@ -7558,14 +7565,14 @@ function prun(params) {
7558
7565
  }
7559
7566
 
7560
7567
  // src/pu.ts
7561
- import { jsShell as jsShell10 } from "lazy-js-utils";
7568
+ import { jsShell as jsShell10 } from "lazy-js-utils/dist/node";
7562
7569
  function pu() {
7563
7570
  return jsShell10("nu");
7564
7571
  }
7565
7572
 
7566
7573
  // src/pui.ts
7567
7574
  var import_picocolors6 = __toESM(require_picocolors(), 1);
7568
- import { getPkg as getPkg4, jsShell as jsShell11, useNodeWorker as useNodeWorker2 } from "lazy-js-utils";
7575
+ import { getPkg as getPkg4, jsShell as jsShell11, useNodeWorker as useNodeWorker2 } from "lazy-js-utils/dist/node";
7569
7576
  var isZh4 = process.env.PI_Lang === "zh";
7570
7577
  async function pui(params, pkg) {
7571
7578
  const text = `${isZh4 ? "\u6B63\u5728\u4E3A\u60A8\u5378\u8F7D" : "Uninstalling"} ${pkg} ...`;
@@ -7577,11 +7584,11 @@ async function pui(params, pkg) {
7577
7584
  (key) => `${key}: ${devDependencies[key]}`
7578
7585
  )
7579
7586
  ];
7580
- const { result: choose, status: status2 } = jsShell11(
7587
+ const { result: choose, status: status2 } = await jsShell11(
7581
7588
  `echo ${deps.join(
7582
7589
  ","
7583
7590
  )} | sed "s/,/\\n/g" | gum filter --placeholder=" \u{1F914}${process.env.PI_Lang === "zh" ? "\u8BF7\u9009\u62E9\u4E00\u4E2A\u9700\u8981\u5220\u9664\u4F9D\u8D56" : "Please select a dependency to get the latest version."}"`,
7584
- "pipe"
7591
+ ["inherit", "pipe", "inherit"]
7585
7592
  );
7586
7593
  if (status2 === 130) {
7587
7594
  console.log(import_picocolors6.default.dim("\u5DF2\u53D6\u6D88"));
@@ -7618,7 +7625,7 @@ ${result}` : failMsg));
7618
7625
  // src/pio.ts
7619
7626
  var import_picocolors7 = __toESM(require_picocolors(), 1);
7620
7627
  import process11 from "process";
7621
- import { useNodeWorker as useNodeWorker3 } from "lazy-js-utils";
7628
+ import { useNodeWorker as useNodeWorker3 } from "lazy-js-utils/dist/node";
7622
7629
  async function pio(params, pkg, executor = "ni") {
7623
7630
  const successMsg = pkg ? `Installed ${pkg} successfully! \u{1F60A}` : "Updated dependency successfully! \u{1F60A}";
7624
7631
  const failMsg = pkg ? `Failed to install ${pkg} \u{1F62D}` : "Failed to update dependency! \u{1F62D}";
@@ -7668,7 +7675,7 @@ async function setup() {
7668
7675
  help(argv);
7669
7676
  const params = spaceFormat(argv.join(" ")).trim();
7670
7677
  if (!hasPkg(rootPath)) {
7671
- if (isGo()) {
7678
+ if (await isGo()) {
7672
7679
  if (exec === "pi") {
7673
7680
  const loading_status = await loading(
7674
7681
  `${isZh5 ? "\u6B63\u5728\u4E3A\u60A8\u5B89\u88C5" : "Installing"} ${params} ...
@@ -7716,7 +7723,7 @@ async function setup() {
7716
7723
  }
7717
7724
  process12.exit();
7718
7725
  }
7719
- if (isRust()) {
7726
+ if (await isRust()) {
7720
7727
  if (exec === "pi") {
7721
7728
  const loading_status = await loading(
7722
7729
  `${isZh5 ? "\u6B63\u5728\u4E3A\u60A8\u5B89\u88C5" : "Installing"} ${params} ...