@fern-api/fern-api-dev 5.84.0 → 5.85.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (2) hide show
  1. package/cli.cjs +1099 -116
  2. package/package.json +1 -1
package/cli.cjs CHANGED
@@ -45336,11 +45336,11 @@ var init_AbsoluteFilePath = __esm({
45336
45336
 
45337
45337
  // ../../commons/path-utils/lib/basename.js
45338
45338
  function basename3(path120, options2) {
45339
- const basename7 = path120.split("/").pop() ?? path120;
45339
+ const basename8 = path120.split("/").pop() ?? path120;
45340
45340
  if (options2?.stripExtension) {
45341
- return basename7.split(".")[0] ?? basename7;
45341
+ return basename8.split(".")[0] ?? basename8;
45342
45342
  }
45343
- return basename7;
45343
+ return basename8;
45344
45344
  }
45345
45345
  var init_basename = __esm({
45346
45346
  "../../commons/path-utils/lib/basename.js"() {
@@ -53603,8 +53603,8 @@ var require_tmp = __commonJS({
53603
53603
  if (!_isUndefined(options2.name)) {
53604
53604
  const name2 = options2.name;
53605
53605
  if (path120.isAbsolute(name2)) throw new Error(`name option must not contain an absolute path, found "${name2}".`);
53606
- const basename7 = path120.basename(name2);
53607
- if (basename7 === ".." || basename7 === "." || basename7 !== name2) {
53606
+ const basename8 = path120.basename(name2);
53607
+ if (basename8 === ".." || basename8 === "." || basename8 !== name2) {
53608
53608
  throw new Error(`name option must not contain a path, found "${name2}".`);
53609
53609
  }
53610
53610
  }
@@ -100826,7 +100826,7 @@ var require_graceful_fs = __commonJS({
100826
100826
  polyfills(fs35);
100827
100827
  fs35.gracefulify = patch5;
100828
100828
  fs35.createReadStream = createReadStream5;
100829
- fs35.createWriteStream = createWriteStream8;
100829
+ fs35.createWriteStream = createWriteStream9;
100830
100830
  var fs$readFile = fs35.readFile;
100831
100831
  fs35.readFile = readFile121;
100832
100832
  function readFile121(path120, options2, cb) {
@@ -101038,7 +101038,7 @@ var require_graceful_fs = __commonJS({
101038
101038
  function createReadStream5(path120, options2) {
101039
101039
  return new fs35.ReadStream(path120, options2);
101040
101040
  }
101041
- function createWriteStream8(path120, options2) {
101041
+ function createWriteStream9(path120, options2) {
101042
101042
  return new fs35.WriteStream(path120, options2);
101043
101043
  }
101044
101044
  var fs$open = fs35.open;
@@ -359353,8 +359353,8 @@ var init_ProtobufIRGenerator = __esm({
359353
359353
  await (0, import_promises35.cp)(absoluteFilepathToProtobufRoot, protobufGeneratorConfigPath, {
359354
359354
  recursive: true,
359355
359355
  filter: (src) => {
359356
- const basename7 = import_path41.default.basename(src);
359357
- return basename7 !== "buf.yaml" && !(basename7.startsWith("buf.gen.") && basename7.endsWith(".yaml"));
359356
+ const basename8 = import_path41.default.basename(src);
359357
+ return basename8 !== "buf.yaml" && !(basename8.startsWith("buf.gen.") && basename8.endsWith(".yaml"));
359358
359358
  }
359359
359359
  });
359360
359360
  }
@@ -473781,7 +473781,7 @@ var require_view = __commonJS({
473781
473781
  var path120 = require("path");
473782
473782
  var fs34 = require("fs");
473783
473783
  var dirname22 = path120.dirname;
473784
- var basename7 = path120.basename;
473784
+ var basename8 = path120.basename;
473785
473785
  var extname2 = path120.extname;
473786
473786
  var join28 = path120.join;
473787
473787
  var resolve15 = path120.resolve;
@@ -473820,7 +473820,7 @@ var require_view = __commonJS({
473820
473820
  var root6 = roots[i5];
473821
473821
  var loc = resolve15(root6, name2);
473822
473822
  var dir = dirname22(loc);
473823
- var file4 = basename7(loc);
473823
+ var file4 = basename8(loc);
473824
473824
  path121 = this.resolve(dir, file4);
473825
473825
  }
473826
473826
  return path121;
@@ -473836,7 +473836,7 @@ var require_view = __commonJS({
473836
473836
  if (stat7 && stat7.isFile()) {
473837
473837
  return path121;
473838
473838
  }
473839
- path121 = join28(dir, basename7(file4, ext2), "index" + ext2);
473839
+ path121 = join28(dir, basename8(file4, ext2), "index" + ext2);
473840
473840
  stat7 = tryStat(path121);
473841
473841
  if (stat7 && stat7.isFile()) {
473842
473842
  return path121;
@@ -473859,7 +473859,7 @@ var require_content_disposition = __commonJS({
473859
473859
  "use strict";
473860
473860
  module4.exports = contentDisposition;
473861
473861
  module4.exports.parse = parse19;
473862
- var basename7 = require("path").basename;
473862
+ var basename8 = require("path").basename;
473863
473863
  var Buffer6 = require_safe_buffer().Buffer;
473864
473864
  var ENCODE_URL_ATTR_CHAR_REGEXP = /[\x00-\x20"'()*,/:;<=>?@[\\\]{}\x7f]/g;
473865
473865
  var HEX_ESCAPE_REGEXP = /%[0-9A-Fa-f]{2}/;
@@ -473895,9 +473895,9 @@ var require_content_disposition = __commonJS({
473895
473895
  if (typeof fallback2 === "string" && NON_LATIN1_REGEXP.test(fallback2)) {
473896
473896
  throw new TypeError("fallback must be ISO-8859-1 string");
473897
473897
  }
473898
- var name2 = basename7(filename);
473898
+ var name2 = basename8(filename);
473899
473899
  var isQuotedString = TEXT_REGEXP.test(name2);
473900
- var fallbackName = typeof fallback2 !== "string" ? fallback2 && getlatin1(name2) : basename7(fallback2);
473900
+ var fallbackName = typeof fallback2 !== "string" ? fallback2 && getlatin1(name2) : basename8(fallback2);
473901
473901
  var hasFallback = typeof fallbackName === "string" && fallbackName !== name2;
473902
473902
  if (hasFallback || !isQuotedString || HEX_ESCAPE_REGEXP.test(name2)) {
473903
473903
  params2["filename*"] = name2;
@@ -482688,7 +482688,7 @@ var require_graceful_fs2 = __commonJS({
482688
482688
  polyfills(fs35);
482689
482689
  fs35.gracefulify = patch5;
482690
482690
  fs35.createReadStream = createReadStream5;
482691
- fs35.createWriteStream = createWriteStream8;
482691
+ fs35.createWriteStream = createWriteStream9;
482692
482692
  var fs$readFile = fs35.readFile;
482693
482693
  fs35.readFile = readFile121;
482694
482694
  function readFile121(path120, options2, cb) {
@@ -482900,7 +482900,7 @@ var require_graceful_fs2 = __commonJS({
482900
482900
  function createReadStream5(path120, options2) {
482901
482901
  return new fs35.ReadStream(path120, options2);
482902
482902
  }
482903
- function createWriteStream8(path120, options2) {
482903
+ function createWriteStream9(path120, options2) {
482904
482904
  return new fs35.WriteStream(path120, options2);
482905
482905
  }
482906
482906
  var fs$open = fs35.open;
@@ -490724,7 +490724,7 @@ var require_yauzl = __commonJS({
490724
490724
  exports2.getFileNameLowLevel = getFileNameLowLevel;
490725
490725
  exports2.validateFileName = validateFileName;
490726
490726
  exports2.parseExtraFields = parseExtraFields;
490727
- exports2.ZipFile = ZipFile;
490727
+ exports2.ZipFile = ZipFile2;
490728
490728
  exports2.Entry = Entry;
490729
490729
  exports2.LocalFileHeader = LocalFileHeader;
490730
490730
  exports2.RandomAccessReader = RandomAccessReader;
@@ -490833,19 +490833,19 @@ var require_yauzl = __commonJS({
490833
490833
  }
490834
490834
  entryCount = readUInt64LE(zip64EocdrBuffer, 32);
490835
490835
  centralDirectoryOffset = readUInt64LE(zip64EocdrBuffer, 48);
490836
- return callback(null, new ZipFile(reader, centralDirectoryOffset, totalSize, entryCount, comment6, options2.autoClose, options2.lazyEntries, decodeStrings, options2.validateEntrySizes, options2.strictFileNames));
490836
+ return callback(null, new ZipFile2(reader, centralDirectoryOffset, totalSize, entryCount, comment6, options2.autoClose, options2.lazyEntries, decodeStrings, options2.validateEntrySizes, options2.strictFileNames));
490837
490837
  });
490838
490838
  }
490839
490839
  if (diskNumber !== 0) {
490840
490840
  return callback(new Error("multi-disk zip files are not supported: found disk number: " + diskNumber));
490841
490841
  }
490842
- return callback(null, new ZipFile(reader, centralDirectoryOffset, totalSize, entryCount, comment6, options2.autoClose, options2.lazyEntries, decodeStrings, options2.validateEntrySizes, options2.strictFileNames));
490842
+ return callback(null, new ZipFile2(reader, centralDirectoryOffset, totalSize, entryCount, comment6, options2.autoClose, options2.lazyEntries, decodeStrings, options2.validateEntrySizes, options2.strictFileNames));
490843
490843
  }
490844
490844
  callback(new Error("End of central directory record signature not found. Either not a zip file, or file is truncated."));
490845
490845
  });
490846
490846
  }
490847
- util5.inherits(ZipFile, EventEmitter9);
490848
- function ZipFile(reader, centralDirectoryOffset, fileSize, entryCount, comment6, autoClose, lazyEntries, decodeStrings, validateEntrySizes, strictFileNames) {
490847
+ util5.inherits(ZipFile2, EventEmitter9);
490848
+ function ZipFile2(reader, centralDirectoryOffset, fileSize, entryCount, comment6, autoClose, lazyEntries, decodeStrings, validateEntrySizes, strictFileNames) {
490849
490849
  var self2 = this;
490850
490850
  EventEmitter9.call(self2);
490851
490851
  self2.reader = reader;
@@ -490869,7 +490869,7 @@ var require_yauzl = __commonJS({
490869
490869
  self2.emittedError = false;
490870
490870
  if (!self2.lazyEntries) self2._readEntry();
490871
490871
  }
490872
- ZipFile.prototype.close = function() {
490872
+ ZipFile2.prototype.close = function() {
490873
490873
  if (!this.isOpen) return;
490874
490874
  this.isOpen = false;
490875
490875
  this.reader.unref();
@@ -490883,11 +490883,11 @@ var require_yauzl = __commonJS({
490883
490883
  self2.emittedError = true;
490884
490884
  self2.emit("error", err);
490885
490885
  }
490886
- ZipFile.prototype.readEntry = function() {
490886
+ ZipFile2.prototype.readEntry = function() {
490887
490887
  if (!this.lazyEntries) throw new Error("readEntry() called without lazyEntries:true");
490888
490888
  this._readEntry();
490889
490889
  };
490890
- ZipFile.prototype._readEntry = function() {
490890
+ ZipFile2.prototype._readEntry = function() {
490891
490891
  var self2 = this;
490892
490892
  if (self2.entryCount === self2.entriesRead) {
490893
490893
  setImmediate(function() {
@@ -490991,7 +490991,7 @@ var require_yauzl = __commonJS({
490991
490991
  });
490992
490992
  });
490993
490993
  };
490994
- ZipFile.prototype.openReadStream = function(entry, options2, callback) {
490994
+ ZipFile2.prototype.openReadStream = function(entry, options2, callback) {
490995
490995
  var self2 = this;
490996
490996
  var relativeStart = 0;
490997
490997
  var relativeEnd = entry.compressedSize;
@@ -491073,7 +491073,7 @@ var require_yauzl = __commonJS({
491073
491073
  );
491074
491074
  });
491075
491075
  };
491076
- ZipFile.prototype.openReadStreamLowLevel = function(fileDataStart, compressedSize, relativeStart, relativeEnd, decompress3, uncompressedSize, callback) {
491076
+ ZipFile2.prototype.openReadStreamLowLevel = function(fileDataStart, compressedSize, relativeStart, relativeEnd, decompress3, uncompressedSize, callback) {
491077
491077
  var self2 = this;
491078
491078
  var fileDataEnd = fileDataStart + compressedSize;
491079
491079
  var readStream2 = self2.reader.createReadStream({
@@ -491110,7 +491110,7 @@ var require_yauzl = __commonJS({
491110
491110
  }
491111
491111
  callback(null, endpointStream);
491112
491112
  };
491113
- ZipFile.prototype.readLocalFileHeader = function(entry, options2, callback) {
491113
+ ZipFile2.prototype.readLocalFileHeader = function(entry, options2, callback) {
491114
491114
  var self2 = this;
491115
491115
  if (callback == null) {
491116
491116
  callback = options2;
@@ -509826,8 +509826,8 @@ var init_Page = __esm({
509826
509826
  throw error50;
509827
509827
  }
509828
509828
  if (options2.path) {
509829
- const { createWriteStream: createWriteStream8 } = environment.value.fs;
509830
- const stream5 = createWriteStream8(options2.path, "binary");
509829
+ const { createWriteStream: createWriteStream9 } = environment.value.fs;
509830
+ const stream5 = createWriteStream9(options2.path, "binary");
509831
509831
  recorder.pipe(stream5);
509832
509832
  }
509833
509833
  return recorder;
@@ -560739,7 +560739,7 @@ var require_extract_zip = __commonJS({
560739
560739
  "../../../node_modules/.pnpm/extract-zip@2.0.1/node_modules/extract-zip/index.js"(exports2, module4) {
560740
560740
  "use strict";
560741
560741
  var debug9 = require_src()("extract-zip");
560742
- var { createWriteStream: createWriteStream8, promises: fs34 } = require("fs");
560742
+ var { createWriteStream: createWriteStream9, promises: fs34 } = require("fs");
560743
560743
  var getStream = require_get_stream3();
560744
560744
  var path120 = require("path");
560745
560745
  var { promisify: promisify14 } = require("util");
@@ -560834,7 +560834,7 @@ var require_extract_zip = __commonJS({
560834
560834
  debug9("creating symlink", link3, dest);
560835
560835
  await fs34.symlink(link3, dest);
560836
560836
  } else {
560837
- await pipeline6(readStream2, createWriteStream8(dest, { mode: procMode }));
560837
+ await pipeline6(readStream2, createWriteStream9(dest, { mode: procMode }));
560838
560838
  }
560839
560839
  }
560840
560840
  getExtractedMode(entryMode, isDir) {
@@ -629292,6 +629292,955 @@ var require_lib19 = __commonJS({
629292
629292
  }
629293
629293
  });
629294
629294
 
629295
+ // ../../../node_modules/.pnpm/buffer-crc32@1.0.0/node_modules/buffer-crc32/dist/index.cjs
629296
+ var require_dist26 = __commonJS({
629297
+ "../../../node_modules/.pnpm/buffer-crc32@1.0.0/node_modules/buffer-crc32/dist/index.cjs"(exports2, module4) {
629298
+ "use strict";
629299
+ function getDefaultExportFromCjs(x4) {
629300
+ return x4 && x4.__esModule && Object.prototype.hasOwnProperty.call(x4, "default") ? x4["default"] : x4;
629301
+ }
629302
+ var CRC_TABLE = new Int32Array([
629303
+ 0,
629304
+ 1996959894,
629305
+ 3993919788,
629306
+ 2567524794,
629307
+ 124634137,
629308
+ 1886057615,
629309
+ 3915621685,
629310
+ 2657392035,
629311
+ 249268274,
629312
+ 2044508324,
629313
+ 3772115230,
629314
+ 2547177864,
629315
+ 162941995,
629316
+ 2125561021,
629317
+ 3887607047,
629318
+ 2428444049,
629319
+ 498536548,
629320
+ 1789927666,
629321
+ 4089016648,
629322
+ 2227061214,
629323
+ 450548861,
629324
+ 1843258603,
629325
+ 4107580753,
629326
+ 2211677639,
629327
+ 325883990,
629328
+ 1684777152,
629329
+ 4251122042,
629330
+ 2321926636,
629331
+ 335633487,
629332
+ 1661365465,
629333
+ 4195302755,
629334
+ 2366115317,
629335
+ 997073096,
629336
+ 1281953886,
629337
+ 3579855332,
629338
+ 2724688242,
629339
+ 1006888145,
629340
+ 1258607687,
629341
+ 3524101629,
629342
+ 2768942443,
629343
+ 901097722,
629344
+ 1119000684,
629345
+ 3686517206,
629346
+ 2898065728,
629347
+ 853044451,
629348
+ 1172266101,
629349
+ 3705015759,
629350
+ 2882616665,
629351
+ 651767980,
629352
+ 1373503546,
629353
+ 3369554304,
629354
+ 3218104598,
629355
+ 565507253,
629356
+ 1454621731,
629357
+ 3485111705,
629358
+ 3099436303,
629359
+ 671266974,
629360
+ 1594198024,
629361
+ 3322730930,
629362
+ 2970347812,
629363
+ 795835527,
629364
+ 1483230225,
629365
+ 3244367275,
629366
+ 3060149565,
629367
+ 1994146192,
629368
+ 31158534,
629369
+ 2563907772,
629370
+ 4023717930,
629371
+ 1907459465,
629372
+ 112637215,
629373
+ 2680153253,
629374
+ 3904427059,
629375
+ 2013776290,
629376
+ 251722036,
629377
+ 2517215374,
629378
+ 3775830040,
629379
+ 2137656763,
629380
+ 141376813,
629381
+ 2439277719,
629382
+ 3865271297,
629383
+ 1802195444,
629384
+ 476864866,
629385
+ 2238001368,
629386
+ 4066508878,
629387
+ 1812370925,
629388
+ 453092731,
629389
+ 2181625025,
629390
+ 4111451223,
629391
+ 1706088902,
629392
+ 314042704,
629393
+ 2344532202,
629394
+ 4240017532,
629395
+ 1658658271,
629396
+ 366619977,
629397
+ 2362670323,
629398
+ 4224994405,
629399
+ 1303535960,
629400
+ 984961486,
629401
+ 2747007092,
629402
+ 3569037538,
629403
+ 1256170817,
629404
+ 1037604311,
629405
+ 2765210733,
629406
+ 3554079995,
629407
+ 1131014506,
629408
+ 879679996,
629409
+ 2909243462,
629410
+ 3663771856,
629411
+ 1141124467,
629412
+ 855842277,
629413
+ 2852801631,
629414
+ 3708648649,
629415
+ 1342533948,
629416
+ 654459306,
629417
+ 3188396048,
629418
+ 3373015174,
629419
+ 1466479909,
629420
+ 544179635,
629421
+ 3110523913,
629422
+ 3462522015,
629423
+ 1591671054,
629424
+ 702138776,
629425
+ 2966460450,
629426
+ 3352799412,
629427
+ 1504918807,
629428
+ 783551873,
629429
+ 3082640443,
629430
+ 3233442989,
629431
+ 3988292384,
629432
+ 2596254646,
629433
+ 62317068,
629434
+ 1957810842,
629435
+ 3939845945,
629436
+ 2647816111,
629437
+ 81470997,
629438
+ 1943803523,
629439
+ 3814918930,
629440
+ 2489596804,
629441
+ 225274430,
629442
+ 2053790376,
629443
+ 3826175755,
629444
+ 2466906013,
629445
+ 167816743,
629446
+ 2097651377,
629447
+ 4027552580,
629448
+ 2265490386,
629449
+ 503444072,
629450
+ 1762050814,
629451
+ 4150417245,
629452
+ 2154129355,
629453
+ 426522225,
629454
+ 1852507879,
629455
+ 4275313526,
629456
+ 2312317920,
629457
+ 282753626,
629458
+ 1742555852,
629459
+ 4189708143,
629460
+ 2394877945,
629461
+ 397917763,
629462
+ 1622183637,
629463
+ 3604390888,
629464
+ 2714866558,
629465
+ 953729732,
629466
+ 1340076626,
629467
+ 3518719985,
629468
+ 2797360999,
629469
+ 1068828381,
629470
+ 1219638859,
629471
+ 3624741850,
629472
+ 2936675148,
629473
+ 906185462,
629474
+ 1090812512,
629475
+ 3747672003,
629476
+ 2825379669,
629477
+ 829329135,
629478
+ 1181335161,
629479
+ 3412177804,
629480
+ 3160834842,
629481
+ 628085408,
629482
+ 1382605366,
629483
+ 3423369109,
629484
+ 3138078467,
629485
+ 570562233,
629486
+ 1426400815,
629487
+ 3317316542,
629488
+ 2998733608,
629489
+ 733239954,
629490
+ 1555261956,
629491
+ 3268935591,
629492
+ 3050360625,
629493
+ 752459403,
629494
+ 1541320221,
629495
+ 2607071920,
629496
+ 3965973030,
629497
+ 1969922972,
629498
+ 40735498,
629499
+ 2617837225,
629500
+ 3943577151,
629501
+ 1913087877,
629502
+ 83908371,
629503
+ 2512341634,
629504
+ 3803740692,
629505
+ 2075208622,
629506
+ 213261112,
629507
+ 2463272603,
629508
+ 3855990285,
629509
+ 2094854071,
629510
+ 198958881,
629511
+ 2262029012,
629512
+ 4057260610,
629513
+ 1759359992,
629514
+ 534414190,
629515
+ 2176718541,
629516
+ 4139329115,
629517
+ 1873836001,
629518
+ 414664567,
629519
+ 2282248934,
629520
+ 4279200368,
629521
+ 1711684554,
629522
+ 285281116,
629523
+ 2405801727,
629524
+ 4167216745,
629525
+ 1634467795,
629526
+ 376229701,
629527
+ 2685067896,
629528
+ 3608007406,
629529
+ 1308918612,
629530
+ 956543938,
629531
+ 2808555105,
629532
+ 3495958263,
629533
+ 1231636301,
629534
+ 1047427035,
629535
+ 2932959818,
629536
+ 3654703836,
629537
+ 1088359270,
629538
+ 936918e3,
629539
+ 2847714899,
629540
+ 3736837829,
629541
+ 1202900863,
629542
+ 817233897,
629543
+ 3183342108,
629544
+ 3401237130,
629545
+ 1404277552,
629546
+ 615818150,
629547
+ 3134207493,
629548
+ 3453421203,
629549
+ 1423857449,
629550
+ 601450431,
629551
+ 3009837614,
629552
+ 3294710456,
629553
+ 1567103746,
629554
+ 711928724,
629555
+ 3020668471,
629556
+ 3272380065,
629557
+ 1510334235,
629558
+ 755167117
629559
+ ]);
629560
+ function ensureBuffer(input3) {
629561
+ if (Buffer.isBuffer(input3)) {
629562
+ return input3;
629563
+ }
629564
+ if (typeof input3 === "number") {
629565
+ return Buffer.alloc(input3);
629566
+ } else if (typeof input3 === "string") {
629567
+ return Buffer.from(input3);
629568
+ } else {
629569
+ throw new Error("input must be buffer, number, or string, received " + typeof input3);
629570
+ }
629571
+ }
629572
+ function bufferizeInt(num) {
629573
+ const tmp22 = ensureBuffer(4);
629574
+ tmp22.writeInt32BE(num, 0);
629575
+ return tmp22;
629576
+ }
629577
+ function _crc32(buf, previous4) {
629578
+ buf = ensureBuffer(buf);
629579
+ if (Buffer.isBuffer(previous4)) {
629580
+ previous4 = previous4.readUInt32BE(0);
629581
+ }
629582
+ let crc = ~~previous4 ^ -1;
629583
+ for (var n2 = 0; n2 < buf.length; n2++) {
629584
+ crc = CRC_TABLE[(crc ^ buf[n2]) & 255] ^ crc >>> 8;
629585
+ }
629586
+ return crc ^ -1;
629587
+ }
629588
+ function crc322() {
629589
+ return bufferizeInt(_crc32.apply(null, arguments));
629590
+ }
629591
+ crc322.signed = function() {
629592
+ return _crc32.apply(null, arguments);
629593
+ };
629594
+ crc322.unsigned = function() {
629595
+ return _crc32.apply(null, arguments) >>> 0;
629596
+ };
629597
+ var bufferCrc32 = crc322;
629598
+ var index3 = /* @__PURE__ */ getDefaultExportFromCjs(bufferCrc32);
629599
+ module4.exports = index3;
629600
+ }
629601
+ });
629602
+
629603
+ // ../../../node_modules/.pnpm/yazl@3.3.1/node_modules/yazl/index.js
629604
+ var require_yazl = __commonJS({
629605
+ "../../../node_modules/.pnpm/yazl@3.3.1/node_modules/yazl/index.js"(exports2) {
629606
+ "use strict";
629607
+ var fs34 = require("fs");
629608
+ var Transform = require("stream").Transform;
629609
+ var PassThrough5 = require("stream").PassThrough;
629610
+ var zlib4 = require("zlib");
629611
+ var util5 = require("util");
629612
+ var EventEmitter9 = require("events").EventEmitter;
629613
+ var errorMonitor3 = require("events").errorMonitor;
629614
+ var crc322 = require_dist26();
629615
+ exports2.ZipFile = ZipFile2;
629616
+ exports2.dateToDosDateTime = dateToDosDateTime;
629617
+ util5.inherits(ZipFile2, EventEmitter9);
629618
+ function ZipFile2() {
629619
+ this.outputStream = new PassThrough5();
629620
+ this.entries = [];
629621
+ this.outputStreamCursor = 0;
629622
+ this.ended = false;
629623
+ this.allDone = false;
629624
+ this.forceZip64Eocd = false;
629625
+ this.errored = false;
629626
+ this.on(errorMonitor3, function() {
629627
+ this.errored = true;
629628
+ });
629629
+ }
629630
+ ZipFile2.prototype.addFile = function(realPath, metadataPath, options2) {
629631
+ var self2 = this;
629632
+ metadataPath = validateMetadataPath(metadataPath, false);
629633
+ if (options2 == null) options2 = {};
629634
+ if (shouldIgnoreAdding(self2)) return;
629635
+ var entry = new Entry(metadataPath, false, options2);
629636
+ self2.entries.push(entry);
629637
+ fs34.stat(realPath, function(err, stats) {
629638
+ if (err) return self2.emit("error", err);
629639
+ if (!stats.isFile()) return self2.emit("error", new Error("not a file: " + realPath));
629640
+ entry.uncompressedSize = stats.size;
629641
+ if (options2.mtime == null) entry.setLastModDate(stats.mtime);
629642
+ if (options2.mode == null) entry.setFileAttributesMode(stats.mode);
629643
+ entry.setFileDataPumpFunction(function() {
629644
+ var readStream2 = fs34.createReadStream(realPath);
629645
+ entry.state = Entry.FILE_DATA_IN_PROGRESS;
629646
+ readStream2.on("error", function(err2) {
629647
+ self2.emit("error", err2);
629648
+ });
629649
+ pumpFileDataReadStream(self2, entry, readStream2);
629650
+ });
629651
+ pumpEntries(self2);
629652
+ });
629653
+ };
629654
+ ZipFile2.prototype.addReadStream = function(readStream2, metadataPath, options2) {
629655
+ this.addReadStreamLazy(metadataPath, options2, function(cb) {
629656
+ cb(null, readStream2);
629657
+ });
629658
+ };
629659
+ ZipFile2.prototype.addReadStreamLazy = function(metadataPath, options2, getReadStreamFunction) {
629660
+ var self2 = this;
629661
+ if (typeof options2 === "function") {
629662
+ getReadStreamFunction = options2;
629663
+ options2 = null;
629664
+ }
629665
+ if (options2 == null) options2 = {};
629666
+ metadataPath = validateMetadataPath(metadataPath, false);
629667
+ if (shouldIgnoreAdding(self2)) return;
629668
+ var entry = new Entry(metadataPath, false, options2);
629669
+ self2.entries.push(entry);
629670
+ entry.setFileDataPumpFunction(function() {
629671
+ entry.state = Entry.FILE_DATA_IN_PROGRESS;
629672
+ getReadStreamFunction(function(err, readStream2) {
629673
+ if (err) return self2.emit("error", err);
629674
+ pumpFileDataReadStream(self2, entry, readStream2);
629675
+ });
629676
+ });
629677
+ pumpEntries(self2);
629678
+ };
629679
+ ZipFile2.prototype.addBuffer = function(buffer, metadataPath, options2) {
629680
+ var self2 = this;
629681
+ metadataPath = validateMetadataPath(metadataPath, false);
629682
+ if (buffer.length > 1073741823) throw new Error("buffer too large: " + buffer.length + " > 1073741823");
629683
+ if (options2 == null) options2 = {};
629684
+ if (options2.size != null) throw new Error("options.size not allowed");
629685
+ if (shouldIgnoreAdding(self2)) return;
629686
+ var entry = new Entry(metadataPath, false, options2);
629687
+ entry.uncompressedSize = buffer.length;
629688
+ entry.crc32 = crc322.unsigned(buffer);
629689
+ entry.crcAndFileSizeKnown = true;
629690
+ self2.entries.push(entry);
629691
+ if (entry.compressionLevel === 0) {
629692
+ setCompressedBuffer(buffer);
629693
+ } else {
629694
+ zlib4.deflateRaw(buffer, { level: entry.compressionLevel }, function(err, compressedBuffer) {
629695
+ setCompressedBuffer(compressedBuffer);
629696
+ });
629697
+ }
629698
+ function setCompressedBuffer(compressedBuffer) {
629699
+ entry.compressedSize = compressedBuffer.length;
629700
+ entry.setFileDataPumpFunction(function() {
629701
+ writeToOutputStream(self2, compressedBuffer);
629702
+ writeToOutputStream(self2, entry.getDataDescriptor());
629703
+ entry.state = Entry.FILE_DATA_DONE;
629704
+ setImmediate(function() {
629705
+ pumpEntries(self2);
629706
+ });
629707
+ });
629708
+ pumpEntries(self2);
629709
+ }
629710
+ };
629711
+ ZipFile2.prototype.addEmptyDirectory = function(metadataPath, options2) {
629712
+ var self2 = this;
629713
+ metadataPath = validateMetadataPath(metadataPath, true);
629714
+ if (options2 == null) options2 = {};
629715
+ if (options2.size != null) throw new Error("options.size not allowed");
629716
+ if (options2.compress != null) throw new Error("options.compress not allowed");
629717
+ if (options2.compressionLevel != null) throw new Error("options.compressionLevel not allowed");
629718
+ if (shouldIgnoreAdding(self2)) return;
629719
+ var entry = new Entry(metadataPath, true, options2);
629720
+ self2.entries.push(entry);
629721
+ entry.setFileDataPumpFunction(function() {
629722
+ writeToOutputStream(self2, entry.getDataDescriptor());
629723
+ entry.state = Entry.FILE_DATA_DONE;
629724
+ pumpEntries(self2);
629725
+ });
629726
+ pumpEntries(self2);
629727
+ };
629728
+ var eocdrSignatureBuffer = bufferFrom([80, 75, 5, 6]);
629729
+ ZipFile2.prototype.end = function(options2, calculatedTotalSizeCallback) {
629730
+ if (typeof options2 === "function") {
629731
+ calculatedTotalSizeCallback = options2;
629732
+ options2 = null;
629733
+ }
629734
+ if (options2 == null) options2 = {};
629735
+ if (this.ended) return;
629736
+ this.ended = true;
629737
+ if (this.errored) return;
629738
+ this.calculatedTotalSizeCallback = calculatedTotalSizeCallback;
629739
+ this.forceZip64Eocd = !!options2.forceZip64Format;
629740
+ if (options2.comment) {
629741
+ if (typeof options2.comment === "string") {
629742
+ this.comment = encodeCp437(options2.comment);
629743
+ } else {
629744
+ this.comment = options2.comment;
629745
+ }
629746
+ if (this.comment.length > 65535) throw new Error("comment is too large");
629747
+ if (bufferIncludes(this.comment, eocdrSignatureBuffer)) throw new Error("comment contains end of central directory record signature");
629748
+ } else {
629749
+ this.comment = EMPTY_BUFFER;
629750
+ }
629751
+ pumpEntries(this);
629752
+ };
629753
+ function writeToOutputStream(self2, buffer) {
629754
+ self2.outputStream.write(buffer);
629755
+ self2.outputStreamCursor += buffer.length;
629756
+ }
629757
+ function pumpFileDataReadStream(self2, entry, readStream2) {
629758
+ var crc32Watcher = new Crc32Watcher();
629759
+ var uncompressedSizeCounter = new ByteCounter();
629760
+ var compressor = entry.compressionLevel !== 0 ? new zlib4.DeflateRaw({ level: entry.compressionLevel }) : new PassThrough5();
629761
+ var compressedSizeCounter = new ByteCounter();
629762
+ readStream2.pipe(crc32Watcher).pipe(uncompressedSizeCounter).pipe(compressor).pipe(compressedSizeCounter).pipe(self2.outputStream, { end: false });
629763
+ compressedSizeCounter.on("end", function() {
629764
+ entry.crc32 = crc32Watcher.crc32;
629765
+ if (entry.uncompressedSize == null) {
629766
+ entry.uncompressedSize = uncompressedSizeCounter.byteCount;
629767
+ } else {
629768
+ if (entry.uncompressedSize !== uncompressedSizeCounter.byteCount) return self2.emit("error", new Error("file data stream has unexpected number of bytes"));
629769
+ }
629770
+ entry.compressedSize = compressedSizeCounter.byteCount;
629771
+ self2.outputStreamCursor += entry.compressedSize;
629772
+ writeToOutputStream(self2, entry.getDataDescriptor());
629773
+ entry.state = Entry.FILE_DATA_DONE;
629774
+ pumpEntries(self2);
629775
+ });
629776
+ }
629777
+ function determineCompressionLevel(options2) {
629778
+ if (options2.compress != null && options2.compressionLevel != null) {
629779
+ if (!!options2.compress !== !!options2.compressionLevel) throw new Error("conflicting settings for compress and compressionLevel");
629780
+ }
629781
+ if (options2.compressionLevel != null) return options2.compressionLevel;
629782
+ if (options2.compress === false) return 0;
629783
+ return 6;
629784
+ }
629785
+ function pumpEntries(self2) {
629786
+ if (self2.allDone || self2.errored) return;
629787
+ if (self2.ended && self2.calculatedTotalSizeCallback != null) {
629788
+ var calculatedTotalSize = calculateTotalSize(self2);
629789
+ if (calculatedTotalSize != null) {
629790
+ self2.calculatedTotalSizeCallback(calculatedTotalSize);
629791
+ self2.calculatedTotalSizeCallback = null;
629792
+ }
629793
+ }
629794
+ var entry = getFirstNotDoneEntry();
629795
+ function getFirstNotDoneEntry() {
629796
+ for (var i5 = 0; i5 < self2.entries.length; i5++) {
629797
+ var entry2 = self2.entries[i5];
629798
+ if (entry2.state < Entry.FILE_DATA_DONE) return entry2;
629799
+ }
629800
+ return null;
629801
+ }
629802
+ if (entry != null) {
629803
+ if (entry.state < Entry.READY_TO_PUMP_FILE_DATA) return;
629804
+ if (entry.state === Entry.FILE_DATA_IN_PROGRESS) return;
629805
+ entry.relativeOffsetOfLocalHeader = self2.outputStreamCursor;
629806
+ var localFileHeader = entry.getLocalFileHeader();
629807
+ writeToOutputStream(self2, localFileHeader);
629808
+ entry.doFileDataPump();
629809
+ } else {
629810
+ if (self2.ended) {
629811
+ self2.offsetOfStartOfCentralDirectory = self2.outputStreamCursor;
629812
+ self2.entries.forEach(function(entry2) {
629813
+ var centralDirectoryRecord = entry2.getCentralDirectoryRecord();
629814
+ writeToOutputStream(self2, centralDirectoryRecord);
629815
+ });
629816
+ writeToOutputStream(self2, getEndOfCentralDirectoryRecord(self2));
629817
+ self2.outputStream.end();
629818
+ self2.allDone = true;
629819
+ }
629820
+ }
629821
+ }
629822
+ function calculateTotalSize(self2) {
629823
+ var pretendOutputCursor = 0;
629824
+ var centralDirectorySize = 0;
629825
+ for (var i5 = 0; i5 < self2.entries.length; i5++) {
629826
+ var entry = self2.entries[i5];
629827
+ if (entry.compressionLevel !== 0) return -1;
629828
+ if (entry.state >= Entry.READY_TO_PUMP_FILE_DATA) {
629829
+ if (entry.uncompressedSize == null) return -1;
629830
+ } else {
629831
+ if (entry.uncompressedSize == null) return null;
629832
+ }
629833
+ entry.relativeOffsetOfLocalHeader = pretendOutputCursor;
629834
+ var useZip64Format = entry.useZip64Format();
629835
+ pretendOutputCursor += LOCAL_FILE_HEADER_FIXED_SIZE + entry.utf8FileName.length;
629836
+ pretendOutputCursor += entry.uncompressedSize;
629837
+ if (!entry.crcAndFileSizeKnown) {
629838
+ if (useZip64Format) {
629839
+ pretendOutputCursor += ZIP64_DATA_DESCRIPTOR_SIZE;
629840
+ } else {
629841
+ pretendOutputCursor += DATA_DESCRIPTOR_SIZE;
629842
+ }
629843
+ }
629844
+ centralDirectorySize += CENTRAL_DIRECTORY_RECORD_FIXED_SIZE + entry.utf8FileName.length + entry.fileComment.length;
629845
+ if (!entry.forceDosTimestamp) {
629846
+ centralDirectorySize += INFO_ZIP_UNIVERSAL_TIMESTAMP_EXTRA_FIELD_SIZE;
629847
+ }
629848
+ if (useZip64Format) {
629849
+ centralDirectorySize += ZIP64_EXTENDED_INFORMATION_EXTRA_FIELD_SIZE;
629850
+ }
629851
+ }
629852
+ var endOfCentralDirectorySize = 0;
629853
+ if (self2.forceZip64Eocd || self2.entries.length >= 65535 || centralDirectorySize >= 65535 || pretendOutputCursor >= 4294967295) {
629854
+ endOfCentralDirectorySize += ZIP64_END_OF_CENTRAL_DIRECTORY_RECORD_SIZE + ZIP64_END_OF_CENTRAL_DIRECTORY_LOCATOR_SIZE;
629855
+ }
629856
+ endOfCentralDirectorySize += END_OF_CENTRAL_DIRECTORY_RECORD_SIZE + self2.comment.length;
629857
+ return pretendOutputCursor + centralDirectorySize + endOfCentralDirectorySize;
629858
+ }
629859
+ function shouldIgnoreAdding(self2) {
629860
+ if (self2.ended) throw new Error("cannot add entries after calling end()");
629861
+ if (self2.errored) return true;
629862
+ return false;
629863
+ }
629864
+ var ZIP64_END_OF_CENTRAL_DIRECTORY_RECORD_SIZE = 56;
629865
+ var ZIP64_END_OF_CENTRAL_DIRECTORY_LOCATOR_SIZE = 20;
629866
+ var END_OF_CENTRAL_DIRECTORY_RECORD_SIZE = 22;
629867
+ function getEndOfCentralDirectoryRecord(self2, actuallyJustTellMeHowLongItWouldBe) {
629868
+ var needZip64Format = false;
629869
+ var normalEntriesLength = self2.entries.length;
629870
+ if (self2.forceZip64Eocd || self2.entries.length >= 65535) {
629871
+ normalEntriesLength = 65535;
629872
+ needZip64Format = true;
629873
+ }
629874
+ var sizeOfCentralDirectory = self2.outputStreamCursor - self2.offsetOfStartOfCentralDirectory;
629875
+ var normalSizeOfCentralDirectory = sizeOfCentralDirectory;
629876
+ if (self2.forceZip64Eocd || sizeOfCentralDirectory >= 4294967295) {
629877
+ normalSizeOfCentralDirectory = 4294967295;
629878
+ needZip64Format = true;
629879
+ }
629880
+ var normalOffsetOfStartOfCentralDirectory = self2.offsetOfStartOfCentralDirectory;
629881
+ if (self2.forceZip64Eocd || self2.offsetOfStartOfCentralDirectory >= 4294967295) {
629882
+ normalOffsetOfStartOfCentralDirectory = 4294967295;
629883
+ needZip64Format = true;
629884
+ }
629885
+ if (actuallyJustTellMeHowLongItWouldBe) {
629886
+ if (needZip64Format) {
629887
+ return ZIP64_END_OF_CENTRAL_DIRECTORY_RECORD_SIZE + ZIP64_END_OF_CENTRAL_DIRECTORY_LOCATOR_SIZE + END_OF_CENTRAL_DIRECTORY_RECORD_SIZE;
629888
+ } else {
629889
+ return END_OF_CENTRAL_DIRECTORY_RECORD_SIZE;
629890
+ }
629891
+ }
629892
+ var eocdrBuffer = bufferAlloc(END_OF_CENTRAL_DIRECTORY_RECORD_SIZE + self2.comment.length);
629893
+ eocdrBuffer.writeUInt32LE(101010256, 0);
629894
+ eocdrBuffer.writeUInt16LE(0, 4);
629895
+ eocdrBuffer.writeUInt16LE(0, 6);
629896
+ eocdrBuffer.writeUInt16LE(normalEntriesLength, 8);
629897
+ eocdrBuffer.writeUInt16LE(normalEntriesLength, 10);
629898
+ eocdrBuffer.writeUInt32LE(normalSizeOfCentralDirectory, 12);
629899
+ eocdrBuffer.writeUInt32LE(normalOffsetOfStartOfCentralDirectory, 16);
629900
+ eocdrBuffer.writeUInt16LE(self2.comment.length, 20);
629901
+ self2.comment.copy(eocdrBuffer, 22);
629902
+ if (!needZip64Format) return eocdrBuffer;
629903
+ var zip64EocdrBuffer = bufferAlloc(ZIP64_END_OF_CENTRAL_DIRECTORY_RECORD_SIZE);
629904
+ zip64EocdrBuffer.writeUInt32LE(101075792, 0);
629905
+ writeUInt64LE(zip64EocdrBuffer, ZIP64_END_OF_CENTRAL_DIRECTORY_RECORD_SIZE - 12, 4);
629906
+ zip64EocdrBuffer.writeUInt16LE(VERSION_MADE_BY, 12);
629907
+ zip64EocdrBuffer.writeUInt16LE(VERSION_NEEDED_TO_EXTRACT_ZIP64, 14);
629908
+ zip64EocdrBuffer.writeUInt32LE(0, 16);
629909
+ zip64EocdrBuffer.writeUInt32LE(0, 20);
629910
+ writeUInt64LE(zip64EocdrBuffer, self2.entries.length, 24);
629911
+ writeUInt64LE(zip64EocdrBuffer, self2.entries.length, 32);
629912
+ writeUInt64LE(zip64EocdrBuffer, sizeOfCentralDirectory, 40);
629913
+ writeUInt64LE(zip64EocdrBuffer, self2.offsetOfStartOfCentralDirectory, 48);
629914
+ var zip64EocdlBuffer = bufferAlloc(ZIP64_END_OF_CENTRAL_DIRECTORY_LOCATOR_SIZE);
629915
+ zip64EocdlBuffer.writeUInt32LE(117853008, 0);
629916
+ zip64EocdlBuffer.writeUInt32LE(0, 4);
629917
+ writeUInt64LE(zip64EocdlBuffer, self2.outputStreamCursor, 8);
629918
+ zip64EocdlBuffer.writeUInt32LE(1, 16);
629919
+ return Buffer.concat([
629920
+ zip64EocdrBuffer,
629921
+ zip64EocdlBuffer,
629922
+ eocdrBuffer
629923
+ ]);
629924
+ }
629925
+ function validateMetadataPath(metadataPath, isDirectory) {
629926
+ if (metadataPath === "") throw new Error("empty metadataPath");
629927
+ metadataPath = metadataPath.replace(/\\/g, "/");
629928
+ if (/^[a-zA-Z]:/.test(metadataPath) || /^\//.test(metadataPath)) throw new Error("absolute path: " + metadataPath);
629929
+ if (metadataPath.split("/").indexOf("..") !== -1) throw new Error("invalid relative path: " + metadataPath);
629930
+ var looksLikeDirectory = /\/$/.test(metadataPath);
629931
+ if (isDirectory) {
629932
+ if (!looksLikeDirectory) metadataPath += "/";
629933
+ } else {
629934
+ if (looksLikeDirectory) throw new Error("file path cannot end with '/': " + metadataPath);
629935
+ }
629936
+ return metadataPath;
629937
+ }
629938
+ var EMPTY_BUFFER = bufferAlloc(0);
629939
+ function Entry(metadataPath, isDirectory, options2) {
629940
+ this.utf8FileName = bufferFrom(metadataPath);
629941
+ if (this.utf8FileName.length > 65535) throw new Error("utf8 file name too long. " + utf8FileName.length + " > 65535");
629942
+ this.isDirectory = isDirectory;
629943
+ this.state = Entry.WAITING_FOR_METADATA;
629944
+ this.setLastModDate(options2.mtime != null ? options2.mtime : /* @__PURE__ */ new Date());
629945
+ this.forceDosTimestamp = !!options2.forceDosTimestamp;
629946
+ if (options2.mode != null) {
629947
+ this.setFileAttributesMode(options2.mode);
629948
+ } else {
629949
+ this.setFileAttributesMode(isDirectory ? 16893 : 33204);
629950
+ }
629951
+ if (isDirectory) {
629952
+ this.crcAndFileSizeKnown = true;
629953
+ this.crc32 = 0;
629954
+ this.uncompressedSize = 0;
629955
+ this.compressedSize = 0;
629956
+ } else {
629957
+ this.crcAndFileSizeKnown = false;
629958
+ this.crc32 = null;
629959
+ this.uncompressedSize = null;
629960
+ this.compressedSize = null;
629961
+ if (options2.size != null) this.uncompressedSize = options2.size;
629962
+ }
629963
+ if (isDirectory) {
629964
+ this.compressionLevel = 0;
629965
+ } else {
629966
+ this.compressionLevel = determineCompressionLevel(options2);
629967
+ }
629968
+ this.forceZip64Format = !!options2.forceZip64Format;
629969
+ if (options2.fileComment) {
629970
+ if (typeof options2.fileComment === "string") {
629971
+ this.fileComment = bufferFrom(options2.fileComment, "utf-8");
629972
+ } else {
629973
+ this.fileComment = options2.fileComment;
629974
+ }
629975
+ if (this.fileComment.length > 65535) throw new Error("fileComment is too large");
629976
+ } else {
629977
+ this.fileComment = EMPTY_BUFFER;
629978
+ }
629979
+ }
629980
+ Entry.WAITING_FOR_METADATA = 0;
629981
+ Entry.READY_TO_PUMP_FILE_DATA = 1;
629982
+ Entry.FILE_DATA_IN_PROGRESS = 2;
629983
+ Entry.FILE_DATA_DONE = 3;
629984
+ Entry.prototype.setLastModDate = function(date26) {
629985
+ this.mtime = date26;
629986
+ var dosDateTime = dateToDosDateTime(date26);
629987
+ this.lastModFileTime = dosDateTime.time;
629988
+ this.lastModFileDate = dosDateTime.date;
629989
+ };
629990
+ Entry.prototype.setFileAttributesMode = function(mode) {
629991
+ if ((mode & 65535) !== mode) throw new Error("invalid mode. expected: 0 <= " + mode + " <= 65535");
629992
+ this.externalFileAttributes = mode << 16 >>> 0;
629993
+ };
629994
+ Entry.prototype.setFileDataPumpFunction = function(doFileDataPump) {
629995
+ this.doFileDataPump = doFileDataPump;
629996
+ this.state = Entry.READY_TO_PUMP_FILE_DATA;
629997
+ };
629998
+ Entry.prototype.useZip64Format = function() {
629999
+ return this.forceZip64Format || this.uncompressedSize != null && this.uncompressedSize > 4294967294 || this.compressedSize != null && this.compressedSize > 4294967294 || this.relativeOffsetOfLocalHeader != null && this.relativeOffsetOfLocalHeader > 4294967294;
630000
+ };
630001
+ var LOCAL_FILE_HEADER_FIXED_SIZE = 30;
630002
+ var VERSION_NEEDED_TO_EXTRACT_UTF8 = 20;
630003
+ var VERSION_NEEDED_TO_EXTRACT_ZIP64 = 45;
630004
+ var VERSION_MADE_BY = 3 << 8 | 63;
630005
+ var FILE_NAME_IS_UTF8 = 1 << 11;
630006
+ var UNKNOWN_CRC32_AND_FILE_SIZES = 1 << 3;
630007
+ Entry.prototype.getLocalFileHeader = function() {
630008
+ var crc323 = 0;
630009
+ var compressedSize = 0;
630010
+ var uncompressedSize = 0;
630011
+ if (this.crcAndFileSizeKnown) {
630012
+ crc323 = this.crc32;
630013
+ compressedSize = this.compressedSize;
630014
+ uncompressedSize = this.uncompressedSize;
630015
+ }
630016
+ var fixedSizeStuff = bufferAlloc(LOCAL_FILE_HEADER_FIXED_SIZE);
630017
+ var generalPurposeBitFlag = FILE_NAME_IS_UTF8;
630018
+ if (!this.crcAndFileSizeKnown) generalPurposeBitFlag |= UNKNOWN_CRC32_AND_FILE_SIZES;
630019
+ fixedSizeStuff.writeUInt32LE(67324752, 0);
630020
+ fixedSizeStuff.writeUInt16LE(VERSION_NEEDED_TO_EXTRACT_UTF8, 4);
630021
+ fixedSizeStuff.writeUInt16LE(generalPurposeBitFlag, 6);
630022
+ fixedSizeStuff.writeUInt16LE(this.getCompressionMethod(), 8);
630023
+ fixedSizeStuff.writeUInt16LE(this.lastModFileTime, 10);
630024
+ fixedSizeStuff.writeUInt16LE(this.lastModFileDate, 12);
630025
+ fixedSizeStuff.writeUInt32LE(crc323, 14);
630026
+ fixedSizeStuff.writeUInt32LE(compressedSize, 18);
630027
+ fixedSizeStuff.writeUInt32LE(uncompressedSize, 22);
630028
+ fixedSizeStuff.writeUInt16LE(this.utf8FileName.length, 26);
630029
+ fixedSizeStuff.writeUInt16LE(0, 28);
630030
+ return Buffer.concat([
630031
+ fixedSizeStuff,
630032
+ // file name (variable size)
630033
+ this.utf8FileName
630034
+ // extra field (variable size)
630035
+ // no extra fields
630036
+ ]);
630037
+ };
630038
+ var DATA_DESCRIPTOR_SIZE = 16;
630039
+ var ZIP64_DATA_DESCRIPTOR_SIZE = 24;
630040
+ Entry.prototype.getDataDescriptor = function() {
630041
+ if (this.crcAndFileSizeKnown) {
630042
+ return EMPTY_BUFFER;
630043
+ }
630044
+ if (!this.useZip64Format()) {
630045
+ var buffer = bufferAlloc(DATA_DESCRIPTOR_SIZE);
630046
+ buffer.writeUInt32LE(134695760, 0);
630047
+ buffer.writeUInt32LE(this.crc32, 4);
630048
+ buffer.writeUInt32LE(this.compressedSize, 8);
630049
+ buffer.writeUInt32LE(this.uncompressedSize, 12);
630050
+ return buffer;
630051
+ } else {
630052
+ var buffer = bufferAlloc(ZIP64_DATA_DESCRIPTOR_SIZE);
630053
+ buffer.writeUInt32LE(134695760, 0);
630054
+ buffer.writeUInt32LE(this.crc32, 4);
630055
+ writeUInt64LE(buffer, this.compressedSize, 8);
630056
+ writeUInt64LE(buffer, this.uncompressedSize, 16);
630057
+ return buffer;
630058
+ }
630059
+ };
630060
+ var CENTRAL_DIRECTORY_RECORD_FIXED_SIZE = 46;
630061
+ var INFO_ZIP_UNIVERSAL_TIMESTAMP_EXTRA_FIELD_SIZE = 9;
630062
+ var ZIP64_EXTENDED_INFORMATION_EXTRA_FIELD_SIZE = 28;
630063
+ Entry.prototype.getCentralDirectoryRecord = function() {
630064
+ var fixedSizeStuff = bufferAlloc(CENTRAL_DIRECTORY_RECORD_FIXED_SIZE);
630065
+ var generalPurposeBitFlag = FILE_NAME_IS_UTF8;
630066
+ if (!this.crcAndFileSizeKnown) generalPurposeBitFlag |= UNKNOWN_CRC32_AND_FILE_SIZES;
630067
+ var izutefBuffer = EMPTY_BUFFER;
630068
+ if (!this.forceDosTimestamp) {
630069
+ izutefBuffer = bufferAlloc(INFO_ZIP_UNIVERSAL_TIMESTAMP_EXTRA_FIELD_SIZE);
630070
+ izutefBuffer.writeUInt16LE(21589, 0);
630071
+ izutefBuffer.writeUInt16LE(INFO_ZIP_UNIVERSAL_TIMESTAMP_EXTRA_FIELD_SIZE - 4, 2);
630072
+ var EB_UT_FL_MTIME = 1 << 0;
630073
+ var EB_UT_FL_ATIME = 1 << 1;
630074
+ izutefBuffer.writeUInt8(EB_UT_FL_MTIME | EB_UT_FL_ATIME, 4);
630075
+ var timestamp = Math.floor(this.mtime.getTime() / 1e3);
630076
+ if (timestamp < -2147483648) timestamp = -2147483648;
630077
+ if (timestamp > 2147483647) timestamp = 2147483647;
630078
+ izutefBuffer.writeUInt32LE(timestamp, 5);
630079
+ }
630080
+ var normalCompressedSize = this.compressedSize;
630081
+ var normalUncompressedSize = this.uncompressedSize;
630082
+ var normalRelativeOffsetOfLocalHeader = this.relativeOffsetOfLocalHeader;
630083
+ var versionNeededToExtract = VERSION_NEEDED_TO_EXTRACT_UTF8;
630084
+ var zeiefBuffer = EMPTY_BUFFER;
630085
+ if (this.useZip64Format()) {
630086
+ normalCompressedSize = 4294967295;
630087
+ normalUncompressedSize = 4294967295;
630088
+ normalRelativeOffsetOfLocalHeader = 4294967295;
630089
+ versionNeededToExtract = VERSION_NEEDED_TO_EXTRACT_ZIP64;
630090
+ zeiefBuffer = bufferAlloc(ZIP64_EXTENDED_INFORMATION_EXTRA_FIELD_SIZE);
630091
+ zeiefBuffer.writeUInt16LE(1, 0);
630092
+ zeiefBuffer.writeUInt16LE(ZIP64_EXTENDED_INFORMATION_EXTRA_FIELD_SIZE - 4, 2);
630093
+ writeUInt64LE(zeiefBuffer, this.uncompressedSize, 4);
630094
+ writeUInt64LE(zeiefBuffer, this.compressedSize, 12);
630095
+ writeUInt64LE(zeiefBuffer, this.relativeOffsetOfLocalHeader, 20);
630096
+ }
630097
+ fixedSizeStuff.writeUInt32LE(33639248, 0);
630098
+ fixedSizeStuff.writeUInt16LE(VERSION_MADE_BY, 4);
630099
+ fixedSizeStuff.writeUInt16LE(versionNeededToExtract, 6);
630100
+ fixedSizeStuff.writeUInt16LE(generalPurposeBitFlag, 8);
630101
+ fixedSizeStuff.writeUInt16LE(this.getCompressionMethod(), 10);
630102
+ fixedSizeStuff.writeUInt16LE(this.lastModFileTime, 12);
630103
+ fixedSizeStuff.writeUInt16LE(this.lastModFileDate, 14);
630104
+ fixedSizeStuff.writeUInt32LE(this.crc32, 16);
630105
+ fixedSizeStuff.writeUInt32LE(normalCompressedSize, 20);
630106
+ fixedSizeStuff.writeUInt32LE(normalUncompressedSize, 24);
630107
+ fixedSizeStuff.writeUInt16LE(this.utf8FileName.length, 28);
630108
+ fixedSizeStuff.writeUInt16LE(izutefBuffer.length + zeiefBuffer.length, 30);
630109
+ fixedSizeStuff.writeUInt16LE(this.fileComment.length, 32);
630110
+ fixedSizeStuff.writeUInt16LE(0, 34);
630111
+ fixedSizeStuff.writeUInt16LE(0, 36);
630112
+ fixedSizeStuff.writeUInt32LE(this.externalFileAttributes, 38);
630113
+ fixedSizeStuff.writeUInt32LE(normalRelativeOffsetOfLocalHeader, 42);
630114
+ return Buffer.concat([
630115
+ fixedSizeStuff,
630116
+ // file name (variable size)
630117
+ this.utf8FileName,
630118
+ // extra field (variable size)
630119
+ izutefBuffer,
630120
+ zeiefBuffer,
630121
+ // file comment (variable size)
630122
+ this.fileComment
630123
+ ]);
630124
+ };
630125
+ Entry.prototype.getCompressionMethod = function() {
630126
+ var NO_COMPRESSION = 0;
630127
+ var DEFLATE_COMPRESSION = 8;
630128
+ return this.compressionLevel === 0 ? NO_COMPRESSION : DEFLATE_COMPRESSION;
630129
+ };
630130
+ var minDosDate = new Date(1980, 0, 1);
630131
+ var maxDosDate = new Date(2107, 11, 31, 23, 59, 58);
630132
+ function dateToDosDateTime(jsDate) {
630133
+ if (jsDate < minDosDate) jsDate = minDosDate;
630134
+ else if (jsDate > maxDosDate) jsDate = maxDosDate;
630135
+ var date26 = 0;
630136
+ date26 |= jsDate.getDate() & 31;
630137
+ date26 |= (jsDate.getMonth() + 1 & 15) << 5;
630138
+ date26 |= (jsDate.getFullYear() - 1980 & 127) << 9;
630139
+ var time3 = 0;
630140
+ time3 |= Math.floor(jsDate.getSeconds() / 2);
630141
+ time3 |= (jsDate.getMinutes() & 63) << 5;
630142
+ time3 |= (jsDate.getHours() & 31) << 11;
630143
+ return { date: date26, time: time3 };
630144
+ }
630145
+ function writeUInt64LE(buffer, n2, offset2) {
630146
+ var high = Math.floor(n2 / 4294967296);
630147
+ var low = n2 % 4294967296;
630148
+ buffer.writeUInt32LE(low, offset2);
630149
+ buffer.writeUInt32LE(high, offset2 + 4);
630150
+ }
630151
+ util5.inherits(ByteCounter, Transform);
630152
+ function ByteCounter(options2) {
630153
+ Transform.call(this, options2);
630154
+ this.byteCount = 0;
630155
+ }
630156
+ ByteCounter.prototype._transform = function(chunk2, encoding, cb) {
630157
+ this.byteCount += chunk2.length;
630158
+ cb(null, chunk2);
630159
+ };
630160
+ util5.inherits(Crc32Watcher, Transform);
630161
+ function Crc32Watcher(options2) {
630162
+ Transform.call(this, options2);
630163
+ this.crc32 = 0;
630164
+ }
630165
+ Crc32Watcher.prototype._transform = function(chunk2, encoding, cb) {
630166
+ this.crc32 = crc322.unsigned(chunk2, this.crc32);
630167
+ cb(null, chunk2);
630168
+ };
630169
+ var cp437 = "\0\u263A\u263B\u2665\u2666\u2663\u2660\u2022\u25D8\u25CB\u25D9\u2642\u2640\u266A\u266B\u263C\u25BA\u25C4\u2195\u203C\xB6\xA7\u25AC\u21A8\u2191\u2193\u2192\u2190\u221F\u2194\u25B2\u25BC !\"#$%&'()*+,-./0123456789:;<=>?@ABCDEFGHIJKLMNOPQRSTUVWXYZ[\\]^_`abcdefghijklmnopqrstuvwxyz{|}~\u2302\xC7\xFC\xE9\xE2\xE4\xE0\xE5\xE7\xEA\xEB\xE8\xEF\xEE\xEC\xC4\xC5\xC9\xE6\xC6\xF4\xF6\xF2\xFB\xF9\xFF\xD6\xDC\xA2\xA3\xA5\u20A7\u0192\xE1\xED\xF3\xFA\xF1\xD1\xAA\xBA\xBF\u2310\xAC\xBD\xBC\xA1\xAB\xBB\u2591\u2592\u2593\u2502\u2524\u2561\u2562\u2556\u2555\u2563\u2551\u2557\u255D\u255C\u255B\u2510\u2514\u2534\u252C\u251C\u2500\u253C\u255E\u255F\u255A\u2554\u2569\u2566\u2560\u2550\u256C\u2567\u2568\u2564\u2565\u2559\u2558\u2552\u2553\u256B\u256A\u2518\u250C\u2588\u2584\u258C\u2590\u2580\u03B1\xDF\u0393\u03C0\u03A3\u03C3\xB5\u03C4\u03A6\u0398\u03A9\u03B4\u221E\u03C6\u03B5\u2229\u2261\xB1\u2265\u2264\u2320\u2321\xF7\u2248\xB0\u2219\xB7\u221A\u207F\xB2\u25A0\xA0";
630170
+ if (cp437.length !== 256) throw new Error("assertion failure");
630171
+ var reverseCp437 = null;
630172
+ function encodeCp437(string28) {
630173
+ if (/^[\x20-\x7e]*$/.test(string28)) {
630174
+ return bufferFrom(string28, "utf-8");
630175
+ }
630176
+ if (reverseCp437 == null) {
630177
+ reverseCp437 = {};
630178
+ for (var i5 = 0; i5 < cp437.length; i5++) {
630179
+ reverseCp437[cp437[i5]] = i5;
630180
+ }
630181
+ }
630182
+ var result = bufferAlloc(string28.length);
630183
+ for (var i5 = 0; i5 < string28.length; i5++) {
630184
+ var b5 = reverseCp437[string28[i5]];
630185
+ if (b5 == null) throw new Error("character not encodable in CP437: " + JSON.stringify(string28[i5]));
630186
+ result[i5] = b5;
630187
+ }
630188
+ return result;
630189
+ }
630190
+ function bufferAlloc(size2) {
630191
+ bufferAlloc = modern;
630192
+ try {
630193
+ return bufferAlloc(size2);
630194
+ } catch (e2) {
630195
+ bufferAlloc = legacy;
630196
+ return bufferAlloc(size2);
630197
+ }
630198
+ function modern(size3) {
630199
+ return Buffer.allocUnsafe(size3);
630200
+ }
630201
+ function legacy(size3) {
630202
+ return new Buffer(size3);
630203
+ }
630204
+ }
630205
+ function bufferFrom(something, encoding) {
630206
+ bufferFrom = modern;
630207
+ try {
630208
+ return bufferFrom(something, encoding);
630209
+ } catch (e2) {
630210
+ bufferFrom = legacy;
630211
+ return bufferFrom(something, encoding);
630212
+ }
630213
+ function modern(something2, encoding2) {
630214
+ return Buffer.from(something2, encoding2);
630215
+ }
630216
+ function legacy(something2, encoding2) {
630217
+ return new Buffer(something2, encoding2);
630218
+ }
630219
+ }
630220
+ function bufferIncludes(buffer, content5) {
630221
+ bufferIncludes = modern;
630222
+ try {
630223
+ return bufferIncludes(buffer, content5);
630224
+ } catch (e2) {
630225
+ bufferIncludes = legacy;
630226
+ return bufferIncludes(buffer, content5);
630227
+ }
630228
+ function modern(buffer2, content6) {
630229
+ return buffer2.includes(content6);
630230
+ }
630231
+ function legacy(buffer2, content6) {
630232
+ for (var i5 = 0; i5 <= buffer2.length - content6.length; i5++) {
630233
+ for (var j5 = 0; ; j5++) {
630234
+ if (j5 === content6.length) return true;
630235
+ if (buffer2[i5 + j5] !== content6[j5]) break;
630236
+ }
630237
+ }
630238
+ return false;
630239
+ }
630240
+ }
630241
+ }
630242
+ });
630243
+
629295
630244
  // ../../../node_modules/.pnpm/@fern-fern+docs-config@0.0.80/node_modules/@fern-fern/docs-config/api/resources/docs/types/DocsConfiguration.js
629296
630245
  var require_DocsConfiguration = __commonJS({
629297
630246
  "../../../node_modules/.pnpm/@fern-fern+docs-config@0.0.80/node_modules/@fern-fern/docs-config/api/resources/docs/types/DocsConfiguration.js"(exports2) {
@@ -692080,7 +693029,7 @@ var AccessTokenPosthogManager = class {
692080
693029
  properties: {
692081
693030
  ...event,
692082
693031
  ...event.properties,
692083
- version: "5.84.0",
693032
+ version: "5.85.0",
692084
693033
  usingAccessToken: true,
692085
693034
  ...getRunIdProperties()
692086
693035
  }
@@ -692146,7 +693095,7 @@ var UserPosthogManager = class {
692146
693095
  distinctId: this.userId ?? await this.getPersistedDistinctId(),
692147
693096
  event: "CLI",
692148
693097
  properties: {
692149
- version: "5.84.0",
693098
+ version: "5.85.0",
692150
693099
  ...event,
692151
693100
  ...event.properties,
692152
693101
  usingAccessToken: false,
@@ -850835,10 +851784,10 @@ var VFile = class {
850835
851784
  * @returns {undefined}
850836
851785
  * Nothing.
850837
851786
  */
850838
- set basename(basename7) {
850839
- assertNonEmpty(basename7, "basename");
850840
- assertPart(basename7, "basename");
850841
- this.path = import_node_path21.default.join(this.dirname || "", basename7);
851787
+ set basename(basename8) {
851788
+ assertNonEmpty(basename8, "basename");
851789
+ assertPart(basename8, "basename");
851790
+ this.path = import_node_path21.default.join(this.dirname || "", basename8);
850842
851791
  }
850843
851792
  /**
850844
851793
  * Get the parent path (example: `'~'`).
@@ -871129,8 +872078,8 @@ function isMdxParseSymptom(violation, filesWithMdxParseErrors, mdxRawMessages) {
871129
872078
  }
871130
872079
  }
871131
872080
  if (parts.length === 1) {
871132
- const basename7 = parts[0];
871133
- if (basename7 != null && violation.message.includes(basename7)) {
872081
+ const basename8 = parts[0];
872082
+ if (basename8 != null && violation.message.includes(basename8)) {
871134
872083
  return true;
871135
872084
  }
871136
872085
  }
@@ -872804,8 +873753,8 @@ var Migrator = class {
872804
873753
  return { success: true, fernYml };
872805
873754
  }
872806
873755
  async findFernDirectory() {
872807
- const basename7 = this.cwd.split("/").pop();
872808
- if (basename7 === FERN_DIRECTORY) {
873756
+ const basename8 = this.cwd.split("/").pop();
873757
+ if (basename8 === FERN_DIRECTORY) {
872809
873758
  return this.cwd;
872810
873759
  }
872811
873760
  const fernDir = join8(this.cwd, RelativeFilePath2.of(FERN_DIRECTORY));
@@ -873032,8 +873981,8 @@ function isMdxParseSymptom2(violation, filesWithMdxParseErrors, mdxRawMessages)
873032
873981
  }
873033
873982
  }
873034
873983
  if (parts.length === 1) {
873035
- const basename7 = parts[0];
873036
- if (basename7 != null && violation.message.includes(basename7)) {
873984
+ const basename8 = parts[0];
873985
+ if (basename8 != null && violation.message.includes(basename8)) {
873037
873986
  return true;
873038
873987
  }
873039
873988
  }
@@ -873252,7 +874201,7 @@ var LOCAL_STORAGE_FOLDER4 = ".fern-dev";
873252
874201
  var LOGS_FOLDER_NAME = "logs";
873253
874202
  var MAX_LOGS_DIR_SIZE_BYTES = 100 * 1024 * 1024;
873254
874203
  function getCliSource() {
873255
- const version7 = "5.84.0";
874204
+ const version7 = "5.85.0";
873256
874205
  return `cli@${version7}`;
873257
874206
  }
873258
874207
  var DebugLogger = class {
@@ -883122,8 +884071,8 @@ var CdpPage = class _CdpPage extends Page {
883122
884071
  return this.#buildMetricsObject(response.metrics);
883123
884072
  }
883124
884073
  async captureHeapSnapshot(options2) {
883125
- const { createWriteStream: createWriteStream8 } = environment.value.fs;
883126
- const stream5 = createWriteStream8(options2.path);
884074
+ const { createWriteStream: createWriteStream9 } = environment.value.fs;
884075
+ const stream5 = createWriteStream9(options2.path);
883127
884076
  const streamPromise = new Promise((resolve15, reject) => {
883128
884077
  stream5.on("error", reject);
883129
884078
  stream5.on("finish", resolve15);
@@ -905951,7 +906900,7 @@ var LegacyDocsPublisher = class {
905951
906900
  previewId,
905952
906901
  disableTemplates: void 0,
905953
906902
  skipUpload,
905954
- cliVersion: "5.84.0",
906903
+ cliVersion: "5.85.0",
905955
906904
  loginCommand: "fern auth login"
905956
906905
  });
905957
906906
  if (taskContext.getResult() === TaskResult.Failure) {
@@ -907732,9 +908681,9 @@ var Wizard = class {
907732
908681
  const defaultFilename = specFormat === "openapi" ? "openapi.yml" : "asyncapi.yml";
907733
908682
  try {
907734
908683
  const pathname = new URL(url3).pathname;
907735
- const basename7 = import_path82.default.basename(pathname);
907736
- if (basename7.includes(".")) {
907737
- return basename7;
908684
+ const basename8 = import_path82.default.basename(pathname);
908685
+ if (basename8.includes(".")) {
908686
+ return basename8;
907738
908687
  }
907739
908688
  return defaultFilename;
907740
908689
  } catch {
@@ -972826,7 +973775,7 @@ function getAutomationContextFromEnv() {
972826
973775
  config_branch: process.env.FERN_CONFIG_BRANCH,
972827
973776
  config_pr_number: process.env.FERN_CONFIG_PR_NUMBER,
972828
973777
  trigger: process.env.GITHUB_EVENT_NAME,
972829
- cli_version: "5.84.0"
973778
+ cli_version: "5.85.0"
972830
973779
  };
972831
973780
  }
972832
973781
  function isAutomationMode() {
@@ -973658,7 +974607,7 @@ var CliContext = class _CliContext {
973658
974607
  if (false) {
973659
974608
  this.logger.error("CLI_VERSION is not defined");
973660
974609
  }
973661
- return "5.84.0";
974610
+ return "5.85.0";
973662
974611
  }
973663
974612
  getCliName() {
973664
974613
  if (false) {
@@ -975450,7 +976399,10 @@ init_esm19();
975450
976399
  init_lib4();
975451
976400
  init_lib8();
975452
976401
  init_lib33();
976402
+ var import_fs41 = require("fs");
975453
976403
  var import_promises168 = require("fs/promises");
976404
+ var import_path110 = require("path");
976405
+ var import_yazl = __toESM(require_yazl(), 1);
975454
976406
  var PACK_OUTPUT_DIRECTORY = "fern-dist";
975455
976407
  var PACK_DOCKER_IMAGES = {
975456
976408
  typescript: "node:22",
@@ -975566,11 +976518,16 @@ async function packOutputForLanguage({
975566
976518
  logArtifacts({ distDir, context: context3 });
975567
976519
  return;
975568
976520
  }
975569
- case "go":
975570
- context3.logger.warn(
975571
- "Go SDKs are distributed as source modules, so there is no package artifact to build. Share the output directory itself (e.g. as a zip), or reference it with a 'replace' directive in go.mod."
975572
- );
976521
+ case "go": {
976522
+ await (0, import_promises168.mkdir)(distDir, { recursive: true });
976523
+ const zipName = `${(0, import_path110.basename)(outputPath)}-source.zip`;
976524
+ await zipDirectory({
976525
+ sourceDir: outputPath,
976526
+ zipPath: join8(distDir, RelativeFilePath2.of(zipName))
976527
+ });
976528
+ logArtifacts({ distDir, context: context3 });
975573
976529
  return;
976530
+ }
975574
976531
  case "swift":
975575
976532
  context3.logger.warn(
975576
976533
  "Swift SDKs are distributed as source packages (Swift Package Manager), so there is no package artifact to build. Share the output directory itself, or reference it as a local package dependency."
@@ -975613,6 +976570,32 @@ async function runPackCommands({
975613
976570
  });
975614
976571
  }
975615
976572
  }
976573
+ async function zipDirectory({
976574
+ sourceDir,
976575
+ zipPath
976576
+ }) {
976577
+ const zip = new import_yazl.ZipFile();
976578
+ const addEntries = async (dir, prefix2) => {
976579
+ for (const entry of await (0, import_promises168.readdir)(dir, { withFileTypes: true })) {
976580
+ if (prefix2 === "" && (entry.name === PACK_OUTPUT_DIRECTORY || entry.name === ".git")) {
976581
+ continue;
976582
+ }
976583
+ const entryPath = join8(dir, RelativeFilePath2.of(entry.name));
976584
+ const entryName = prefix2 === "" ? entry.name : `${prefix2}/${entry.name}`;
976585
+ if (entry.isDirectory()) {
976586
+ await addEntries(entryPath, entryName);
976587
+ } else if (entry.isFile()) {
976588
+ zip.addFile(entryPath, entryName);
976589
+ }
976590
+ }
976591
+ };
976592
+ await addEntries(sourceDir, "");
976593
+ zip.end();
976594
+ await new Promise((resolve15, reject) => {
976595
+ zip.outputStream.on("error", reject);
976596
+ zip.outputStream.pipe((0, import_fs41.createWriteStream)(zipPath)).on("close", resolve15).on("error", reject);
976597
+ });
976598
+ }
975616
976599
  async function removeDistDirIfEmpty(outputPath) {
975617
976600
  const distDir = join8(outputPath, RelativeFilePath2.of(PACK_OUTPUT_DIRECTORY));
975618
976601
  try {
@@ -976640,7 +977623,7 @@ function renderOverflowWarning(failureCount) {
976640
977623
 
976641
977624
  // src/commands/automations/generate/reportGenerateResults.ts
976642
977625
  init_lib4();
976643
- var import_fs41 = require("fs");
977626
+ var import_fs42 = require("fs");
976644
977627
  var import_promises169 = require("fs/promises");
976645
977628
  var JSON_SCHEMA_VERSION = 1;
976646
977629
  function renderStdoutSummary(results) {
@@ -976846,13 +977829,13 @@ function writeResultsSync({
976846
977829
  const stepSummaryPath = getGithubStepSummaryPath();
976847
977830
  if (stepSummaryPath != null) {
976848
977831
  try {
976849
- (0, import_fs41.appendFileSync)(stepSummaryPath, renderMarkdownSummary(results), "utf8");
977832
+ (0, import_fs42.appendFileSync)(stepSummaryPath, renderMarkdownSummary(results), "utf8");
976850
977833
  } catch {
976851
977834
  }
976852
977835
  }
976853
977836
  if (jsonOutputPath != null) {
976854
977837
  try {
976855
- (0, import_fs41.writeFileSync)(jsonOutputPath, JSON.stringify(renderJsonSummary(results), null, 2), "utf8");
977838
+ (0, import_fs42.writeFileSync)(jsonOutputPath, JSON.stringify(renderJsonSummary(results), null, 2), "utf8");
976856
977839
  } catch {
976857
977840
  }
976858
977841
  }
@@ -983335,7 +984318,7 @@ init_lib12();
983335
984318
  init_lib8();
983336
984319
  var import_promises201 = require("fs/promises");
983337
984320
  init_js_yaml();
983338
- var import_path110 = __toESM(require("path"), 1);
984321
+ var import_path111 = __toESM(require("path"), 1);
983339
984322
  var ThemeExporter = class {
983340
984323
  constructor(docsWorkspace) {
983341
984324
  this.docsWorkspace = docsWorkspace;
@@ -983343,8 +984326,8 @@ var ThemeExporter = class {
983343
984326
  docsWorkspace;
983344
984327
  async export({ output: output2, context: context3 }) {
983345
984328
  const docsYmlPath = this.docsWorkspace.absoluteFilepathToDocsConfig;
983346
- const docsDir = import_path110.default.dirname(docsYmlPath);
983347
- const outDir = output2 != null ? import_path110.default.resolve(process.cwd(), output2) : import_path110.default.join(this.docsWorkspace.absoluteFilePath, "theme");
984329
+ const docsDir = import_path111.default.dirname(docsYmlPath);
984330
+ const outDir = output2 != null ? import_path111.default.resolve(process.cwd(), output2) : import_path111.default.join(this.docsWorkspace.absoluteFilePath, "theme");
983348
984331
  context3.logger.info(`Exporting theme-eligible fields from docs.yml \u2192 ${outDir}`);
983349
984332
  const raw = index_vite_proxy_tmp_default.load(await (0, import_promises201.readFile)(docsYmlPath, "utf-8"));
983350
984333
  const themeConfig = {};
@@ -983354,26 +984337,26 @@ var ThemeExporter = class {
983354
984337
  }
983355
984338
  }
983356
984339
  await (0, import_promises201.mkdir)(outDir, { recursive: true });
983357
- const assetsDir = import_path110.default.join(outDir, "assets");
984340
+ const assetsDir = import_path111.default.join(outDir, "assets");
983358
984341
  await (0, import_promises201.mkdir)(assetsDir, { recursive: true });
983359
984342
  const exported = await copyLocalFiles(themeConfig, docsDir, assetsDir);
983360
- await (0, import_promises201.writeFile)(import_path110.default.join(outDir, "theme.yml"), index_vite_proxy_tmp_default.dump(exported), "utf-8");
984343
+ await (0, import_promises201.writeFile)(import_path111.default.join(outDir, "theme.yml"), index_vite_proxy_tmp_default.dump(exported), "utf-8");
983361
984344
  context3.logger.info(`Theme exported to ${outDir}/theme.yml`);
983362
984345
  }
983363
984346
  };
983364
984347
  async function copyLocalFiles(obj, sourceDir, assetsDir) {
983365
984348
  if (obj === null || typeof obj !== "object") {
983366
984349
  if (typeof obj === "string" && !isURL(obj)) {
983367
- const abs = import_path110.default.resolve(sourceDir, obj);
983368
- const relFromSource = import_path110.default.relative(sourceDir, abs);
983369
- const projectRoot = import_path110.default.dirname(sourceDir);
983370
- const relFromProject = import_path110.default.relative(projectRoot, abs);
983371
- const destRelative = relFromSource.startsWith("..") ? relFromProject.startsWith("..") ? import_path110.default.basename(abs) : relFromProject : relFromSource;
983372
- const dest = import_path110.default.join(assetsDir, destRelative);
984350
+ const abs = import_path111.default.resolve(sourceDir, obj);
984351
+ const relFromSource = import_path111.default.relative(sourceDir, abs);
984352
+ const projectRoot = import_path111.default.dirname(sourceDir);
984353
+ const relFromProject = import_path111.default.relative(projectRoot, abs);
984354
+ const destRelative = relFromSource.startsWith("..") ? relFromProject.startsWith("..") ? import_path111.default.basename(abs) : relFromProject : relFromSource;
984355
+ const dest = import_path111.default.join(assetsDir, destRelative);
983373
984356
  try {
983374
- await (0, import_promises201.mkdir)(import_path110.default.dirname(dest), { recursive: true });
984357
+ await (0, import_promises201.mkdir)(import_path111.default.dirname(dest), { recursive: true });
983375
984358
  await (0, import_promises201.copyFile)(abs, dest);
983376
- return `./assets/${destRelative.split(import_path110.default.sep).join("/")}`;
984359
+ return `./assets/${destRelative.split(import_path111.default.sep).join("/")}`;
983377
984360
  } catch {
983378
984361
  return obj;
983379
984362
  }
@@ -983466,7 +984449,7 @@ async function listDocsThemes({
983466
984449
  init_lib6();
983467
984450
  var import_promises203 = require("fs/promises");
983468
984451
  init_js_yaml();
983469
- var import_path112 = __toESM(require("path"), 1);
984452
+ var import_path113 = __toESM(require("path"), 1);
983470
984453
 
983471
984454
  // src/commands/docs-theme/ThemeConfigProcessor.ts
983472
984455
  init_lib8();
@@ -983475,7 +984458,7 @@ var import_child_process13 = require("child_process");
983475
984458
  var import_crypto10 = require("crypto");
983476
984459
  var import_promises202 = require("fs/promises");
983477
984460
  var import_mime_types2 = __toESM(require_mime_types(), 1);
983478
- var import_path111 = __toESM(require("path"), 1);
984461
+ var import_path112 = __toESM(require("path"), 1);
983479
984462
  function getGitRoot() {
983480
984463
  try {
983481
984464
  return (0, import_child_process13.execSync)("git rev-parse --show-toplevel", { encoding: "utf-8" }).trim();
@@ -983484,9 +984467,9 @@ function getGitRoot() {
983484
984467
  }
983485
984468
  }
983486
984469
  function posixBindPath(gitRoot, absolutePath) {
983487
- const repoName = import_path111.default.basename(gitRoot);
983488
- const relative6 = import_path111.default.relative(gitRoot, absolutePath);
983489
- return [repoName, ...relative6.split(import_path111.default.sep)].join("/");
984470
+ const repoName = import_path112.default.basename(gitRoot);
984471
+ const relative6 = import_path112.default.relative(gitRoot, absolutePath);
984472
+ return [repoName, ...relative6.split(import_path112.default.sep)].join("/");
983490
984473
  }
983491
984474
  var ThemeConfigProcessor = class {
983492
984475
  themeDir;
@@ -983500,7 +984483,7 @@ var ThemeConfigProcessor = class {
983500
984483
  token,
983501
984484
  context: context3
983502
984485
  }) {
983503
- this.themeDir = import_path111.default.join(docsWorkspace.absoluteFilePath, "theme");
984486
+ this.themeDir = import_path112.default.join(docsWorkspace.absoluteFilePath, "theme");
983504
984487
  this.orgId = orgId;
983505
984488
  this.token = token;
983506
984489
  this.gitRoot = getGitRoot();
@@ -983515,7 +984498,7 @@ var ThemeConfigProcessor = class {
983515
984498
  const errors4 = [];
983516
984499
  await Promise.all(
983517
984500
  filePaths.map(async (filePath) => {
983518
- const abs = import_path111.default.resolve(this.themeDir, filePath);
984501
+ const abs = import_path112.default.resolve(this.themeDir, filePath);
983519
984502
  try {
983520
984503
  await (0, import_promises202.access)(abs);
983521
984504
  } catch {
@@ -983602,7 +984585,7 @@ ${errors4.map((e2) => ` - ${e2}`).join("\n")}`,
983602
984585
  if (isURL(value2)) {
983603
984586
  return value2;
983604
984587
  }
983605
- const abs = import_path111.default.resolve(this.themeDir, value2);
984588
+ const abs = import_path112.default.resolve(this.themeDir, value2);
983606
984589
  this.context.logger.debug(` Uploading ${value2}...`);
983607
984590
  const hash5 = await this.uploadFileToCas(abs);
983608
984591
  filesUploaded++;
@@ -983685,7 +984668,7 @@ ${errors4.map((e2) => ` - ${e2}`).join("\n")}`,
983685
984668
  const content5 = await (0, import_promises202.readFile)(absolutePath);
983686
984669
  const contentType = import_mime_types2.default.lookup(absolutePath) || "application/octet-stream";
983687
984670
  const bindPath = posixBindPath(this.gitRoot, absolutePath);
983688
- return this.uploadToCas(content5, contentType, bindPath, import_path111.default.basename(absolutePath));
984671
+ return this.uploadToCas(content5, contentType, bindPath, import_path112.default.basename(absolutePath));
983689
984672
  }
983690
984673
  async uploadToCas(content5, contentType, bindPath, label) {
983691
984674
  const hash5 = (0, import_crypto10.createHash)("sha256").update(content5).digest("hex");
@@ -983793,7 +984776,7 @@ async function uploadDocsTheme({
983793
984776
  return;
983794
984777
  }
983795
984778
  const orgId = org ?? project.config.organization;
983796
- const themeYmlPath = import_path112.default.join(docsWorkspace.absoluteFilePath, "theme", "theme.yml");
984779
+ const themeYmlPath = import_path113.default.join(docsWorkspace.absoluteFilePath, "theme", "theme.yml");
983797
984780
  await cliContext.runTask(async (context3) => {
983798
984781
  let rawYaml;
983799
984782
  try {
@@ -985640,7 +986623,7 @@ function summarizeValidationErrors(errors4) {
985640
986623
  // src/commands/generate-dynamic-ir/generateDynamicIrForWorkspaces.ts
985641
986624
  init_lib8();
985642
986625
  init_lib6();
985643
- var import_path113 = __toESM(require("path"), 1);
986626
+ var import_path114 = __toESM(require("path"), 1);
985644
986627
 
985645
986628
  // src/commands/generate-ir/generateIrForFernWorkspace.ts
985646
986629
  init_lib36();
@@ -985707,7 +986690,7 @@ async function generateDynamicIrForWorkspaces({
985707
986690
  code: CliError.Code.InternalError
985708
986691
  });
985709
986692
  }
985710
- const irOutputFilePath = import_path113.default.resolve(irFilepath);
986693
+ const irOutputFilePath = import_path114.default.resolve(irFilepath);
985711
986694
  await streamObjectToFile(AbsoluteFilePath2.of(irOutputFilePath), intermediateRepresentation.dynamic);
985712
986695
  context3.logger.info(`Wrote IR to ${irOutputFilePath}`);
985713
986696
  });
@@ -985718,7 +986701,7 @@ async function generateDynamicIrForWorkspaces({
985718
986701
  // src/commands/generate-fdr/generateFdrApiDefinitionForWorkspaces.ts
985719
986702
  init_lib8();
985720
986703
  init_lib66();
985721
- var import_path114 = __toESM(require("path"), 1);
986704
+ var import_path115 = __toESM(require("path"), 1);
985722
986705
  async function generateFdrApiDefinitionForWorkspaces({
985723
986706
  project,
985724
986707
  outputFilepath,
@@ -985755,7 +986738,7 @@ async function generateFdrApiDefinitionForWorkspaces({
985755
986738
  },
985756
986739
  context: context3
985757
986740
  });
985758
- const resolvedOutputFilePath = AbsoluteFilePath2.of(import_path114.default.resolve(outputFilepath));
986741
+ const resolvedOutputFilePath = AbsoluteFilePath2.of(import_path115.default.resolve(outputFilepath));
985759
986742
  await streamObjectToFile(resolvedOutputFilePath, apiDefinition, { pretty: true });
985760
986743
  context3.logger.info(`Wrote FDR API definition to ${resolvedOutputFilePath}`);
985761
986744
  });
@@ -985767,7 +986750,7 @@ async function generateFdrApiDefinitionForWorkspaces({
985767
986750
  init_lib8();
985768
986751
  init_lib9();
985769
986752
  init_lib35();
985770
- var import_path115 = __toESM(require("path"), 1);
986753
+ var import_path116 = __toESM(require("path"), 1);
985771
986754
  async function generateIrForWorkspaces({
985772
986755
  project,
985773
986756
  irFilepath,
@@ -985797,7 +986780,7 @@ async function generateIrForWorkspaces({
985797
986780
  readme,
985798
986781
  directFromOpenapi
985799
986782
  });
985800
- const irOutputFilePath = AbsoluteFilePath2.of(import_path115.default.resolve(irFilepath));
986783
+ const irOutputFilePath = AbsoluteFilePath2.of(import_path116.default.resolve(irFilepath));
985801
986784
  await streamObjectToFile(irOutputFilePath, intermediateRepresentation, { pretty: true });
985802
986785
  context3.logger.info(`Wrote IR to ${irOutputFilePath}`);
985803
986786
  });
@@ -985854,7 +986837,7 @@ async function getIntermediateRepresentation2({
985854
986837
  // src/commands/generate-openapi-fdr/generateOpenApiToFdrApiDefinitionForWorkspaces.ts
985855
986838
  init_lib67();
985856
986839
  init_lib8();
985857
- var import_path116 = __toESM(require("path"), 1);
986840
+ var import_path117 = __toESM(require("path"), 1);
985858
986841
  async function generateOpenApiToFdrApiDefinitionForWorkspaces({
985859
986842
  project,
985860
986843
  outputFilepath,
@@ -985865,7 +986848,7 @@ async function generateOpenApiToFdrApiDefinitionForWorkspaces({
985865
986848
  project.apiWorkspaces.map(async (workspace) => {
985866
986849
  await cliContext.runTaskForWorkspace(workspace, async (context3) => {
985867
986850
  const fdrApiDefinition = await generateFdrFromOpenApiWorkspaceV3(workspace, context3, audiences);
985868
- const resolvedOutputFilePath = AbsoluteFilePath2.of(import_path116.default.resolve(outputFilepath));
986851
+ const resolvedOutputFilePath = AbsoluteFilePath2.of(import_path117.default.resolve(outputFilepath));
985869
986852
  await streamObjectToFile(resolvedOutputFilePath, fdrApiDefinition, { pretty: true });
985870
986853
  context3.logger.info(`Wrote FDR API definition to ${resolvedOutputFilePath}`);
985871
986854
  });
@@ -985878,7 +986861,7 @@ init_lib8();
985878
986861
  init_lib35();
985879
986862
  init_lib13();
985880
986863
  init_lib16();
985881
- var import_path117 = __toESM(require("path"), 1);
986864
+ var import_path118 = __toESM(require("path"), 1);
985882
986865
  async function generateOpenAPIIrForWorkspaces({
985883
986866
  project,
985884
986867
  irFilepath,
@@ -985900,7 +986883,7 @@ async function generateOpenAPIIrForWorkspaces({
985900
986883
  context: context3,
985901
986884
  documents: await openAPILoader.loadDocuments({ context: context3, specs: openAPISpecs })
985902
986885
  });
985903
- const irOutputFilePath = AbsoluteFilePath2.of(import_path117.default.resolve(irFilepath));
986886
+ const irOutputFilePath = AbsoluteFilePath2.of(import_path118.default.resolve(irFilepath));
985904
986887
  const openApiIrJson = serialization_exports5.OpenApiIntermediateRepresentation.jsonOrThrow(openAPIIr, {
985905
986888
  skipValidation: true
985906
986889
  });
@@ -987532,7 +988515,7 @@ init_lib6();
987532
988515
  init_esm19();
987533
988516
  init_axios2();
987534
988517
  var import_promises210 = require("fs/promises");
987535
- var import_path118 = __toESM(require("path"), 1);
988518
+ var import_path119 = __toESM(require("path"), 1);
987536
988519
  init_index_min2();
987537
988520
  var import_tmp_promise21 = __toESM(require_tmp_promise(), 1);
987538
988521
  async function registerWorkspacesV1({
@@ -987581,7 +988564,7 @@ async function registerWorkspacesV1({
987581
988564
  return;
987582
988565
  }
987583
988566
  const tmpDir = await import_tmp_promise21.default.dir();
987584
- const tarPath = import_path118.default.join(tmpDir.path, "definition.tgz");
988567
+ const tarPath = import_path119.default.join(tmpDir.path, "definition.tgz");
987585
988568
  context3.logger.debug(`Compressing definition at ${tmpDir.path}`);
987586
988569
  await Kn({ file: tarPath, cwd: resolvedWorkspace.absoluteFilePath }, ["."]);
987587
988570
  context3.logger.info("Uploading definition...");
@@ -987643,7 +988626,7 @@ function getAIEnhancerConfig2() {
987643
988626
  init_lib8();
987644
988627
  init_lib35();
987645
988628
  var import_promises211 = require("fs/promises");
987646
- var import_path119 = __toESM(require("path"), 1);
988629
+ var import_path120 = __toESM(require("path"), 1);
987647
988630
  async function resolveSpecsForWorkspaces({
987648
988631
  project,
987649
988632
  outputDir,
@@ -987661,7 +988644,7 @@ async function resolveSpecsForWorkspaces({
987661
988644
  context3.logger.info("No specs found.");
987662
988645
  return;
987663
988646
  }
987664
- const workspaceOutputDir = project.apiWorkspaces.length > 1 ? AbsoluteFilePath2.of(import_path119.default.join(outputDir, workspace.workspaceName ?? "api")) : outputDir;
988647
+ const workspaceOutputDir = project.apiWorkspaces.length > 1 ? AbsoluteFilePath2.of(import_path120.default.join(outputDir, workspace.workspaceName ?? "api")) : outputDir;
987665
988648
  await (0, import_promises211.mkdir)(workspaceOutputDir, { recursive: true });
987666
988649
  const manifest = await collectRawSpecs({
987667
988650
  specs,
@@ -987670,7 +988653,7 @@ async function resolveSpecsForWorkspaces({
987670
988653
  context: context3
987671
988654
  });
987672
988655
  await (0, import_promises211.writeFile)(
987673
- import_path119.default.join(workspaceOutputDir, SPECS_MANIFEST_FILENAME),
988656
+ import_path120.default.join(workspaceOutputDir, SPECS_MANIFEST_FILENAME),
987674
988657
  JSON.stringify(manifest, void 0, 4)
987675
988658
  );
987676
988659
  context3.logger.info(`Resolved ${manifest.specs.length} spec(s) to ${workspaceOutputDir}`);
@@ -988190,7 +989173,7 @@ init_lib33();
988190
989173
  init_lib6();
988191
989174
  init_source();
988192
989175
  var import_promises213 = require("fs/promises");
988193
- var import_path120 = require("path");
989176
+ var import_path121 = require("path");
988194
989177
  async function getPackageManagerBinDir(logger4, pm) {
988195
989178
  let command3;
988196
989179
  let args;
@@ -988269,16 +989252,16 @@ async function detectInstallationMethod(logger4) {
988269
989252
  }
988270
989253
  }
988271
989254
  }
988272
- const fernDir = (0, import_path120.dirname)(resolvedPath);
989255
+ const fernDir = (0, import_path121.dirname)(resolvedPath);
988273
989256
  logger4.debug(`fern directory: ${fernDir}`);
988274
989257
  const packageManagers = ["pnpm", "yarn", "bun", "npm"];
988275
989258
  for (const pm of packageManagers) {
988276
989259
  const binDir = await getPackageManagerBinDir(logger4, pm);
988277
989260
  if (binDir != null) {
988278
989261
  logger4.debug(`${pm} bin dir: ${binDir}`);
988279
- const normalizedFernDir = (0, import_path120.normalize)(fernDir);
988280
- const normalizedBinDir = (0, import_path120.normalize)(binDir);
988281
- if (normalizedFernDir === normalizedBinDir || normalizedFernDir.startsWith(normalizedBinDir + import_path120.sep) || normalizedFernDir.startsWith(normalizedBinDir + "/") || normalizedFernDir.startsWith(normalizedBinDir + "\\")) {
989262
+ const normalizedFernDir = (0, import_path121.normalize)(fernDir);
989263
+ const normalizedBinDir = (0, import_path121.normalize)(binDir);
989264
+ if (normalizedFernDir === normalizedBinDir || normalizedFernDir.startsWith(normalizedBinDir + import_path121.sep) || normalizedFernDir.startsWith(normalizedBinDir + "/") || normalizedFernDir.startsWith(normalizedBinDir + "\\")) {
988282
989265
  return {
988283
989266
  type: pm,
988284
989267
  command: pm,
@@ -988288,8 +989271,8 @@ async function detectInstallationMethod(logger4) {
988288
989271
  }
988289
989272
  }
988290
989273
  }
988291
- const normalizedPath = (0, import_path120.normalize)(resolvedPath);
988292
- if (normalizedPath.includes(".pnpm") || normalizedPath.includes("pnpm-global") || normalizedPath.includes(`${import_path120.sep}pnpm${import_path120.sep}`) || normalizedPath.includes("/pnpm/") || normalizedPath.includes("\\pnpm\\")) {
989274
+ const normalizedPath = (0, import_path121.normalize)(resolvedPath);
989275
+ if (normalizedPath.includes(".pnpm") || normalizedPath.includes("pnpm-global") || normalizedPath.includes(`${import_path121.sep}pnpm${import_path121.sep}`) || normalizedPath.includes("/pnpm/") || normalizedPath.includes("\\pnpm\\")) {
988293
989276
  return {
988294
989277
  type: "pnpm",
988295
989278
  command: "pnpm",
@@ -988297,7 +989280,7 @@ async function detectInstallationMethod(logger4) {
988297
989280
  resolvedPath
988298
989281
  };
988299
989282
  }
988300
- if (normalizedPath.includes(`${import_path120.sep}.yarn${import_path120.sep}`) || normalizedPath.includes(`${import_path120.sep}yarn${import_path120.sep}`) || normalizedPath.includes("/.yarn/") || normalizedPath.includes("/yarn/") || normalizedPath.includes("\\.yarn\\") || normalizedPath.includes("\\yarn\\")) {
989283
+ if (normalizedPath.includes(`${import_path121.sep}.yarn${import_path121.sep}`) || normalizedPath.includes(`${import_path121.sep}yarn${import_path121.sep}`) || normalizedPath.includes("/.yarn/") || normalizedPath.includes("/yarn/") || normalizedPath.includes("\\.yarn\\") || normalizedPath.includes("\\yarn\\")) {
988301
989284
  return {
988302
989285
  type: "yarn",
988303
989286
  command: "yarn",
@@ -988305,7 +989288,7 @@ async function detectInstallationMethod(logger4) {
988305
989288
  resolvedPath
988306
989289
  };
988307
989290
  }
988308
- if (normalizedPath.includes(`${import_path120.sep}.bun${import_path120.sep}`) || normalizedPath.includes(`${import_path120.sep}bun${import_path120.sep}`) || normalizedPath.includes("/.bun/") || normalizedPath.includes("/bun/") || normalizedPath.includes("\\.bun\\") || normalizedPath.includes("\\bun\\")) {
989291
+ if (normalizedPath.includes(`${import_path121.sep}.bun${import_path121.sep}`) || normalizedPath.includes(`${import_path121.sep}bun${import_path121.sep}`) || normalizedPath.includes("/.bun/") || normalizedPath.includes("/bun/") || normalizedPath.includes("\\.bun\\") || normalizedPath.includes("\\bun\\")) {
988309
989292
  return {
988310
989293
  type: "bun",
988311
989294
  command: "bun",
@@ -988313,7 +989296,7 @@ async function detectInstallationMethod(logger4) {
988313
989296
  resolvedPath
988314
989297
  };
988315
989298
  }
988316
- if (normalizedPath.includes(`${import_path120.sep}lib${import_path120.sep}node_modules${import_path120.sep}`) || normalizedPath.includes(`${import_path120.sep}node_modules${import_path120.sep}`) || normalizedPath.includes("/lib/node_modules/") || normalizedPath.includes("/node_modules/") || normalizedPath.includes("\\lib\\node_modules\\") || normalizedPath.includes("\\node_modules\\")) {
989299
+ if (normalizedPath.includes(`${import_path121.sep}lib${import_path121.sep}node_modules${import_path121.sep}`) || normalizedPath.includes(`${import_path121.sep}node_modules${import_path121.sep}`) || normalizedPath.includes("/lib/node_modules/") || normalizedPath.includes("/node_modules/") || normalizedPath.includes("\\lib\\node_modules\\") || normalizedPath.includes("\\node_modules\\")) {
988317
989300
  return {
988318
989301
  type: "npm",
988319
989302
  command: "npm",
@@ -988327,7 +989310,7 @@ async function detectInstallationMethod(logger4) {
988327
989310
  }
988328
989311
  logger4.debug(` - Package manager bin directories checked: pnpm, yarn, bun, npm (none matched)`);
988329
989312
  logger4.debug(
988330
- ` - Path patterns checked: .pnpm, pnpm-global, ${import_path120.sep}pnpm${import_path120.sep}, .yarn, ${import_path120.sep}yarn${import_path120.sep}, .bun, ${import_path120.sep}bun${import_path120.sep}, ${import_path120.sep}node_modules${import_path120.sep}`
989313
+ ` - Path patterns checked: .pnpm, pnpm-global, ${import_path121.sep}pnpm${import_path121.sep}, .yarn, ${import_path121.sep}yarn${import_path121.sep}, .bun, ${import_path121.sep}bun${import_path121.sep}, ${import_path121.sep}node_modules${import_path121.sep}`
988331
989314
  );
988332
989315
  logger4.debug(` - Resolved path: ${resolvedPath}`);
988333
989316
  logger4.debug(` - Directory: ${fernDir}`);
@@ -988874,9 +989857,9 @@ async function validateDocsBrokenLinks({
988874
989857
  init_lib19();
988875
989858
  init_lib64();
988876
989859
  init_source();
988877
- var import_fs42 = require("fs");
989860
+ var import_fs43 = require("fs");
988878
989861
  var import_gray_matter12 = __toESM(require_gray_matter(), 1);
988879
- var import_path121 = __toESM(require("path"), 1);
989862
+ var import_path122 = __toESM(require("path"), 1);
988880
989863
  function calculateVisualColumn(text9, charIndex, tabWidth = 4) {
988881
989864
  let visualColumn = 0;
988882
989865
  for (let i5 = 0; i5 < Math.min(charIndex, text9.length); i5++) {
@@ -988898,7 +989881,7 @@ var MdxValidationError = class {
988898
989881
  column;
988899
989882
  contextLines;
988900
989883
  toString() {
988901
- const relativePath = import_path121.default.relative(process.cwd(), this.filepath);
989884
+ const relativePath = import_path122.default.relative(process.cwd(), this.filepath);
988902
989885
  let formatted = source_default.red(` ${relativePath}`);
988903
989886
  if (this.line != null) {
988904
989887
  formatted += source_default.yellow(`:${this.line}`);
@@ -988950,7 +989933,7 @@ async function validateMdxFiles({
988950
989933
  });
988951
989934
  const filesToCheck = Array.from(new Set(allPages));
988952
989935
  for (const filepath of filesToCheck) {
988953
- const content5 = (0, import_fs42.readFileSync)(filepath, "utf-8");
989936
+ const content5 = (0, import_fs43.readFileSync)(filepath, "utf-8");
988954
989937
  try {
988955
989938
  parseMarkdownToTree(content5);
988956
989939
  } catch (error50) {
@@ -989439,7 +990422,7 @@ init_lib8();
989439
990422
  init_source();
989440
990423
  var import_promises216 = require("fs/promises");
989441
990424
  init_js_yaml();
989442
- var import_path122 = __toESM(require("path"), 1);
990425
+ var import_path123 = __toESM(require("path"), 1);
989443
990426
  async function writeDefinitionForWorkspaces({
989444
990427
  project,
989445
990428
  cliContext,
@@ -989477,7 +990460,7 @@ async function writeDefinitionForFernWorkspace({
989477
990460
  absolutePathToOutputDirectory
989478
990461
  });
989479
990462
  context3.logger.info(
989480
- source_default.green(`Wrote imported definition at ${import_path122.default.relative(process.cwd(), absolutePathToOutputDirectory)}`)
990463
+ source_default.green(`Wrote imported definition at ${import_path123.default.relative(process.cwd(), absolutePathToOutputDirectory)}`)
989481
990464
  );
989482
990465
  }
989483
990466
  }
@@ -989494,7 +990477,7 @@ async function writeDefinitionForNonFernWorkspace({
989494
990477
  absolutePathToOutputDirectory
989495
990478
  });
989496
990479
  context3.logger.info(
989497
- source_default.green(`Wrote definition to ${import_path122.default.relative(process.cwd(), absolutePathToOutputDirectory)}`)
990480
+ source_default.green(`Wrote definition to ${import_path123.default.relative(process.cwd(), absolutePathToOutputDirectory)}`)
989498
990481
  );
989499
990482
  }
989500
990483
  async function writeFernDefinition({