@atlashub/smartstack-cli 4.59.0 → 4.61.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist/index.js CHANGED
@@ -974,7 +974,7 @@ var require_command = __commonJS({
974
974
  var EventEmitter2 = require("events").EventEmitter;
975
975
  var childProcess2 = require("child_process");
976
976
  var path4 = require("path");
977
- var fs21 = require("fs");
977
+ var fs22 = require("fs");
978
978
  var process17 = require("process");
979
979
  var { Argument: Argument2, humanReadableArgName } = require_argument();
980
980
  var { CommanderError: CommanderError2 } = require_error();
@@ -1907,10 +1907,10 @@ Expecting one of '${allowedValues.join("', '")}'`);
1907
1907
  const sourceExt = [".js", ".ts", ".tsx", ".mjs", ".cjs"];
1908
1908
  function findFile(baseDir, baseName) {
1909
1909
  const localBin = path4.resolve(baseDir, baseName);
1910
- if (fs21.existsSync(localBin)) return localBin;
1910
+ if (fs22.existsSync(localBin)) return localBin;
1911
1911
  if (sourceExt.includes(path4.extname(baseName))) return void 0;
1912
1912
  const foundExt = sourceExt.find(
1913
- (ext2) => fs21.existsSync(`${localBin}${ext2}`)
1913
+ (ext2) => fs22.existsSync(`${localBin}${ext2}`)
1914
1914
  );
1915
1915
  if (foundExt) return `${localBin}${foundExt}`;
1916
1916
  return void 0;
@@ -1922,7 +1922,7 @@ Expecting one of '${allowedValues.join("', '")}'`);
1922
1922
  if (this._scriptPath) {
1923
1923
  let resolvedScriptPath;
1924
1924
  try {
1925
- resolvedScriptPath = fs21.realpathSync(this._scriptPath);
1925
+ resolvedScriptPath = fs22.realpathSync(this._scriptPath);
1926
1926
  } catch (err) {
1927
1927
  resolvedScriptPath = this._scriptPath;
1928
1928
  }
@@ -3089,54 +3089,54 @@ var require_polyfills = __commonJS({
3089
3089
  }
3090
3090
  var chdir;
3091
3091
  module2.exports = patch;
3092
- function patch(fs21) {
3092
+ function patch(fs22) {
3093
3093
  if (constants.hasOwnProperty("O_SYMLINK") && process.version.match(/^v0\.6\.[0-2]|^v0\.5\./)) {
3094
- patchLchmod(fs21);
3095
- }
3096
- if (!fs21.lutimes) {
3097
- patchLutimes(fs21);
3098
- }
3099
- fs21.chown = chownFix(fs21.chown);
3100
- fs21.fchown = chownFix(fs21.fchown);
3101
- fs21.lchown = chownFix(fs21.lchown);
3102
- fs21.chmod = chmodFix(fs21.chmod);
3103
- fs21.fchmod = chmodFix(fs21.fchmod);
3104
- fs21.lchmod = chmodFix(fs21.lchmod);
3105
- fs21.chownSync = chownFixSync(fs21.chownSync);
3106
- fs21.fchownSync = chownFixSync(fs21.fchownSync);
3107
- fs21.lchownSync = chownFixSync(fs21.lchownSync);
3108
- fs21.chmodSync = chmodFixSync(fs21.chmodSync);
3109
- fs21.fchmodSync = chmodFixSync(fs21.fchmodSync);
3110
- fs21.lchmodSync = chmodFixSync(fs21.lchmodSync);
3111
- fs21.stat = statFix(fs21.stat);
3112
- fs21.fstat = statFix(fs21.fstat);
3113
- fs21.lstat = statFix(fs21.lstat);
3114
- fs21.statSync = statFixSync(fs21.statSync);
3115
- fs21.fstatSync = statFixSync(fs21.fstatSync);
3116
- fs21.lstatSync = statFixSync(fs21.lstatSync);
3117
- if (fs21.chmod && !fs21.lchmod) {
3118
- fs21.lchmod = function(path4, mode, cb) {
3094
+ patchLchmod(fs22);
3095
+ }
3096
+ if (!fs22.lutimes) {
3097
+ patchLutimes(fs22);
3098
+ }
3099
+ fs22.chown = chownFix(fs22.chown);
3100
+ fs22.fchown = chownFix(fs22.fchown);
3101
+ fs22.lchown = chownFix(fs22.lchown);
3102
+ fs22.chmod = chmodFix(fs22.chmod);
3103
+ fs22.fchmod = chmodFix(fs22.fchmod);
3104
+ fs22.lchmod = chmodFix(fs22.lchmod);
3105
+ fs22.chownSync = chownFixSync(fs22.chownSync);
3106
+ fs22.fchownSync = chownFixSync(fs22.fchownSync);
3107
+ fs22.lchownSync = chownFixSync(fs22.lchownSync);
3108
+ fs22.chmodSync = chmodFixSync(fs22.chmodSync);
3109
+ fs22.fchmodSync = chmodFixSync(fs22.fchmodSync);
3110
+ fs22.lchmodSync = chmodFixSync(fs22.lchmodSync);
3111
+ fs22.stat = statFix(fs22.stat);
3112
+ fs22.fstat = statFix(fs22.fstat);
3113
+ fs22.lstat = statFix(fs22.lstat);
3114
+ fs22.statSync = statFixSync(fs22.statSync);
3115
+ fs22.fstatSync = statFixSync(fs22.fstatSync);
3116
+ fs22.lstatSync = statFixSync(fs22.lstatSync);
3117
+ if (fs22.chmod && !fs22.lchmod) {
3118
+ fs22.lchmod = function(path4, mode, cb) {
3119
3119
  if (cb) process.nextTick(cb);
3120
3120
  };
3121
- fs21.lchmodSync = function() {
3121
+ fs22.lchmodSync = function() {
3122
3122
  };
3123
3123
  }
3124
- if (fs21.chown && !fs21.lchown) {
3125
- fs21.lchown = function(path4, uid, gid, cb) {
3124
+ if (fs22.chown && !fs22.lchown) {
3125
+ fs22.lchown = function(path4, uid, gid, cb) {
3126
3126
  if (cb) process.nextTick(cb);
3127
3127
  };
3128
- fs21.lchownSync = function() {
3128
+ fs22.lchownSync = function() {
3129
3129
  };
3130
3130
  }
3131
3131
  if (platform4 === "win32") {
3132
- fs21.rename = typeof fs21.rename !== "function" ? fs21.rename : (function(fs$rename) {
3132
+ fs22.rename = typeof fs22.rename !== "function" ? fs22.rename : (function(fs$rename) {
3133
3133
  function rename(from3, to, cb) {
3134
3134
  var start = Date.now();
3135
3135
  var backoff = 0;
3136
3136
  fs$rename(from3, to, function CB(er) {
3137
3137
  if (er && (er.code === "EACCES" || er.code === "EPERM" || er.code === "EBUSY") && Date.now() - start < 6e4) {
3138
3138
  setTimeout(function() {
3139
- fs21.stat(to, function(stater, st) {
3139
+ fs22.stat(to, function(stater, st) {
3140
3140
  if (stater && stater.code === "ENOENT")
3141
3141
  fs$rename(from3, to, CB);
3142
3142
  else
@@ -3152,9 +3152,9 @@ var require_polyfills = __commonJS({
3152
3152
  }
3153
3153
  if (Object.setPrototypeOf) Object.setPrototypeOf(rename, fs$rename);
3154
3154
  return rename;
3155
- })(fs21.rename);
3155
+ })(fs22.rename);
3156
3156
  }
3157
- fs21.read = typeof fs21.read !== "function" ? fs21.read : (function(fs$read) {
3157
+ fs22.read = typeof fs22.read !== "function" ? fs22.read : (function(fs$read) {
3158
3158
  function read(fd, buffer, offset, length, position, callback_) {
3159
3159
  var callback;
3160
3160
  if (callback_ && typeof callback_ === "function") {
@@ -3162,22 +3162,22 @@ var require_polyfills = __commonJS({
3162
3162
  callback = function(er, _3, __) {
3163
3163
  if (er && er.code === "EAGAIN" && eagCounter < 10) {
3164
3164
  eagCounter++;
3165
- return fs$read.call(fs21, fd, buffer, offset, length, position, callback);
3165
+ return fs$read.call(fs22, fd, buffer, offset, length, position, callback);
3166
3166
  }
3167
3167
  callback_.apply(this, arguments);
3168
3168
  };
3169
3169
  }
3170
- return fs$read.call(fs21, fd, buffer, offset, length, position, callback);
3170
+ return fs$read.call(fs22, fd, buffer, offset, length, position, callback);
3171
3171
  }
3172
3172
  if (Object.setPrototypeOf) Object.setPrototypeOf(read, fs$read);
3173
3173
  return read;
3174
- })(fs21.read);
3175
- fs21.readSync = typeof fs21.readSync !== "function" ? fs21.readSync : /* @__PURE__ */ (function(fs$readSync) {
3174
+ })(fs22.read);
3175
+ fs22.readSync = typeof fs22.readSync !== "function" ? fs22.readSync : /* @__PURE__ */ (function(fs$readSync) {
3176
3176
  return function(fd, buffer, offset, length, position) {
3177
3177
  var eagCounter = 0;
3178
3178
  while (true) {
3179
3179
  try {
3180
- return fs$readSync.call(fs21, fd, buffer, offset, length, position);
3180
+ return fs$readSync.call(fs22, fd, buffer, offset, length, position);
3181
3181
  } catch (er) {
3182
3182
  if (er.code === "EAGAIN" && eagCounter < 10) {
3183
3183
  eagCounter++;
@@ -3187,10 +3187,10 @@ var require_polyfills = __commonJS({
3187
3187
  }
3188
3188
  }
3189
3189
  };
3190
- })(fs21.readSync);
3191
- function patchLchmod(fs22) {
3192
- fs22.lchmod = function(path4, mode, callback) {
3193
- fs22.open(
3190
+ })(fs22.readSync);
3191
+ function patchLchmod(fs23) {
3192
+ fs23.lchmod = function(path4, mode, callback) {
3193
+ fs23.open(
3194
3194
  path4,
3195
3195
  constants.O_WRONLY | constants.O_SYMLINK,
3196
3196
  mode,
@@ -3199,80 +3199,80 @@ var require_polyfills = __commonJS({
3199
3199
  if (callback) callback(err);
3200
3200
  return;
3201
3201
  }
3202
- fs22.fchmod(fd, mode, function(err2) {
3203
- fs22.close(fd, function(err22) {
3202
+ fs23.fchmod(fd, mode, function(err2) {
3203
+ fs23.close(fd, function(err22) {
3204
3204
  if (callback) callback(err2 || err22);
3205
3205
  });
3206
3206
  });
3207
3207
  }
3208
3208
  );
3209
3209
  };
3210
- fs22.lchmodSync = function(path4, mode) {
3211
- var fd = fs22.openSync(path4, constants.O_WRONLY | constants.O_SYMLINK, mode);
3210
+ fs23.lchmodSync = function(path4, mode) {
3211
+ var fd = fs23.openSync(path4, constants.O_WRONLY | constants.O_SYMLINK, mode);
3212
3212
  var threw = true;
3213
3213
  var ret;
3214
3214
  try {
3215
- ret = fs22.fchmodSync(fd, mode);
3215
+ ret = fs23.fchmodSync(fd, mode);
3216
3216
  threw = false;
3217
3217
  } finally {
3218
3218
  if (threw) {
3219
3219
  try {
3220
- fs22.closeSync(fd);
3220
+ fs23.closeSync(fd);
3221
3221
  } catch (er) {
3222
3222
  }
3223
3223
  } else {
3224
- fs22.closeSync(fd);
3224
+ fs23.closeSync(fd);
3225
3225
  }
3226
3226
  }
3227
3227
  return ret;
3228
3228
  };
3229
3229
  }
3230
- function patchLutimes(fs22) {
3231
- if (constants.hasOwnProperty("O_SYMLINK") && fs22.futimes) {
3232
- fs22.lutimes = function(path4, at, mt, cb) {
3233
- fs22.open(path4, constants.O_SYMLINK, function(er, fd) {
3230
+ function patchLutimes(fs23) {
3231
+ if (constants.hasOwnProperty("O_SYMLINK") && fs23.futimes) {
3232
+ fs23.lutimes = function(path4, at, mt, cb) {
3233
+ fs23.open(path4, constants.O_SYMLINK, function(er, fd) {
3234
3234
  if (er) {
3235
3235
  if (cb) cb(er);
3236
3236
  return;
3237
3237
  }
3238
- fs22.futimes(fd, at, mt, function(er2) {
3239
- fs22.close(fd, function(er22) {
3238
+ fs23.futimes(fd, at, mt, function(er2) {
3239
+ fs23.close(fd, function(er22) {
3240
3240
  if (cb) cb(er2 || er22);
3241
3241
  });
3242
3242
  });
3243
3243
  });
3244
3244
  };
3245
- fs22.lutimesSync = function(path4, at, mt) {
3246
- var fd = fs22.openSync(path4, constants.O_SYMLINK);
3245
+ fs23.lutimesSync = function(path4, at, mt) {
3246
+ var fd = fs23.openSync(path4, constants.O_SYMLINK);
3247
3247
  var ret;
3248
3248
  var threw = true;
3249
3249
  try {
3250
- ret = fs22.futimesSync(fd, at, mt);
3250
+ ret = fs23.futimesSync(fd, at, mt);
3251
3251
  threw = false;
3252
3252
  } finally {
3253
3253
  if (threw) {
3254
3254
  try {
3255
- fs22.closeSync(fd);
3255
+ fs23.closeSync(fd);
3256
3256
  } catch (er) {
3257
3257
  }
3258
3258
  } else {
3259
- fs22.closeSync(fd);
3259
+ fs23.closeSync(fd);
3260
3260
  }
3261
3261
  }
3262
3262
  return ret;
3263
3263
  };
3264
- } else if (fs22.futimes) {
3265
- fs22.lutimes = function(_a, _b, _c, cb) {
3264
+ } else if (fs23.futimes) {
3265
+ fs23.lutimes = function(_a, _b, _c, cb) {
3266
3266
  if (cb) process.nextTick(cb);
3267
3267
  };
3268
- fs22.lutimesSync = function() {
3268
+ fs23.lutimesSync = function() {
3269
3269
  };
3270
3270
  }
3271
3271
  }
3272
3272
  function chmodFix(orig) {
3273
3273
  if (!orig) return orig;
3274
3274
  return function(target, mode, cb) {
3275
- return orig.call(fs21, target, mode, function(er) {
3275
+ return orig.call(fs22, target, mode, function(er) {
3276
3276
  if (chownErOk(er)) er = null;
3277
3277
  if (cb) cb.apply(this, arguments);
3278
3278
  });
@@ -3282,7 +3282,7 @@ var require_polyfills = __commonJS({
3282
3282
  if (!orig) return orig;
3283
3283
  return function(target, mode) {
3284
3284
  try {
3285
- return orig.call(fs21, target, mode);
3285
+ return orig.call(fs22, target, mode);
3286
3286
  } catch (er) {
3287
3287
  if (!chownErOk(er)) throw er;
3288
3288
  }
@@ -3291,7 +3291,7 @@ var require_polyfills = __commonJS({
3291
3291
  function chownFix(orig) {
3292
3292
  if (!orig) return orig;
3293
3293
  return function(target, uid, gid, cb) {
3294
- return orig.call(fs21, target, uid, gid, function(er) {
3294
+ return orig.call(fs22, target, uid, gid, function(er) {
3295
3295
  if (chownErOk(er)) er = null;
3296
3296
  if (cb) cb.apply(this, arguments);
3297
3297
  });
@@ -3301,7 +3301,7 @@ var require_polyfills = __commonJS({
3301
3301
  if (!orig) return orig;
3302
3302
  return function(target, uid, gid) {
3303
3303
  try {
3304
- return orig.call(fs21, target, uid, gid);
3304
+ return orig.call(fs22, target, uid, gid);
3305
3305
  } catch (er) {
3306
3306
  if (!chownErOk(er)) throw er;
3307
3307
  }
@@ -3321,13 +3321,13 @@ var require_polyfills = __commonJS({
3321
3321
  }
3322
3322
  if (cb) cb.apply(this, arguments);
3323
3323
  }
3324
- return options ? orig.call(fs21, target, options, callback) : orig.call(fs21, target, callback);
3324
+ return options ? orig.call(fs22, target, options, callback) : orig.call(fs22, target, callback);
3325
3325
  };
3326
3326
  }
3327
3327
  function statFixSync(orig) {
3328
3328
  if (!orig) return orig;
3329
3329
  return function(target, options) {
3330
- var stats = options ? orig.call(fs21, target, options) : orig.call(fs21, target);
3330
+ var stats = options ? orig.call(fs22, target, options) : orig.call(fs22, target);
3331
3331
  if (stats) {
3332
3332
  if (stats.uid < 0) stats.uid += 4294967296;
3333
3333
  if (stats.gid < 0) stats.gid += 4294967296;
@@ -3357,7 +3357,7 @@ var require_legacy_streams = __commonJS({
3357
3357
  "use strict";
3358
3358
  var Stream2 = require("stream").Stream;
3359
3359
  module2.exports = legacy;
3360
- function legacy(fs21) {
3360
+ function legacy(fs22) {
3361
3361
  return {
3362
3362
  ReadStream,
3363
3363
  WriteStream
@@ -3400,7 +3400,7 @@ var require_legacy_streams = __commonJS({
3400
3400
  });
3401
3401
  return;
3402
3402
  }
3403
- fs21.open(this.path, this.flags, this.mode, function(err, fd) {
3403
+ fs22.open(this.path, this.flags, this.mode, function(err, fd) {
3404
3404
  if (err) {
3405
3405
  self2.emit("error", err);
3406
3406
  self2.readable = false;
@@ -3439,7 +3439,7 @@ var require_legacy_streams = __commonJS({
3439
3439
  this.busy = false;
3440
3440
  this._queue = [];
3441
3441
  if (this.fd === null) {
3442
- this._open = fs21.open;
3442
+ this._open = fs22.open;
3443
3443
  this._queue.push([this._open, this.path, this.flags, this.mode, void 0]);
3444
3444
  this.flush();
3445
3445
  }
@@ -3475,7 +3475,7 @@ var require_clone = __commonJS({
3475
3475
  var require_graceful_fs = __commonJS({
3476
3476
  "node_modules/graceful-fs/graceful-fs.js"(exports2, module2) {
3477
3477
  "use strict";
3478
- var fs21 = require("fs");
3478
+ var fs22 = require("fs");
3479
3479
  var polyfills = require_polyfills();
3480
3480
  var legacy = require_legacy_streams();
3481
3481
  var clone = require_clone();
@@ -3507,12 +3507,12 @@ var require_graceful_fs = __commonJS({
3507
3507
  m = "GFS4: " + m.split(/\n/).join("\nGFS4: ");
3508
3508
  console.error(m);
3509
3509
  };
3510
- if (!fs21[gracefulQueue]) {
3510
+ if (!fs22[gracefulQueue]) {
3511
3511
  queue = global[gracefulQueue] || [];
3512
- publishQueue(fs21, queue);
3513
- fs21.close = (function(fs$close) {
3512
+ publishQueue(fs22, queue);
3513
+ fs22.close = (function(fs$close) {
3514
3514
  function close(fd, cb) {
3515
- return fs$close.call(fs21, fd, function(err) {
3515
+ return fs$close.call(fs22, fd, function(err) {
3516
3516
  if (!err) {
3517
3517
  resetQueue();
3518
3518
  }
@@ -3524,40 +3524,40 @@ var require_graceful_fs = __commonJS({
3524
3524
  value: fs$close
3525
3525
  });
3526
3526
  return close;
3527
- })(fs21.close);
3528
- fs21.closeSync = (function(fs$closeSync) {
3527
+ })(fs22.close);
3528
+ fs22.closeSync = (function(fs$closeSync) {
3529
3529
  function closeSync(fd) {
3530
- fs$closeSync.apply(fs21, arguments);
3530
+ fs$closeSync.apply(fs22, arguments);
3531
3531
  resetQueue();
3532
3532
  }
3533
3533
  Object.defineProperty(closeSync, previousSymbol, {
3534
3534
  value: fs$closeSync
3535
3535
  });
3536
3536
  return closeSync;
3537
- })(fs21.closeSync);
3537
+ })(fs22.closeSync);
3538
3538
  if (/\bgfs4\b/i.test(process.env.NODE_DEBUG || "")) {
3539
3539
  process.on("exit", function() {
3540
- debug(fs21[gracefulQueue]);
3541
- require("assert").equal(fs21[gracefulQueue].length, 0);
3540
+ debug(fs22[gracefulQueue]);
3541
+ require("assert").equal(fs22[gracefulQueue].length, 0);
3542
3542
  });
3543
3543
  }
3544
3544
  }
3545
3545
  var queue;
3546
3546
  if (!global[gracefulQueue]) {
3547
- publishQueue(global, fs21[gracefulQueue]);
3548
- }
3549
- module2.exports = patch(clone(fs21));
3550
- if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs21.__patched) {
3551
- module2.exports = patch(fs21);
3552
- fs21.__patched = true;
3553
- }
3554
- function patch(fs22) {
3555
- polyfills(fs22);
3556
- fs22.gracefulify = patch;
3557
- fs22.createReadStream = createReadStream;
3558
- fs22.createWriteStream = createWriteStream;
3559
- var fs$readFile = fs22.readFile;
3560
- fs22.readFile = readFile;
3547
+ publishQueue(global, fs22[gracefulQueue]);
3548
+ }
3549
+ module2.exports = patch(clone(fs22));
3550
+ if (process.env.TEST_GRACEFUL_FS_GLOBAL_PATCH && !fs22.__patched) {
3551
+ module2.exports = patch(fs22);
3552
+ fs22.__patched = true;
3553
+ }
3554
+ function patch(fs23) {
3555
+ polyfills(fs23);
3556
+ fs23.gracefulify = patch;
3557
+ fs23.createReadStream = createReadStream;
3558
+ fs23.createWriteStream = createWriteStream;
3559
+ var fs$readFile = fs23.readFile;
3560
+ fs23.readFile = readFile;
3561
3561
  function readFile(path4, options, cb) {
3562
3562
  if (typeof options === "function")
3563
3563
  cb = options, options = null;
@@ -3573,8 +3573,8 @@ var require_graceful_fs = __commonJS({
3573
3573
  });
3574
3574
  }
3575
3575
  }
3576
- var fs$writeFile = fs22.writeFile;
3577
- fs22.writeFile = writeFile;
3576
+ var fs$writeFile = fs23.writeFile;
3577
+ fs23.writeFile = writeFile;
3578
3578
  function writeFile(path4, data, options, cb) {
3579
3579
  if (typeof options === "function")
3580
3580
  cb = options, options = null;
@@ -3590,9 +3590,9 @@ var require_graceful_fs = __commonJS({
3590
3590
  });
3591
3591
  }
3592
3592
  }
3593
- var fs$appendFile = fs22.appendFile;
3593
+ var fs$appendFile = fs23.appendFile;
3594
3594
  if (fs$appendFile)
3595
- fs22.appendFile = appendFile;
3595
+ fs23.appendFile = appendFile;
3596
3596
  function appendFile(path4, data, options, cb) {
3597
3597
  if (typeof options === "function")
3598
3598
  cb = options, options = null;
@@ -3608,9 +3608,9 @@ var require_graceful_fs = __commonJS({
3608
3608
  });
3609
3609
  }
3610
3610
  }
3611
- var fs$copyFile = fs22.copyFile;
3611
+ var fs$copyFile = fs23.copyFile;
3612
3612
  if (fs$copyFile)
3613
- fs22.copyFile = copyFile;
3613
+ fs23.copyFile = copyFile;
3614
3614
  function copyFile(src, dest, flags, cb) {
3615
3615
  if (typeof flags === "function") {
3616
3616
  cb = flags;
@@ -3628,8 +3628,8 @@ var require_graceful_fs = __commonJS({
3628
3628
  });
3629
3629
  }
3630
3630
  }
3631
- var fs$readdir = fs22.readdir;
3632
- fs22.readdir = readdir2;
3631
+ var fs$readdir = fs23.readdir;
3632
+ fs23.readdir = readdir2;
3633
3633
  var noReaddirOptionVersions = /^v[0-5]\./;
3634
3634
  function readdir2(path4, options, cb) {
3635
3635
  if (typeof options === "function")
@@ -3670,21 +3670,21 @@ var require_graceful_fs = __commonJS({
3670
3670
  }
3671
3671
  }
3672
3672
  if (process.version.substr(0, 4) === "v0.8") {
3673
- var legStreams = legacy(fs22);
3673
+ var legStreams = legacy(fs23);
3674
3674
  ReadStream = legStreams.ReadStream;
3675
3675
  WriteStream = legStreams.WriteStream;
3676
3676
  }
3677
- var fs$ReadStream = fs22.ReadStream;
3677
+ var fs$ReadStream = fs23.ReadStream;
3678
3678
  if (fs$ReadStream) {
3679
3679
  ReadStream.prototype = Object.create(fs$ReadStream.prototype);
3680
3680
  ReadStream.prototype.open = ReadStream$open;
3681
3681
  }
3682
- var fs$WriteStream = fs22.WriteStream;
3682
+ var fs$WriteStream = fs23.WriteStream;
3683
3683
  if (fs$WriteStream) {
3684
3684
  WriteStream.prototype = Object.create(fs$WriteStream.prototype);
3685
3685
  WriteStream.prototype.open = WriteStream$open;
3686
3686
  }
3687
- Object.defineProperty(fs22, "ReadStream", {
3687
+ Object.defineProperty(fs23, "ReadStream", {
3688
3688
  get: function() {
3689
3689
  return ReadStream;
3690
3690
  },
@@ -3694,7 +3694,7 @@ var require_graceful_fs = __commonJS({
3694
3694
  enumerable: true,
3695
3695
  configurable: true
3696
3696
  });
3697
- Object.defineProperty(fs22, "WriteStream", {
3697
+ Object.defineProperty(fs23, "WriteStream", {
3698
3698
  get: function() {
3699
3699
  return WriteStream;
3700
3700
  },
@@ -3705,7 +3705,7 @@ var require_graceful_fs = __commonJS({
3705
3705
  configurable: true
3706
3706
  });
3707
3707
  var FileReadStream = ReadStream;
3708
- Object.defineProperty(fs22, "FileReadStream", {
3708
+ Object.defineProperty(fs23, "FileReadStream", {
3709
3709
  get: function() {
3710
3710
  return FileReadStream;
3711
3711
  },
@@ -3716,7 +3716,7 @@ var require_graceful_fs = __commonJS({
3716
3716
  configurable: true
3717
3717
  });
3718
3718
  var FileWriteStream = WriteStream;
3719
- Object.defineProperty(fs22, "FileWriteStream", {
3719
+ Object.defineProperty(fs23, "FileWriteStream", {
3720
3720
  get: function() {
3721
3721
  return FileWriteStream;
3722
3722
  },
@@ -3765,13 +3765,13 @@ var require_graceful_fs = __commonJS({
3765
3765
  });
3766
3766
  }
3767
3767
  function createReadStream(path4, options) {
3768
- return new fs22.ReadStream(path4, options);
3768
+ return new fs23.ReadStream(path4, options);
3769
3769
  }
3770
3770
  function createWriteStream(path4, options) {
3771
- return new fs22.WriteStream(path4, options);
3771
+ return new fs23.WriteStream(path4, options);
3772
3772
  }
3773
- var fs$open = fs22.open;
3774
- fs22.open = open2;
3773
+ var fs$open = fs23.open;
3774
+ fs23.open = open2;
3775
3775
  function open2(path4, flags, mode, cb) {
3776
3776
  if (typeof mode === "function")
3777
3777
  cb = mode, mode = null;
@@ -3787,20 +3787,20 @@ var require_graceful_fs = __commonJS({
3787
3787
  });
3788
3788
  }
3789
3789
  }
3790
- return fs22;
3790
+ return fs23;
3791
3791
  }
3792
3792
  function enqueue(elem) {
3793
3793
  debug("ENQUEUE", elem[0].name, elem[1]);
3794
- fs21[gracefulQueue].push(elem);
3794
+ fs22[gracefulQueue].push(elem);
3795
3795
  retry();
3796
3796
  }
3797
3797
  var retryTimer;
3798
3798
  function resetQueue() {
3799
3799
  var now = Date.now();
3800
- for (var i = 0; i < fs21[gracefulQueue].length; ++i) {
3801
- if (fs21[gracefulQueue][i].length > 2) {
3802
- fs21[gracefulQueue][i][3] = now;
3803
- fs21[gracefulQueue][i][4] = now;
3800
+ for (var i = 0; i < fs22[gracefulQueue].length; ++i) {
3801
+ if (fs22[gracefulQueue][i].length > 2) {
3802
+ fs22[gracefulQueue][i][3] = now;
3803
+ fs22[gracefulQueue][i][4] = now;
3804
3804
  }
3805
3805
  }
3806
3806
  retry();
@@ -3808,9 +3808,9 @@ var require_graceful_fs = __commonJS({
3808
3808
  function retry() {
3809
3809
  clearTimeout(retryTimer);
3810
3810
  retryTimer = void 0;
3811
- if (fs21[gracefulQueue].length === 0)
3811
+ if (fs22[gracefulQueue].length === 0)
3812
3812
  return;
3813
- var elem = fs21[gracefulQueue].shift();
3813
+ var elem = fs22[gracefulQueue].shift();
3814
3814
  var fn = elem[0];
3815
3815
  var args = elem[1];
3816
3816
  var err = elem[2];
@@ -3832,7 +3832,7 @@ var require_graceful_fs = __commonJS({
3832
3832
  debug("RETRY", fn.name, args);
3833
3833
  fn.apply(null, args.concat([startTime]));
3834
3834
  } else {
3835
- fs21[gracefulQueue].push(elem);
3835
+ fs22[gracefulQueue].push(elem);
3836
3836
  }
3837
3837
  }
3838
3838
  if (retryTimer === void 0) {
@@ -3847,7 +3847,7 @@ var require_fs = __commonJS({
3847
3847
  "node_modules/fs-extra/lib/fs/index.js"(exports2) {
3848
3848
  "use strict";
3849
3849
  var u = require_universalify().fromCallback;
3850
- var fs21 = require_graceful_fs();
3850
+ var fs22 = require_graceful_fs();
3851
3851
  var api = [
3852
3852
  "access",
3853
3853
  "appendFile",
@@ -3888,26 +3888,26 @@ var require_fs = __commonJS({
3888
3888
  "utimes",
3889
3889
  "writeFile"
3890
3890
  ].filter((key) => {
3891
- return typeof fs21[key] === "function";
3891
+ return typeof fs22[key] === "function";
3892
3892
  });
3893
- Object.assign(exports2, fs21);
3893
+ Object.assign(exports2, fs22);
3894
3894
  api.forEach((method) => {
3895
- exports2[method] = u(fs21[method]);
3895
+ exports2[method] = u(fs22[method]);
3896
3896
  });
3897
3897
  exports2.exists = function(filename, callback) {
3898
3898
  if (typeof callback === "function") {
3899
- return fs21.exists(filename, callback);
3899
+ return fs22.exists(filename, callback);
3900
3900
  }
3901
3901
  return new Promise((resolve2) => {
3902
- return fs21.exists(filename, resolve2);
3902
+ return fs22.exists(filename, resolve2);
3903
3903
  });
3904
3904
  };
3905
3905
  exports2.read = function(fd, buffer, offset, length, position, callback) {
3906
3906
  if (typeof callback === "function") {
3907
- return fs21.read(fd, buffer, offset, length, position, callback);
3907
+ return fs22.read(fd, buffer, offset, length, position, callback);
3908
3908
  }
3909
3909
  return new Promise((resolve2, reject) => {
3910
- fs21.read(fd, buffer, offset, length, position, (err, bytesRead, buffer2) => {
3910
+ fs22.read(fd, buffer, offset, length, position, (err, bytesRead, buffer2) => {
3911
3911
  if (err) return reject(err);
3912
3912
  resolve2({ bytesRead, buffer: buffer2 });
3913
3913
  });
@@ -3915,10 +3915,10 @@ var require_fs = __commonJS({
3915
3915
  };
3916
3916
  exports2.write = function(fd, buffer, ...args) {
3917
3917
  if (typeof args[args.length - 1] === "function") {
3918
- return fs21.write(fd, buffer, ...args);
3918
+ return fs22.write(fd, buffer, ...args);
3919
3919
  }
3920
3920
  return new Promise((resolve2, reject) => {
3921
- fs21.write(fd, buffer, ...args, (err, bytesWritten, buffer2) => {
3921
+ fs22.write(fd, buffer, ...args, (err, bytesWritten, buffer2) => {
3922
3922
  if (err) return reject(err);
3923
3923
  resolve2({ bytesWritten, buffer: buffer2 });
3924
3924
  });
@@ -3926,10 +3926,10 @@ var require_fs = __commonJS({
3926
3926
  };
3927
3927
  exports2.readv = function(fd, buffers, ...args) {
3928
3928
  if (typeof args[args.length - 1] === "function") {
3929
- return fs21.readv(fd, buffers, ...args);
3929
+ return fs22.readv(fd, buffers, ...args);
3930
3930
  }
3931
3931
  return new Promise((resolve2, reject) => {
3932
- fs21.readv(fd, buffers, ...args, (err, bytesRead, buffers2) => {
3932
+ fs22.readv(fd, buffers, ...args, (err, bytesRead, buffers2) => {
3933
3933
  if (err) return reject(err);
3934
3934
  resolve2({ bytesRead, buffers: buffers2 });
3935
3935
  });
@@ -3937,17 +3937,17 @@ var require_fs = __commonJS({
3937
3937
  };
3938
3938
  exports2.writev = function(fd, buffers, ...args) {
3939
3939
  if (typeof args[args.length - 1] === "function") {
3940
- return fs21.writev(fd, buffers, ...args);
3940
+ return fs22.writev(fd, buffers, ...args);
3941
3941
  }
3942
3942
  return new Promise((resolve2, reject) => {
3943
- fs21.writev(fd, buffers, ...args, (err, bytesWritten, buffers2) => {
3943
+ fs22.writev(fd, buffers, ...args, (err, bytesWritten, buffers2) => {
3944
3944
  if (err) return reject(err);
3945
3945
  resolve2({ bytesWritten, buffers: buffers2 });
3946
3946
  });
3947
3947
  });
3948
3948
  };
3949
- if (typeof fs21.realpath.native === "function") {
3950
- exports2.realpath.native = u(fs21.realpath.native);
3949
+ if (typeof fs22.realpath.native === "function") {
3950
+ exports2.realpath.native = u(fs22.realpath.native);
3951
3951
  } else {
3952
3952
  process.emitWarning(
3953
3953
  "fs.realpath.native is not a function. Is fs being monkey-patched?",
@@ -3980,7 +3980,7 @@ var require_utils = __commonJS({
3980
3980
  var require_make_dir = __commonJS({
3981
3981
  "node_modules/fs-extra/lib/mkdirs/make-dir.js"(exports2, module2) {
3982
3982
  "use strict";
3983
- var fs21 = require_fs();
3983
+ var fs22 = require_fs();
3984
3984
  var { checkPath } = require_utils();
3985
3985
  var getMode = (options) => {
3986
3986
  const defaults2 = { mode: 511 };
@@ -3989,14 +3989,14 @@ var require_make_dir = __commonJS({
3989
3989
  };
3990
3990
  module2.exports.makeDir = async (dir, options) => {
3991
3991
  checkPath(dir);
3992
- return fs21.mkdir(dir, {
3992
+ return fs22.mkdir(dir, {
3993
3993
  mode: getMode(options),
3994
3994
  recursive: true
3995
3995
  });
3996
3996
  };
3997
3997
  module2.exports.makeDirSync = (dir, options) => {
3998
3998
  checkPath(dir);
3999
- return fs21.mkdirSync(dir, {
3999
+ return fs22.mkdirSync(dir, {
4000
4000
  mode: getMode(options),
4001
4001
  recursive: true
4002
4002
  });
@@ -4028,13 +4028,13 @@ var require_path_exists = __commonJS({
4028
4028
  "node_modules/fs-extra/lib/path-exists/index.js"(exports2, module2) {
4029
4029
  "use strict";
4030
4030
  var u = require_universalify().fromPromise;
4031
- var fs21 = require_fs();
4031
+ var fs22 = require_fs();
4032
4032
  function pathExists(path4) {
4033
- return fs21.access(path4).then(() => true).catch(() => false);
4033
+ return fs22.access(path4).then(() => true).catch(() => false);
4034
4034
  }
4035
4035
  module2.exports = {
4036
4036
  pathExists: u(pathExists),
4037
- pathExistsSync: fs21.existsSync
4037
+ pathExistsSync: fs22.existsSync
4038
4038
  };
4039
4039
  }
4040
4040
  });
@@ -4043,16 +4043,16 @@ var require_path_exists = __commonJS({
4043
4043
  var require_utimes = __commonJS({
4044
4044
  "node_modules/fs-extra/lib/util/utimes.js"(exports2, module2) {
4045
4045
  "use strict";
4046
- var fs21 = require_fs();
4046
+ var fs22 = require_fs();
4047
4047
  var u = require_universalify().fromPromise;
4048
4048
  async function utimesMillis(path4, atime, mtime) {
4049
- const fd = await fs21.open(path4, "r+");
4049
+ const fd = await fs22.open(path4, "r+");
4050
4050
  let closeErr = null;
4051
4051
  try {
4052
- await fs21.futimes(fd, atime, mtime);
4052
+ await fs22.futimes(fd, atime, mtime);
4053
4053
  } finally {
4054
4054
  try {
4055
- await fs21.close(fd);
4055
+ await fs22.close(fd);
4056
4056
  } catch (e) {
4057
4057
  closeErr = e;
4058
4058
  }
@@ -4062,9 +4062,9 @@ var require_utimes = __commonJS({
4062
4062
  }
4063
4063
  }
4064
4064
  function utimesMillisSync(path4, atime, mtime) {
4065
- const fd = fs21.openSync(path4, "r+");
4066
- fs21.futimesSync(fd, atime, mtime);
4067
- return fs21.closeSync(fd);
4065
+ const fd = fs22.openSync(path4, "r+");
4066
+ fs22.futimesSync(fd, atime, mtime);
4067
+ return fs22.closeSync(fd);
4068
4068
  }
4069
4069
  module2.exports = {
4070
4070
  utimesMillis: u(utimesMillis),
@@ -4077,11 +4077,11 @@ var require_utimes = __commonJS({
4077
4077
  var require_stat = __commonJS({
4078
4078
  "node_modules/fs-extra/lib/util/stat.js"(exports2, module2) {
4079
4079
  "use strict";
4080
- var fs21 = require_fs();
4080
+ var fs22 = require_fs();
4081
4081
  var path4 = require("path");
4082
4082
  var u = require_universalify().fromPromise;
4083
4083
  function getStats(src, dest, opts) {
4084
- const statFunc = opts.dereference ? (file) => fs21.stat(file, { bigint: true }) : (file) => fs21.lstat(file, { bigint: true });
4084
+ const statFunc = opts.dereference ? (file) => fs22.stat(file, { bigint: true }) : (file) => fs22.lstat(file, { bigint: true });
4085
4085
  return Promise.all([
4086
4086
  statFunc(src),
4087
4087
  statFunc(dest).catch((err) => {
@@ -4092,7 +4092,7 @@ var require_stat = __commonJS({
4092
4092
  }
4093
4093
  function getStatsSync(src, dest, opts) {
4094
4094
  let destStat;
4095
- const statFunc = opts.dereference ? (file) => fs21.statSync(file, { bigint: true }) : (file) => fs21.lstatSync(file, { bigint: true });
4095
+ const statFunc = opts.dereference ? (file) => fs22.statSync(file, { bigint: true }) : (file) => fs22.lstatSync(file, { bigint: true });
4096
4096
  const srcStat = statFunc(src);
4097
4097
  try {
4098
4098
  destStat = statFunc(dest);
@@ -4154,7 +4154,7 @@ var require_stat = __commonJS({
4154
4154
  if (destParent === srcParent || destParent === path4.parse(destParent).root) return;
4155
4155
  let destStat;
4156
4156
  try {
4157
- destStat = await fs21.stat(destParent, { bigint: true });
4157
+ destStat = await fs22.stat(destParent, { bigint: true });
4158
4158
  } catch (err) {
4159
4159
  if (err.code === "ENOENT") return;
4160
4160
  throw err;
@@ -4170,7 +4170,7 @@ var require_stat = __commonJS({
4170
4170
  if (destParent === srcParent || destParent === path4.parse(destParent).root) return;
4171
4171
  let destStat;
4172
4172
  try {
4173
- destStat = fs21.statSync(destParent, { bigint: true });
4173
+ destStat = fs22.statSync(destParent, { bigint: true });
4174
4174
  } catch (err) {
4175
4175
  if (err.code === "ENOENT") return;
4176
4176
  throw err;
@@ -4237,7 +4237,7 @@ var require_async = __commonJS({
4237
4237
  var require_copy = __commonJS({
4238
4238
  "node_modules/fs-extra/lib/copy/copy.js"(exports2, module2) {
4239
4239
  "use strict";
4240
- var fs21 = require_fs();
4240
+ var fs22 = require_fs();
4241
4241
  var path4 = require("path");
4242
4242
  var { mkdirs } = require_mkdirs();
4243
4243
  var { pathExists } = require_path_exists();
@@ -4273,7 +4273,7 @@ var require_copy = __commonJS({
4273
4273
  return opts.filter(src, dest);
4274
4274
  }
4275
4275
  async function getStatsAndPerformCopy(destStat, src, dest, opts) {
4276
- const statFn = opts.dereference ? fs21.stat : fs21.lstat;
4276
+ const statFn = opts.dereference ? fs22.stat : fs22.lstat;
4277
4277
  const srcStat = await statFn(src);
4278
4278
  if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts);
4279
4279
  if (srcStat.isFile() || srcStat.isCharacterDevice() || srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts);
@@ -4285,7 +4285,7 @@ var require_copy = __commonJS({
4285
4285
  async function onFile(srcStat, destStat, src, dest, opts) {
4286
4286
  if (!destStat) return copyFile(srcStat, src, dest, opts);
4287
4287
  if (opts.overwrite) {
4288
- await fs21.unlink(dest);
4288
+ await fs22.unlink(dest);
4289
4289
  return copyFile(srcStat, src, dest, opts);
4290
4290
  }
4291
4291
  if (opts.errorOnExist) {
@@ -4293,27 +4293,27 @@ var require_copy = __commonJS({
4293
4293
  }
4294
4294
  }
4295
4295
  async function copyFile(srcStat, src, dest, opts) {
4296
- await fs21.copyFile(src, dest);
4296
+ await fs22.copyFile(src, dest);
4297
4297
  if (opts.preserveTimestamps) {
4298
4298
  if (fileIsNotWritable(srcStat.mode)) {
4299
4299
  await makeFileWritable(dest, srcStat.mode);
4300
4300
  }
4301
- const updatedSrcStat = await fs21.stat(src);
4301
+ const updatedSrcStat = await fs22.stat(src);
4302
4302
  await utimesMillis(dest, updatedSrcStat.atime, updatedSrcStat.mtime);
4303
4303
  }
4304
- return fs21.chmod(dest, srcStat.mode);
4304
+ return fs22.chmod(dest, srcStat.mode);
4305
4305
  }
4306
4306
  function fileIsNotWritable(srcMode) {
4307
4307
  return (srcMode & 128) === 0;
4308
4308
  }
4309
4309
  function makeFileWritable(dest, srcMode) {
4310
- return fs21.chmod(dest, srcMode | 128);
4310
+ return fs22.chmod(dest, srcMode | 128);
4311
4311
  }
4312
4312
  async function onDir(srcStat, destStat, src, dest, opts) {
4313
4313
  if (!destStat) {
4314
- await fs21.mkdir(dest);
4314
+ await fs22.mkdir(dest);
4315
4315
  }
4316
- await asyncIteratorConcurrentProcess(await fs21.opendir(src), async (item) => {
4316
+ await asyncIteratorConcurrentProcess(await fs22.opendir(src), async (item) => {
4317
4317
  const srcItem = path4.join(src, item.name);
4318
4318
  const destItem = path4.join(dest, item.name);
4319
4319
  const include = await runFilter(srcItem, destItem, opts);
@@ -4323,22 +4323,22 @@ var require_copy = __commonJS({
4323
4323
  }
4324
4324
  });
4325
4325
  if (!destStat) {
4326
- await fs21.chmod(dest, srcStat.mode);
4326
+ await fs22.chmod(dest, srcStat.mode);
4327
4327
  }
4328
4328
  }
4329
4329
  async function onLink(destStat, src, dest, opts) {
4330
- let resolvedSrc = await fs21.readlink(src);
4330
+ let resolvedSrc = await fs22.readlink(src);
4331
4331
  if (opts.dereference) {
4332
4332
  resolvedSrc = path4.resolve(process.cwd(), resolvedSrc);
4333
4333
  }
4334
4334
  if (!destStat) {
4335
- return fs21.symlink(resolvedSrc, dest);
4335
+ return fs22.symlink(resolvedSrc, dest);
4336
4336
  }
4337
4337
  let resolvedDest = null;
4338
4338
  try {
4339
- resolvedDest = await fs21.readlink(dest);
4339
+ resolvedDest = await fs22.readlink(dest);
4340
4340
  } catch (e) {
4341
- if (e.code === "EINVAL" || e.code === "UNKNOWN") return fs21.symlink(resolvedSrc, dest);
4341
+ if (e.code === "EINVAL" || e.code === "UNKNOWN") return fs22.symlink(resolvedSrc, dest);
4342
4342
  throw e;
4343
4343
  }
4344
4344
  if (opts.dereference) {
@@ -4352,8 +4352,8 @@ var require_copy = __commonJS({
4352
4352
  throw new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`);
4353
4353
  }
4354
4354
  }
4355
- await fs21.unlink(dest);
4356
- return fs21.symlink(resolvedSrc, dest);
4355
+ await fs22.unlink(dest);
4356
+ return fs22.symlink(resolvedSrc, dest);
4357
4357
  }
4358
4358
  module2.exports = copy;
4359
4359
  }
@@ -4363,7 +4363,7 @@ var require_copy = __commonJS({
4363
4363
  var require_copy_sync = __commonJS({
4364
4364
  "node_modules/fs-extra/lib/copy/copy-sync.js"(exports2, module2) {
4365
4365
  "use strict";
4366
- var fs21 = require_graceful_fs();
4366
+ var fs22 = require_graceful_fs();
4367
4367
  var path4 = require("path");
4368
4368
  var mkdirsSync = require_mkdirs().mkdirsSync;
4369
4369
  var utimesMillisSync = require_utimes().utimesMillisSync;
@@ -4386,11 +4386,11 @@ var require_copy_sync = __commonJS({
4386
4386
  stat.checkParentPathsSync(src, srcStat, dest, "copy");
4387
4387
  if (opts.filter && !opts.filter(src, dest)) return;
4388
4388
  const destParent = path4.dirname(dest);
4389
- if (!fs21.existsSync(destParent)) mkdirsSync(destParent);
4389
+ if (!fs22.existsSync(destParent)) mkdirsSync(destParent);
4390
4390
  return getStats(destStat, src, dest, opts);
4391
4391
  }
4392
4392
  function getStats(destStat, src, dest, opts) {
4393
- const statSync = opts.dereference ? fs21.statSync : fs21.lstatSync;
4393
+ const statSync = opts.dereference ? fs22.statSync : fs22.lstatSync;
4394
4394
  const srcStat = statSync(src);
4395
4395
  if (srcStat.isDirectory()) return onDir(srcStat, destStat, src, dest, opts);
4396
4396
  else if (srcStat.isFile() || srcStat.isCharacterDevice() || srcStat.isBlockDevice()) return onFile(srcStat, destStat, src, dest, opts);
@@ -4405,14 +4405,14 @@ var require_copy_sync = __commonJS({
4405
4405
  }
4406
4406
  function mayCopyFile(srcStat, src, dest, opts) {
4407
4407
  if (opts.overwrite) {
4408
- fs21.unlinkSync(dest);
4408
+ fs22.unlinkSync(dest);
4409
4409
  return copyFile(srcStat, src, dest, opts);
4410
4410
  } else if (opts.errorOnExist) {
4411
4411
  throw new Error(`'${dest}' already exists`);
4412
4412
  }
4413
4413
  }
4414
4414
  function copyFile(srcStat, src, dest, opts) {
4415
- fs21.copyFileSync(src, dest);
4415
+ fs22.copyFileSync(src, dest);
4416
4416
  if (opts.preserveTimestamps) handleTimestamps(srcStat.mode, src, dest);
4417
4417
  return setDestMode(dest, srcStat.mode);
4418
4418
  }
@@ -4427,10 +4427,10 @@ var require_copy_sync = __commonJS({
4427
4427
  return setDestMode(dest, srcMode | 128);
4428
4428
  }
4429
4429
  function setDestMode(dest, srcMode) {
4430
- return fs21.chmodSync(dest, srcMode);
4430
+ return fs22.chmodSync(dest, srcMode);
4431
4431
  }
4432
4432
  function setDestTimestamps(src, dest) {
4433
- const updatedSrcStat = fs21.statSync(src);
4433
+ const updatedSrcStat = fs22.statSync(src);
4434
4434
  return utimesMillisSync(dest, updatedSrcStat.atime, updatedSrcStat.mtime);
4435
4435
  }
4436
4436
  function onDir(srcStat, destStat, src, dest, opts) {
@@ -4438,12 +4438,12 @@ var require_copy_sync = __commonJS({
4438
4438
  return copyDir(src, dest, opts);
4439
4439
  }
4440
4440
  function mkDirAndCopy(srcMode, src, dest, opts) {
4441
- fs21.mkdirSync(dest);
4441
+ fs22.mkdirSync(dest);
4442
4442
  copyDir(src, dest, opts);
4443
4443
  return setDestMode(dest, srcMode);
4444
4444
  }
4445
4445
  function copyDir(src, dest, opts) {
4446
- const dir = fs21.opendirSync(src);
4446
+ const dir = fs22.opendirSync(src);
4447
4447
  try {
4448
4448
  let dirent;
4449
4449
  while ((dirent = dir.readSync()) !== null) {
@@ -4461,18 +4461,18 @@ var require_copy_sync = __commonJS({
4461
4461
  return getStats(destStat, srcItem, destItem, opts);
4462
4462
  }
4463
4463
  function onLink(destStat, src, dest, opts) {
4464
- let resolvedSrc = fs21.readlinkSync(src);
4464
+ let resolvedSrc = fs22.readlinkSync(src);
4465
4465
  if (opts.dereference) {
4466
4466
  resolvedSrc = path4.resolve(process.cwd(), resolvedSrc);
4467
4467
  }
4468
4468
  if (!destStat) {
4469
- return fs21.symlinkSync(resolvedSrc, dest);
4469
+ return fs22.symlinkSync(resolvedSrc, dest);
4470
4470
  } else {
4471
4471
  let resolvedDest;
4472
4472
  try {
4473
- resolvedDest = fs21.readlinkSync(dest);
4473
+ resolvedDest = fs22.readlinkSync(dest);
4474
4474
  } catch (err) {
4475
- if (err.code === "EINVAL" || err.code === "UNKNOWN") return fs21.symlinkSync(resolvedSrc, dest);
4475
+ if (err.code === "EINVAL" || err.code === "UNKNOWN") return fs22.symlinkSync(resolvedSrc, dest);
4476
4476
  throw err;
4477
4477
  }
4478
4478
  if (opts.dereference) {
@@ -4490,8 +4490,8 @@ var require_copy_sync = __commonJS({
4490
4490
  }
4491
4491
  }
4492
4492
  function copyLink(resolvedSrc, dest) {
4493
- fs21.unlinkSync(dest);
4494
- return fs21.symlinkSync(resolvedSrc, dest);
4493
+ fs22.unlinkSync(dest);
4494
+ return fs22.symlinkSync(resolvedSrc, dest);
4495
4495
  }
4496
4496
  module2.exports = copySync;
4497
4497
  }
@@ -4513,13 +4513,13 @@ var require_copy2 = __commonJS({
4513
4513
  var require_remove = __commonJS({
4514
4514
  "node_modules/fs-extra/lib/remove/index.js"(exports2, module2) {
4515
4515
  "use strict";
4516
- var fs21 = require_graceful_fs();
4516
+ var fs22 = require_graceful_fs();
4517
4517
  var u = require_universalify().fromCallback;
4518
4518
  function remove(path4, callback) {
4519
- fs21.rm(path4, { recursive: true, force: true }, callback);
4519
+ fs22.rm(path4, { recursive: true, force: true }, callback);
4520
4520
  }
4521
4521
  function removeSync(path4) {
4522
- fs21.rmSync(path4, { recursive: true, force: true });
4522
+ fs22.rmSync(path4, { recursive: true, force: true });
4523
4523
  }
4524
4524
  module2.exports = {
4525
4525
  remove: u(remove),
@@ -4533,14 +4533,14 @@ var require_empty = __commonJS({
4533
4533
  "node_modules/fs-extra/lib/empty/index.js"(exports2, module2) {
4534
4534
  "use strict";
4535
4535
  var u = require_universalify().fromPromise;
4536
- var fs21 = require_fs();
4536
+ var fs22 = require_fs();
4537
4537
  var path4 = require("path");
4538
4538
  var mkdir = require_mkdirs();
4539
4539
  var remove = require_remove();
4540
4540
  var emptyDir = u(async function emptyDir2(dir) {
4541
4541
  let items;
4542
4542
  try {
4543
- items = await fs21.readdir(dir);
4543
+ items = await fs22.readdir(dir);
4544
4544
  } catch {
4545
4545
  return mkdir.mkdirs(dir);
4546
4546
  }
@@ -4549,7 +4549,7 @@ var require_empty = __commonJS({
4549
4549
  function emptyDirSync(dir) {
4550
4550
  let items;
4551
4551
  try {
4552
- items = fs21.readdirSync(dir);
4552
+ items = fs22.readdirSync(dir);
4553
4553
  } catch {
4554
4554
  return mkdir.mkdirsSync(dir);
4555
4555
  }
@@ -4573,51 +4573,51 @@ var require_file = __commonJS({
4573
4573
  "use strict";
4574
4574
  var u = require_universalify().fromPromise;
4575
4575
  var path4 = require("path");
4576
- var fs21 = require_fs();
4576
+ var fs22 = require_fs();
4577
4577
  var mkdir = require_mkdirs();
4578
4578
  async function createFile(file) {
4579
4579
  let stats;
4580
4580
  try {
4581
- stats = await fs21.stat(file);
4581
+ stats = await fs22.stat(file);
4582
4582
  } catch {
4583
4583
  }
4584
4584
  if (stats && stats.isFile()) return;
4585
4585
  const dir = path4.dirname(file);
4586
4586
  let dirStats = null;
4587
4587
  try {
4588
- dirStats = await fs21.stat(dir);
4588
+ dirStats = await fs22.stat(dir);
4589
4589
  } catch (err) {
4590
4590
  if (err.code === "ENOENT") {
4591
4591
  await mkdir.mkdirs(dir);
4592
- await fs21.writeFile(file, "");
4592
+ await fs22.writeFile(file, "");
4593
4593
  return;
4594
4594
  } else {
4595
4595
  throw err;
4596
4596
  }
4597
4597
  }
4598
4598
  if (dirStats.isDirectory()) {
4599
- await fs21.writeFile(file, "");
4599
+ await fs22.writeFile(file, "");
4600
4600
  } else {
4601
- await fs21.readdir(dir);
4601
+ await fs22.readdir(dir);
4602
4602
  }
4603
4603
  }
4604
4604
  function createFileSync(file) {
4605
4605
  let stats;
4606
4606
  try {
4607
- stats = fs21.statSync(file);
4607
+ stats = fs22.statSync(file);
4608
4608
  } catch {
4609
4609
  }
4610
4610
  if (stats && stats.isFile()) return;
4611
4611
  const dir = path4.dirname(file);
4612
4612
  try {
4613
- if (!fs21.statSync(dir).isDirectory()) {
4614
- fs21.readdirSync(dir);
4613
+ if (!fs22.statSync(dir).isDirectory()) {
4614
+ fs22.readdirSync(dir);
4615
4615
  }
4616
4616
  } catch (err) {
4617
4617
  if (err && err.code === "ENOENT") mkdir.mkdirsSync(dir);
4618
4618
  else throw err;
4619
4619
  }
4620
- fs21.writeFileSync(file, "");
4620
+ fs22.writeFileSync(file, "");
4621
4621
  }
4622
4622
  module2.exports = {
4623
4623
  createFile: u(createFile),
@@ -4632,19 +4632,19 @@ var require_link = __commonJS({
4632
4632
  "use strict";
4633
4633
  var u = require_universalify().fromPromise;
4634
4634
  var path4 = require("path");
4635
- var fs21 = require_fs();
4635
+ var fs22 = require_fs();
4636
4636
  var mkdir = require_mkdirs();
4637
4637
  var { pathExists } = require_path_exists();
4638
4638
  var { areIdentical } = require_stat();
4639
4639
  async function createLink(srcpath, dstpath) {
4640
4640
  let dstStat;
4641
4641
  try {
4642
- dstStat = await fs21.lstat(dstpath);
4642
+ dstStat = await fs22.lstat(dstpath);
4643
4643
  } catch {
4644
4644
  }
4645
4645
  let srcStat;
4646
4646
  try {
4647
- srcStat = await fs21.lstat(srcpath);
4647
+ srcStat = await fs22.lstat(srcpath);
4648
4648
  } catch (err) {
4649
4649
  err.message = err.message.replace("lstat", "ensureLink");
4650
4650
  throw err;
@@ -4655,26 +4655,26 @@ var require_link = __commonJS({
4655
4655
  if (!dirExists) {
4656
4656
  await mkdir.mkdirs(dir);
4657
4657
  }
4658
- await fs21.link(srcpath, dstpath);
4658
+ await fs22.link(srcpath, dstpath);
4659
4659
  }
4660
4660
  function createLinkSync(srcpath, dstpath) {
4661
4661
  let dstStat;
4662
4662
  try {
4663
- dstStat = fs21.lstatSync(dstpath);
4663
+ dstStat = fs22.lstatSync(dstpath);
4664
4664
  } catch {
4665
4665
  }
4666
4666
  try {
4667
- const srcStat = fs21.lstatSync(srcpath);
4667
+ const srcStat = fs22.lstatSync(srcpath);
4668
4668
  if (dstStat && areIdentical(srcStat, dstStat)) return;
4669
4669
  } catch (err) {
4670
4670
  err.message = err.message.replace("lstat", "ensureLink");
4671
4671
  throw err;
4672
4672
  }
4673
4673
  const dir = path4.dirname(dstpath);
4674
- const dirExists = fs21.existsSync(dir);
4675
- if (dirExists) return fs21.linkSync(srcpath, dstpath);
4674
+ const dirExists = fs22.existsSync(dir);
4675
+ if (dirExists) return fs22.linkSync(srcpath, dstpath);
4676
4676
  mkdir.mkdirsSync(dir);
4677
- return fs21.linkSync(srcpath, dstpath);
4677
+ return fs22.linkSync(srcpath, dstpath);
4678
4678
  }
4679
4679
  module2.exports = {
4680
4680
  createLink: u(createLink),
@@ -4688,13 +4688,13 @@ var require_symlink_paths = __commonJS({
4688
4688
  "node_modules/fs-extra/lib/ensure/symlink-paths.js"(exports2, module2) {
4689
4689
  "use strict";
4690
4690
  var path4 = require("path");
4691
- var fs21 = require_fs();
4691
+ var fs22 = require_fs();
4692
4692
  var { pathExists } = require_path_exists();
4693
4693
  var u = require_universalify().fromPromise;
4694
4694
  async function symlinkPaths(srcpath, dstpath) {
4695
4695
  if (path4.isAbsolute(srcpath)) {
4696
4696
  try {
4697
- await fs21.lstat(srcpath);
4697
+ await fs22.lstat(srcpath);
4698
4698
  } catch (err) {
4699
4699
  err.message = err.message.replace("lstat", "ensureSymlink");
4700
4700
  throw err;
@@ -4714,7 +4714,7 @@ var require_symlink_paths = __commonJS({
4714
4714
  };
4715
4715
  }
4716
4716
  try {
4717
- await fs21.lstat(srcpath);
4717
+ await fs22.lstat(srcpath);
4718
4718
  } catch (err) {
4719
4719
  err.message = err.message.replace("lstat", "ensureSymlink");
4720
4720
  throw err;
@@ -4726,7 +4726,7 @@ var require_symlink_paths = __commonJS({
4726
4726
  }
4727
4727
  function symlinkPathsSync(srcpath, dstpath) {
4728
4728
  if (path4.isAbsolute(srcpath)) {
4729
- const exists2 = fs21.existsSync(srcpath);
4729
+ const exists2 = fs22.existsSync(srcpath);
4730
4730
  if (!exists2) throw new Error("absolute srcpath does not exist");
4731
4731
  return {
4732
4732
  toCwd: srcpath,
@@ -4735,14 +4735,14 @@ var require_symlink_paths = __commonJS({
4735
4735
  }
4736
4736
  const dstdir = path4.dirname(dstpath);
4737
4737
  const relativeToDst = path4.join(dstdir, srcpath);
4738
- const exists = fs21.existsSync(relativeToDst);
4738
+ const exists = fs22.existsSync(relativeToDst);
4739
4739
  if (exists) {
4740
4740
  return {
4741
4741
  toCwd: relativeToDst,
4742
4742
  toDst: srcpath
4743
4743
  };
4744
4744
  }
4745
- const srcExists = fs21.existsSync(srcpath);
4745
+ const srcExists = fs22.existsSync(srcpath);
4746
4746
  if (!srcExists) throw new Error("relative srcpath does not exist");
4747
4747
  return {
4748
4748
  toCwd: srcpath,
@@ -4760,13 +4760,13 @@ var require_symlink_paths = __commonJS({
4760
4760
  var require_symlink_type = __commonJS({
4761
4761
  "node_modules/fs-extra/lib/ensure/symlink-type.js"(exports2, module2) {
4762
4762
  "use strict";
4763
- var fs21 = require_fs();
4763
+ var fs22 = require_fs();
4764
4764
  var u = require_universalify().fromPromise;
4765
4765
  async function symlinkType(srcpath, type) {
4766
4766
  if (type) return type;
4767
4767
  let stats;
4768
4768
  try {
4769
- stats = await fs21.lstat(srcpath);
4769
+ stats = await fs22.lstat(srcpath);
4770
4770
  } catch {
4771
4771
  return "file";
4772
4772
  }
@@ -4776,7 +4776,7 @@ var require_symlink_type = __commonJS({
4776
4776
  if (type) return type;
4777
4777
  let stats;
4778
4778
  try {
4779
- stats = fs21.lstatSync(srcpath);
4779
+ stats = fs22.lstatSync(srcpath);
4780
4780
  } catch {
4781
4781
  return "file";
4782
4782
  }
@@ -4795,7 +4795,7 @@ var require_symlink = __commonJS({
4795
4795
  "use strict";
4796
4796
  var u = require_universalify().fromPromise;
4797
4797
  var path4 = require("path");
4798
- var fs21 = require_fs();
4798
+ var fs22 = require_fs();
4799
4799
  var { mkdirs, mkdirsSync } = require_mkdirs();
4800
4800
  var { symlinkPaths, symlinkPathsSync } = require_symlink_paths();
4801
4801
  var { symlinkType, symlinkTypeSync } = require_symlink_type();
@@ -4804,13 +4804,13 @@ var require_symlink = __commonJS({
4804
4804
  async function createSymlink(srcpath, dstpath, type) {
4805
4805
  let stats;
4806
4806
  try {
4807
- stats = await fs21.lstat(dstpath);
4807
+ stats = await fs22.lstat(dstpath);
4808
4808
  } catch {
4809
4809
  }
4810
4810
  if (stats && stats.isSymbolicLink()) {
4811
4811
  const [srcStat, dstStat] = await Promise.all([
4812
- fs21.stat(srcpath),
4813
- fs21.stat(dstpath)
4812
+ fs22.stat(srcpath),
4813
+ fs22.stat(dstpath)
4814
4814
  ]);
4815
4815
  if (areIdentical(srcStat, dstStat)) return;
4816
4816
  }
@@ -4821,27 +4821,27 @@ var require_symlink = __commonJS({
4821
4821
  if (!await pathExists(dir)) {
4822
4822
  await mkdirs(dir);
4823
4823
  }
4824
- return fs21.symlink(srcpath, dstpath, toType);
4824
+ return fs22.symlink(srcpath, dstpath, toType);
4825
4825
  }
4826
4826
  function createSymlinkSync(srcpath, dstpath, type) {
4827
4827
  let stats;
4828
4828
  try {
4829
- stats = fs21.lstatSync(dstpath);
4829
+ stats = fs22.lstatSync(dstpath);
4830
4830
  } catch {
4831
4831
  }
4832
4832
  if (stats && stats.isSymbolicLink()) {
4833
- const srcStat = fs21.statSync(srcpath);
4834
- const dstStat = fs21.statSync(dstpath);
4833
+ const srcStat = fs22.statSync(srcpath);
4834
+ const dstStat = fs22.statSync(dstpath);
4835
4835
  if (areIdentical(srcStat, dstStat)) return;
4836
4836
  }
4837
4837
  const relative2 = symlinkPathsSync(srcpath, dstpath);
4838
4838
  srcpath = relative2.toDst;
4839
4839
  type = symlinkTypeSync(relative2.toCwd, type);
4840
4840
  const dir = path4.dirname(dstpath);
4841
- const exists = fs21.existsSync(dir);
4842
- if (exists) return fs21.symlinkSync(srcpath, dstpath, type);
4841
+ const exists = fs22.existsSync(dir);
4842
+ if (exists) return fs22.symlinkSync(srcpath, dstpath, type);
4843
4843
  mkdirsSync(dir);
4844
- return fs21.symlinkSync(srcpath, dstpath, type);
4844
+ return fs22.symlinkSync(srcpath, dstpath, type);
4845
4845
  }
4846
4846
  module2.exports = {
4847
4847
  createSymlink: u(createSymlink),
@@ -4910,9 +4910,9 @@ var require_jsonfile = __commonJS({
4910
4910
  if (typeof options === "string") {
4911
4911
  options = { encoding: options };
4912
4912
  }
4913
- const fs21 = options.fs || _fs;
4913
+ const fs22 = options.fs || _fs;
4914
4914
  const shouldThrow = "throws" in options ? options.throws : true;
4915
- let data = await universalify.fromCallback(fs21.readFile)(file, options);
4915
+ let data = await universalify.fromCallback(fs22.readFile)(file, options);
4916
4916
  data = stripBom(data);
4917
4917
  let obj;
4918
4918
  try {
@@ -4932,10 +4932,10 @@ var require_jsonfile = __commonJS({
4932
4932
  if (typeof options === "string") {
4933
4933
  options = { encoding: options };
4934
4934
  }
4935
- const fs21 = options.fs || _fs;
4935
+ const fs22 = options.fs || _fs;
4936
4936
  const shouldThrow = "throws" in options ? options.throws : true;
4937
4937
  try {
4938
- let content = fs21.readFileSync(file, options);
4938
+ let content = fs22.readFileSync(file, options);
4939
4939
  content = stripBom(content);
4940
4940
  return JSON.parse(content, options.reviver);
4941
4941
  } catch (err) {
@@ -4948,15 +4948,15 @@ var require_jsonfile = __commonJS({
4948
4948
  }
4949
4949
  }
4950
4950
  async function _writeFile(file, obj, options = {}) {
4951
- const fs21 = options.fs || _fs;
4951
+ const fs22 = options.fs || _fs;
4952
4952
  const str = stringify2(obj, options);
4953
- await universalify.fromCallback(fs21.writeFile)(file, str, options);
4953
+ await universalify.fromCallback(fs22.writeFile)(file, str, options);
4954
4954
  }
4955
4955
  var writeFile = universalify.fromPromise(_writeFile);
4956
4956
  function writeFileSync4(file, obj, options = {}) {
4957
- const fs21 = options.fs || _fs;
4957
+ const fs22 = options.fs || _fs;
4958
4958
  const str = stringify2(obj, options);
4959
- return fs21.writeFileSync(file, str, options);
4959
+ return fs22.writeFileSync(file, str, options);
4960
4960
  }
4961
4961
  module2.exports = {
4962
4962
  readFile,
@@ -4987,7 +4987,7 @@ var require_output_file = __commonJS({
4987
4987
  "node_modules/fs-extra/lib/output-file/index.js"(exports2, module2) {
4988
4988
  "use strict";
4989
4989
  var u = require_universalify().fromPromise;
4990
- var fs21 = require_fs();
4990
+ var fs22 = require_fs();
4991
4991
  var path4 = require("path");
4992
4992
  var mkdir = require_mkdirs();
4993
4993
  var pathExists = require_path_exists().pathExists;
@@ -4996,14 +4996,14 @@ var require_output_file = __commonJS({
4996
4996
  if (!await pathExists(dir)) {
4997
4997
  await mkdir.mkdirs(dir);
4998
4998
  }
4999
- return fs21.writeFile(file, data, encoding);
4999
+ return fs22.writeFile(file, data, encoding);
5000
5000
  }
5001
5001
  function outputFileSync(file, ...args) {
5002
5002
  const dir = path4.dirname(file);
5003
- if (!fs21.existsSync(dir)) {
5003
+ if (!fs22.existsSync(dir)) {
5004
5004
  mkdir.mkdirsSync(dir);
5005
5005
  }
5006
- fs21.writeFileSync(file, ...args);
5006
+ fs22.writeFileSync(file, ...args);
5007
5007
  }
5008
5008
  module2.exports = {
5009
5009
  outputFile: u(outputFile),
@@ -5062,7 +5062,7 @@ var require_json = __commonJS({
5062
5062
  var require_move = __commonJS({
5063
5063
  "node_modules/fs-extra/lib/move/move.js"(exports2, module2) {
5064
5064
  "use strict";
5065
- var fs21 = require_fs();
5065
+ var fs22 = require_fs();
5066
5066
  var path4 = require("path");
5067
5067
  var { copy } = require_copy2();
5068
5068
  var { remove } = require_remove();
@@ -5089,7 +5089,7 @@ var require_move = __commonJS({
5089
5089
  }
5090
5090
  }
5091
5091
  try {
5092
- await fs21.rename(src, dest);
5092
+ await fs22.rename(src, dest);
5093
5093
  } catch (err) {
5094
5094
  if (err.code !== "EXDEV") {
5095
5095
  throw err;
@@ -5114,7 +5114,7 @@ var require_move = __commonJS({
5114
5114
  var require_move_sync = __commonJS({
5115
5115
  "node_modules/fs-extra/lib/move/move-sync.js"(exports2, module2) {
5116
5116
  "use strict";
5117
- var fs21 = require_graceful_fs();
5117
+ var fs22 = require_graceful_fs();
5118
5118
  var path4 = require("path");
5119
5119
  var copySync = require_copy2().copySync;
5120
5120
  var removeSync = require_remove().removeSync;
@@ -5139,12 +5139,12 @@ var require_move_sync = __commonJS({
5139
5139
  removeSync(dest);
5140
5140
  return rename(src, dest, overwrite);
5141
5141
  }
5142
- if (fs21.existsSync(dest)) throw new Error("dest already exists.");
5142
+ if (fs22.existsSync(dest)) throw new Error("dest already exists.");
5143
5143
  return rename(src, dest, overwrite);
5144
5144
  }
5145
5145
  function rename(src, dest, overwrite) {
5146
5146
  try {
5147
- fs21.renameSync(src, dest);
5147
+ fs22.renameSync(src, dest);
5148
5148
  } catch (err) {
5149
5149
  if (err.code !== "EXDEV") throw err;
5150
5150
  return moveAcrossDevice(src, dest, overwrite);
@@ -19200,7 +19200,7 @@ var require_buffer_list = __commonJS({
19200
19200
  }
19201
19201
  }, {
19202
19202
  key: "join",
19203
- value: function join18(s) {
19203
+ value: function join19(s) {
19204
19204
  if (this.length === 0) return "";
19205
19205
  var p = this.head;
19206
19206
  var ret = "" + p.data;
@@ -28077,10 +28077,10 @@ var require_lib2 = __commonJS({
28077
28077
  exports2.analyse = analyse;
28078
28078
  var detectFile = (filepath, opts = {}) => new Promise((resolve2, reject) => {
28079
28079
  let fd;
28080
- const fs21 = (0, node_1.default)();
28080
+ const fs22 = (0, node_1.default)();
28081
28081
  const handler = (err, buffer) => {
28082
28082
  if (fd) {
28083
- fs21.closeSync(fd);
28083
+ fs22.closeSync(fd);
28084
28084
  }
28085
28085
  if (err) {
28086
28086
  reject(err);
@@ -28092,9 +28092,9 @@ var require_lib2 = __commonJS({
28092
28092
  };
28093
28093
  const sampleSize = (opts === null || opts === void 0 ? void 0 : opts.sampleSize) || 0;
28094
28094
  if (sampleSize > 0) {
28095
- fd = fs21.openSync(filepath, "r");
28095
+ fd = fs22.openSync(filepath, "r");
28096
28096
  let sample = Buffer.allocUnsafe(sampleSize);
28097
- fs21.read(fd, sample, 0, sampleSize, opts.offset, (err, bytesRead) => {
28097
+ fs22.read(fd, sample, 0, sampleSize, opts.offset, (err, bytesRead) => {
28098
28098
  if (err) {
28099
28099
  handler(err, null);
28100
28100
  } else {
@@ -28106,22 +28106,22 @@ var require_lib2 = __commonJS({
28106
28106
  });
28107
28107
  return;
28108
28108
  }
28109
- fs21.readFile(filepath, handler);
28109
+ fs22.readFile(filepath, handler);
28110
28110
  });
28111
28111
  exports2.detectFile = detectFile;
28112
28112
  var detectFileSync = (filepath, opts = {}) => {
28113
- const fs21 = (0, node_1.default)();
28113
+ const fs22 = (0, node_1.default)();
28114
28114
  if (opts && opts.sampleSize) {
28115
- const fd = fs21.openSync(filepath, "r");
28115
+ const fd = fs22.openSync(filepath, "r");
28116
28116
  let sample = Buffer.allocUnsafe(opts.sampleSize);
28117
- const bytesRead = fs21.readSync(fd, sample, 0, opts.sampleSize, opts.offset);
28117
+ const bytesRead = fs22.readSync(fd, sample, 0, opts.sampleSize, opts.offset);
28118
28118
  if (bytesRead < opts.sampleSize) {
28119
28119
  sample = sample.subarray(0, bytesRead);
28120
28120
  }
28121
- fs21.closeSync(fd);
28121
+ fs22.closeSync(fd);
28122
28122
  return (0, exports2.detect)(sample);
28123
28123
  }
28124
- return (0, exports2.detect)(fs21.readFileSync(filepath));
28124
+ return (0, exports2.detect)(fs22.readFileSync(filepath));
28125
28125
  };
28126
28126
  exports2.detectFileSync = detectFileSync;
28127
28127
  exports2.default = {
@@ -52395,7 +52395,7 @@ var require_msal_node = __commonJS({
52395
52395
  var crypto5 = require("crypto");
52396
52396
  var msalCommon = require_lib6();
52397
52397
  var jwt2 = require_jsonwebtoken();
52398
- var fs21 = require("fs");
52398
+ var fs22 = require("fs");
52399
52399
  var path4 = require("path");
52400
52400
  var Serializer = class {
52401
52401
  /**
@@ -62094,7 +62094,7 @@ Headers: ${JSON.stringify(headers)}`
62094
62094
  if (!identityEndpoint || !imdsEndpoint) {
62095
62095
  const fileDetectionPath = AZURE_ARC_FILE_DETECTION[process.platform];
62096
62096
  try {
62097
- fs21.accessSync(fileDetectionPath, fs21.constants.F_OK | fs21.constants.R_OK);
62097
+ fs22.accessSync(fileDetectionPath, fs22.constants.F_OK | fs22.constants.R_OK);
62098
62098
  identityEndpoint = DEFAULT_AZURE_ARC_IDENTITY_ENDPOINT;
62099
62099
  imdsEndpoint = HIMDS_EXECUTABLE_HELPER_STRING;
62100
62100
  } catch (err) {
@@ -62206,7 +62206,7 @@ Headers: ${JSON.stringify(headers)}`
62206
62206
  }
62207
62207
  let secretFileSize;
62208
62208
  try {
62209
- secretFileSize = await fs21.statSync(secretFilePath).size;
62209
+ secretFileSize = await fs22.statSync(secretFilePath).size;
62210
62210
  } catch (e) {
62211
62211
  throw createManagedIdentityError(unableToReadSecretFile);
62212
62212
  }
@@ -62215,7 +62215,7 @@ Headers: ${JSON.stringify(headers)}`
62215
62215
  }
62216
62216
  let secret;
62217
62217
  try {
62218
- secret = fs21.readFileSync(secretFilePath, EncodingTypes.UTF8);
62218
+ secret = fs22.readFileSync(secretFilePath, EncodingTypes.UTF8);
62219
62219
  } catch (e) {
62220
62220
  throw createManagedIdentityError(unableToReadSecretFile);
62221
62221
  }
@@ -117204,7 +117204,7 @@ ${projectName}/
117204
117204
  \u2502 \u2514\u2500\u2500 ${projectName}.Api/ # Web API controllers and configuration
117205
117205
  \u251C\u2500\u2500 web/
117206
117206
  \u2502 \u2514\u2500\u2500 ${projectName.toLowerCase()}-web/ # React frontend (Vite + TypeScript + Tailwind)
117207
- \u251C\u2500\u2500 docker-images/ # Dockerfiles (backend + frontend)
117207
+ \u251C\u2500\u2500 docker-images/ # Dockerfiles + docker-compose (backend + frontend)
117208
117208
  \u2514\u2500\u2500 tests/ # Unit and integration tests
117209
117209
  \`\`\`
117210
117210
 
@@ -117740,6 +117740,19 @@ async function createDockerFiles(config, state, dryRun) {
117740
117740
  logSafeWriteResult(dockerignoreRelPath, dockerignoreResult);
117741
117741
  recordFile(state, "docker", dockerignoreRelPath, dockerignoreResult.hash);
117742
117742
  }
117743
+ const dockerCompose = await loadTemplate("docker-compose.yml.template", projectName);
117744
+ const composeRelPath = "docker-images/docker-compose.yml";
117745
+ if (dryRun) {
117746
+ logger.info(`Would create ${composeRelPath}`);
117747
+ } else {
117748
+ const composeResult = await safeWriteFile(
117749
+ (0, import_path7.join)(projectDir, composeRelPath),
117750
+ dockerCompose,
117751
+ findKnownHash(state, "docker", composeRelPath)
117752
+ );
117753
+ logSafeWriteResult(composeRelPath, composeResult);
117754
+ recordFile(state, "docker", composeRelPath, composeResult.hash);
117755
+ }
117743
117756
  logger.success("Docker configuration created");
117744
117757
  }
117745
117758
  function checkGitIdentity(cwd) {
@@ -118185,6 +118198,7 @@ var initCommand = new Command("init").description("Initialize a new SmartStack p
118185
118198
  ` 3. Start dev server: ${source_default.cyan("npm run dev")}`,
118186
118199
  "",
118187
118200
  source_default.yellow("Docker:"),
118201
+ ` Build & run: ${source_default.cyan("docker compose -f docker-images/docker-compose.yml up --build")}`,
118188
118202
  ` Build backend: ${source_default.cyan(`docker build -t smartstack-${projectNameLower}-backend:latest -f docker-images/Dockerfile.backend .`)}`,
118189
118203
  ` Build frontend: ${source_default.cyan(`docker build -t smartstack-${projectNameLower}-frontend:latest -f docker-images/Dockerfile.frontend .`)}`,
118190
118204
  "",
@@ -123277,8 +123291,8 @@ var PathScurryBase = class {
123277
123291
  *
123278
123292
  * @internal
123279
123293
  */
123280
- constructor(cwd = process.cwd(), pathImpl, sep2, { nocase, childrenCacheSize = 16 * 1024, fs: fs21 = defaultFS } = {}) {
123281
- this.#fs = fsFromOption(fs21);
123294
+ constructor(cwd = process.cwd(), pathImpl, sep2, { nocase, childrenCacheSize = 16 * 1024, fs: fs22 = defaultFS } = {}) {
123295
+ this.#fs = fsFromOption(fs22);
123282
123296
  if (cwd instanceof URL || cwd.startsWith("file://")) {
123283
123297
  cwd = (0, import_node_url.fileURLToPath)(cwd);
123284
123298
  }
@@ -123836,8 +123850,8 @@ var PathScurryWin32 = class extends PathScurryBase {
123836
123850
  /**
123837
123851
  * @internal
123838
123852
  */
123839
- newRoot(fs21) {
123840
- return new PathWin32(this.rootPath, IFDIR, void 0, this.roots, this.nocase, this.childrenCache(), { fs: fs21 });
123853
+ newRoot(fs22) {
123854
+ return new PathWin32(this.rootPath, IFDIR, void 0, this.roots, this.nocase, this.childrenCache(), { fs: fs22 });
123841
123855
  }
123842
123856
  /**
123843
123857
  * Return true if the provided path string is an absolute path
@@ -123865,8 +123879,8 @@ var PathScurryPosix = class extends PathScurryBase {
123865
123879
  /**
123866
123880
  * @internal
123867
123881
  */
123868
- newRoot(fs21) {
123869
- return new PathPosix(this.rootPath, IFDIR, void 0, this.roots, this.nocase, this.childrenCache(), { fs: fs21 });
123882
+ newRoot(fs22) {
123883
+ return new PathPosix(this.rootPath, IFDIR, void 0, this.roots, this.nocase, this.childrenCache(), { fs: fs22 });
123870
123884
  }
123871
123885
  /**
123872
123886
  * Return true if the provided path string is an absolute path
@@ -125378,6 +125392,11 @@ async function syncDockerFiles(projectDir, baseNamespace, dryRun) {
125378
125392
  template: "dockerignore.template",
125379
125393
  dest: (0, import_path8.join)(projectDir, ".dockerignore"),
125380
125394
  label: ".dockerignore"
125395
+ },
125396
+ {
125397
+ template: "docker-compose.yml.template",
125398
+ dest: (0, import_path8.join)(projectDir, "docker-images", "docker-compose.yml"),
125399
+ label: "docker-images/docker-compose.yml"
125381
125400
  }
125382
125401
  ];
125383
125402
  for (const file of files) {
@@ -129948,10 +129967,154 @@ tmuxCommand.command("status").description("Show WSL development environment stat
129948
129967
  }
129949
129968
  });
129950
129969
 
129970
+ // src/commands/docker.ts
129971
+ var import_child_process12 = require("child_process");
129972
+ var import_path18 = require("path");
129973
+ var import_fs_extra16 = __toESM(require_lib());
129974
+ function checkDocker() {
129975
+ try {
129976
+ const version2 = (0, import_child_process12.spawnSync)("docker", ["--version"], {
129977
+ encoding: "utf-8",
129978
+ shell: true,
129979
+ timeout: 5e3,
129980
+ stdio: "pipe"
129981
+ });
129982
+ if (version2.status !== 0) {
129983
+ return { installed: false, running: false };
129984
+ }
129985
+ const info = (0, import_child_process12.spawnSync)("docker", ["info"], {
129986
+ encoding: "utf-8",
129987
+ shell: true,
129988
+ timeout: 1e4,
129989
+ stdio: "pipe"
129990
+ });
129991
+ return { installed: true, running: info.status === 0 };
129992
+ } catch {
129993
+ return { installed: false, running: false };
129994
+ }
129995
+ }
129996
+ function requireDocker() {
129997
+ const status = checkDocker();
129998
+ if (!status.installed) {
129999
+ logger.error("Docker is not installed.");
130000
+ console.log();
130001
+ console.log(` Install Docker Desktop: ${source_default.cyan("https://docs.docker.com/get-docker/")}`);
130002
+ console.log(` Then restart your terminal and try again.`);
130003
+ console.log();
130004
+ return false;
130005
+ }
130006
+ if (!status.running) {
130007
+ logger.error("Docker is installed but the daemon is not running.");
130008
+ console.log();
130009
+ console.log(` Start Docker Desktop and wait for it to be ready, then try again.`);
130010
+ console.log();
130011
+ return false;
130012
+ }
130013
+ return true;
130014
+ }
130015
+ function findComposeFile() {
130016
+ const cwd = process.cwd();
130017
+ const composePath = (0, import_path18.join)(cwd, "docker-images", "docker-compose.yml");
130018
+ if (import_fs_extra16.default.existsSync(composePath)) {
130019
+ return composePath;
130020
+ }
130021
+ return null;
130022
+ }
130023
+ function requireComposeFile() {
130024
+ const composePath = findComposeFile();
130025
+ if (!composePath) {
130026
+ logger.error("No docker-compose.yml found in docker-images/");
130027
+ console.log();
130028
+ console.log(` Make sure you are in a SmartStack project root directory.`);
130029
+ console.log(` Run ${source_default.cyan("ss upgrade")} to generate the Docker files.`);
130030
+ console.log();
130031
+ return null;
130032
+ }
130033
+ return composePath;
130034
+ }
130035
+ function runCompose(composePath, args) {
130036
+ const result = (0, import_child_process12.spawnSync)("docker", ["compose", "-f", composePath, ...args], {
130037
+ encoding: "utf-8",
130038
+ shell: true,
130039
+ stdio: "inherit",
130040
+ cwd: process.cwd()
130041
+ });
130042
+ return result.status ?? 1;
130043
+ }
130044
+ var dockerCommand = new Command("docker").description("Build and run SmartStack Docker images").addCommand(
130045
+ new Command("up").description("Build images and start containers").option("-d, --detach", "Run containers in the background").option("--no-build", "Skip image build, use existing images").action(async (options) => {
130046
+ if (!requireDocker()) return;
130047
+ const composePath = requireComposeFile();
130048
+ if (!composePath) return;
130049
+ logger.header("SmartStack Docker Up");
130050
+ const args = ["up"];
130051
+ if (options.build !== false) args.push("--build");
130052
+ if (options.detach) args.push("-d");
130053
+ const code = runCompose(composePath, args);
130054
+ if (code !== 0) {
130055
+ logger.error(`docker compose up exited with code ${code}`);
130056
+ process.exitCode = code;
130057
+ }
130058
+ })
130059
+ ).addCommand(
130060
+ new Command("down").description("Stop and remove containers").option("-v, --volumes", "Also remove volumes").action(async (options) => {
130061
+ if (!requireDocker()) return;
130062
+ const composePath = requireComposeFile();
130063
+ if (!composePath) return;
130064
+ logger.header("SmartStack Docker Down");
130065
+ const args = ["down"];
130066
+ if (options.volumes) args.push("-v");
130067
+ const code = runCompose(composePath, args);
130068
+ if (code !== 0) {
130069
+ logger.error(`docker compose down exited with code ${code}`);
130070
+ process.exitCode = code;
130071
+ }
130072
+ })
130073
+ ).addCommand(
130074
+ new Command("build").description("Build images without starting containers").option("--no-cache", "Build without using cache").action(async (options) => {
130075
+ if (!requireDocker()) return;
130076
+ const composePath = requireComposeFile();
130077
+ if (!composePath) return;
130078
+ logger.header("SmartStack Docker Build");
130079
+ const args = ["build"];
130080
+ if (options.cache === false) args.push("--no-cache");
130081
+ const code = runCompose(composePath, args);
130082
+ if (code !== 0) {
130083
+ logger.error(`docker compose build exited with code ${code}`);
130084
+ process.exitCode = code;
130085
+ }
130086
+ })
130087
+ ).addCommand(
130088
+ new Command("status").description("Show container status").action(async () => {
130089
+ if (!requireDocker()) return;
130090
+ const composePath = requireComposeFile();
130091
+ if (!composePath) return;
130092
+ const code = runCompose(composePath, ["ps", "-a"]);
130093
+ if (code !== 0) {
130094
+ process.exitCode = code;
130095
+ }
130096
+ })
130097
+ ).addCommand(
130098
+ new Command("logs").description("Show container logs").option("-f, --follow", "Follow log output").option("--tail <lines>", "Number of lines to show from the end", "100").argument("[service]", "Service name (backend or frontend)").action(async (service, options) => {
130099
+ if (!requireDocker()) return;
130100
+ const composePath = requireComposeFile();
130101
+ if (!composePath) return;
130102
+ const args = ["logs", "--tail", options.tail];
130103
+ if (options.follow) args.push("-f");
130104
+ if (service) args.push(service);
130105
+ const code = runCompose(composePath, args);
130106
+ if (code !== 0) {
130107
+ process.exitCode = code;
130108
+ }
130109
+ })
130110
+ ).action(() => {
130111
+ dockerCommand.outputHelp();
130112
+ });
130113
+
129951
130114
  // src/index.ts
129952
130115
  var import_fs6 = require("fs");
129953
- var import_path18 = require("path");
129954
- var pkg = JSON.parse((0, import_fs6.readFileSync)((0, import_path18.join)(__dirname, "..", "package.json"), "utf-8"));
130116
+ var import_path19 = require("path");
130117
+ var pkg = JSON.parse((0, import_fs6.readFileSync)((0, import_path19.join)(__dirname, "..", "package.json"), "utf-8"));
129955
130118
  var LICENSE_FREE_COMMANDS = ["license", "doctor", "help", "--help", "-h", "--version", "-v"];
129956
130119
  async function main2() {
129957
130120
  const program2 = new Command();
@@ -129971,6 +130134,7 @@ async function main2() {
129971
130134
  program2.addCommand(mcpCommand);
129972
130135
  program2.addCommand(businessAnalyseHandoffCommand);
129973
130136
  program2.addCommand(tmuxCommand);
130137
+ program2.addCommand(dockerCommand);
129974
130138
  const args = process.argv.slice(2);
129975
130139
  const commandName = args[0] || "";
129976
130140
  const requiresLicense = !LICENSE_FREE_COMMANDS.some(