@fern-api/fern-api-dev 4.63.1-2-g7eec44a362b → 4.63.2-1-gcc2932efdb5
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/cli.cjs +187 -139
- package/package.json +1 -1
package/cli.cjs
CHANGED
|
@@ -24181,11 +24181,11 @@ var init_dirname2 = __esm({
|
|
|
24181
24181
|
// ../../commons/fs-utils/lib/doesPathExist.js
|
|
24182
24182
|
async function isPathEmpty(filepath) {
|
|
24183
24183
|
try {
|
|
24184
|
-
const
|
|
24185
|
-
if (
|
|
24186
|
-
return
|
|
24184
|
+
const stat7 = await (0, import_promises.lstat)(filepath);
|
|
24185
|
+
if (stat7.isFile()) {
|
|
24186
|
+
return stat7.size === 0;
|
|
24187
24187
|
}
|
|
24188
|
-
if (
|
|
24188
|
+
if (stat7.isDirectory()) {
|
|
24189
24189
|
const entries22 = await (0, import_promises.readdir)(filepath);
|
|
24190
24190
|
return entries22.length === 0;
|
|
24191
24191
|
}
|
|
@@ -24196,11 +24196,11 @@ async function isPathEmpty(filepath) {
|
|
|
24196
24196
|
}
|
|
24197
24197
|
async function doesPathExist(filepath, mode) {
|
|
24198
24198
|
try {
|
|
24199
|
-
const
|
|
24200
|
-
if (mode === "file" && !
|
|
24199
|
+
const stat7 = await (0, import_promises.lstat)(filepath);
|
|
24200
|
+
if (mode === "file" && !stat7.isFile()) {
|
|
24201
24201
|
return false;
|
|
24202
24202
|
}
|
|
24203
|
-
if (mode === "directory" && !
|
|
24203
|
+
if (mode === "directory" && !stat7.isDirectory()) {
|
|
24204
24204
|
return false;
|
|
24205
24205
|
}
|
|
24206
24206
|
return true;
|
|
@@ -24210,11 +24210,11 @@ async function doesPathExist(filepath, mode) {
|
|
|
24210
24210
|
}
|
|
24211
24211
|
function doesPathExistSync(filepath, mode) {
|
|
24212
24212
|
try {
|
|
24213
|
-
const
|
|
24214
|
-
if (mode === "file" && !
|
|
24213
|
+
const stat7 = (0, import_fs5.lstatSync)(filepath);
|
|
24214
|
+
if (mode === "file" && !stat7.isFile()) {
|
|
24215
24215
|
return false;
|
|
24216
24216
|
}
|
|
24217
|
-
if (mode === "directory" && !
|
|
24217
|
+
if (mode === "directory" && !stat7.isDirectory()) {
|
|
24218
24218
|
return false;
|
|
24219
24219
|
}
|
|
24220
24220
|
return true;
|
|
@@ -34119,12 +34119,12 @@ var require_src2 = __commonJS({
|
|
|
34119
34119
|
function check3(path97, isFile3, isDirectory) {
|
|
34120
34120
|
log4(`checking %s`, path97);
|
|
34121
34121
|
try {
|
|
34122
|
-
const
|
|
34123
|
-
if (
|
|
34122
|
+
const stat7 = fs_1.statSync(path97);
|
|
34123
|
+
if (stat7.isFile() && isFile3) {
|
|
34124
34124
|
log4(`[OK] path represents a file`);
|
|
34125
34125
|
return true;
|
|
34126
34126
|
}
|
|
34127
|
-
if (
|
|
34127
|
+
if (stat7.isDirectory() && isDirectory) {
|
|
34128
34128
|
log4(`[OK] path represents a directory`);
|
|
34129
34129
|
return true;
|
|
34130
34130
|
}
|
|
@@ -48729,9 +48729,9 @@ var require_graceful_fs = __commonJS({
|
|
|
48729
48729
|
}
|
|
48730
48730
|
}
|
|
48731
48731
|
var fs$readdir = fs29.readdir;
|
|
48732
|
-
fs29.readdir =
|
|
48732
|
+
fs29.readdir = readdir21;
|
|
48733
48733
|
var noReaddirOptionVersions = /^v[0-5]\./;
|
|
48734
|
-
function
|
|
48734
|
+
function readdir21(path97, options2, cb2) {
|
|
48735
48735
|
if (typeof options2 === "function")
|
|
48736
48736
|
cb2 = options2, options2 = null;
|
|
48737
48737
|
var go$readdir = noReaddirOptionVersions.test(process.version) ? function go$readdir2(path98, options3, cb3, startTime) {
|
|
@@ -192551,12 +192551,12 @@ var require_form_data = __commonJS({
|
|
|
192551
192551
|
if (value.end != void 0 && value.end != Infinity && value.start != void 0) {
|
|
192552
192552
|
callback(null, value.end + 1 - (value.start ? value.start : 0));
|
|
192553
192553
|
} else {
|
|
192554
|
-
fs28.stat(value.path, function(err,
|
|
192554
|
+
fs28.stat(value.path, function(err, stat7) {
|
|
192555
192555
|
if (err) {
|
|
192556
192556
|
callback(err);
|
|
192557
192557
|
return;
|
|
192558
192558
|
}
|
|
192559
|
-
var fileSize =
|
|
192559
|
+
var fileSize = stat7.size - (value.start ? value.start : 0);
|
|
192560
192560
|
callback(null, fileSize);
|
|
192561
192561
|
});
|
|
192562
192562
|
}
|
|
@@ -220650,15 +220650,15 @@ var require_windows = __commonJS({
|
|
|
220650
220650
|
}
|
|
220651
220651
|
return false;
|
|
220652
220652
|
}
|
|
220653
|
-
function checkStat(
|
|
220654
|
-
if (!
|
|
220653
|
+
function checkStat(stat7, path97, options2) {
|
|
220654
|
+
if (!stat7.isSymbolicLink() && !stat7.isFile()) {
|
|
220655
220655
|
return false;
|
|
220656
220656
|
}
|
|
220657
220657
|
return checkPathExt(path97, options2);
|
|
220658
220658
|
}
|
|
220659
220659
|
function isexe(path97, options2, cb2) {
|
|
220660
|
-
fs28.stat(path97, function(er19,
|
|
220661
|
-
cb2(er19, er19 ? false : checkStat(
|
|
220660
|
+
fs28.stat(path97, function(er19, stat7) {
|
|
220661
|
+
cb2(er19, er19 ? false : checkStat(stat7, path97, options2));
|
|
220662
220662
|
});
|
|
220663
220663
|
}
|
|
220664
220664
|
function sync2(path97, options2) {
|
|
@@ -220675,20 +220675,20 @@ var require_mode = __commonJS({
|
|
|
220675
220675
|
isexe.sync = sync2;
|
|
220676
220676
|
var fs28 = require("fs");
|
|
220677
220677
|
function isexe(path97, options2, cb2) {
|
|
220678
|
-
fs28.stat(path97, function(er19,
|
|
220679
|
-
cb2(er19, er19 ? false : checkStat(
|
|
220678
|
+
fs28.stat(path97, function(er19, stat7) {
|
|
220679
|
+
cb2(er19, er19 ? false : checkStat(stat7, options2));
|
|
220680
220680
|
});
|
|
220681
220681
|
}
|
|
220682
220682
|
function sync2(path97, options2) {
|
|
220683
220683
|
return checkStat(fs28.statSync(path97), options2);
|
|
220684
220684
|
}
|
|
220685
|
-
function checkStat(
|
|
220686
|
-
return
|
|
220685
|
+
function checkStat(stat7, options2) {
|
|
220686
|
+
return stat7.isFile() && checkMode(stat7, options2);
|
|
220687
220687
|
}
|
|
220688
|
-
function checkMode(
|
|
220689
|
-
var mod =
|
|
220690
|
-
var uid =
|
|
220691
|
-
var gid =
|
|
220688
|
+
function checkMode(stat7, options2) {
|
|
220689
|
+
var mod = stat7.mode;
|
|
220690
|
+
var uid = stat7.uid;
|
|
220691
|
+
var gid = stat7.gid;
|
|
220692
220692
|
var myUid = options2.uid !== void 0 ? options2.uid : process.getuid && process.getuid();
|
|
220693
220693
|
var myGid = options2.gid !== void 0 ? options2.gid : process.getgid && process.getgid();
|
|
220694
220694
|
var u8 = parseInt("100", 8);
|
|
@@ -270532,14 +270532,14 @@ var require_require_in_the_middle = __commonJS({
|
|
|
270532
270532
|
moduleName = parsedPath.name;
|
|
270533
270533
|
basedir = parsedPath.dir;
|
|
270534
270534
|
} else {
|
|
270535
|
-
const
|
|
270536
|
-
if (
|
|
270535
|
+
const stat7 = moduleDetailsFromPath(filename);
|
|
270536
|
+
if (stat7 === void 0) {
|
|
270537
270537
|
debug9("could not parse filename: %s", filename);
|
|
270538
270538
|
return exports3;
|
|
270539
270539
|
}
|
|
270540
|
-
moduleName =
|
|
270541
|
-
basedir =
|
|
270542
|
-
const fullModuleName = resolveModuleName(
|
|
270540
|
+
moduleName = stat7.name;
|
|
270541
|
+
basedir = stat7.basedir;
|
|
270542
|
+
const fullModuleName = resolveModuleName(stat7);
|
|
270543
270543
|
debug9("resolved filename to module: %s (id: %s, resolved: %s, basedir: %s)", moduleName, id2, fullModuleName, basedir);
|
|
270544
270544
|
let matchFound = false;
|
|
270545
270545
|
if (hasWhitelist) {
|
|
@@ -270601,9 +270601,9 @@ var require_require_in_the_middle = __commonJS({
|
|
|
270601
270601
|
}
|
|
270602
270602
|
}
|
|
270603
270603
|
};
|
|
270604
|
-
function resolveModuleName(
|
|
270605
|
-
const normalizedPath = path97.sep !== "/" ?
|
|
270606
|
-
return path97.posix.join(
|
|
270604
|
+
function resolveModuleName(stat7) {
|
|
270605
|
+
const normalizedPath = path97.sep !== "/" ? stat7.path.split(path97.sep).join("/") : stat7.path;
|
|
270606
|
+
return path97.posix.join(stat7.name, normalizedPath).replace(normalize13, "");
|
|
270607
270607
|
}
|
|
270608
270608
|
}
|
|
270609
270609
|
});
|
|
@@ -297908,13 +297908,13 @@ var require_view = __commonJS({
|
|
|
297908
297908
|
View.prototype.resolve = function resolve14(dir, file4) {
|
|
297909
297909
|
var ext2 = this.ext;
|
|
297910
297910
|
var path98 = join27(dir, file4);
|
|
297911
|
-
var
|
|
297912
|
-
if (
|
|
297911
|
+
var stat7 = tryStat(path98);
|
|
297912
|
+
if (stat7 && stat7.isFile()) {
|
|
297913
297913
|
return path98;
|
|
297914
297914
|
}
|
|
297915
297915
|
path98 = join27(dir, basename6(file4, ext2), "index" + ext2);
|
|
297916
|
-
|
|
297917
|
-
if (
|
|
297916
|
+
stat7 = tryStat(path98);
|
|
297917
|
+
if (stat7 && stat7.isFile()) {
|
|
297918
297918
|
return path98;
|
|
297919
297919
|
}
|
|
297920
297920
|
};
|
|
@@ -298126,9 +298126,9 @@ var require_etag = __commonJS({
|
|
|
298126
298126
|
}
|
|
298127
298127
|
return obj && typeof obj === "object" && "ctime" in obj && toString11.call(obj.ctime) === "[object Date]" && "mtime" in obj && toString11.call(obj.mtime) === "[object Date]" && "ino" in obj && typeof obj.ino === "number" && "size" in obj && typeof obj.size === "number";
|
|
298128
298128
|
}
|
|
298129
|
-
function stattag(
|
|
298130
|
-
var mtime =
|
|
298131
|
-
var size2 =
|
|
298129
|
+
function stattag(stat7) {
|
|
298130
|
+
var mtime = stat7.mtime.getTime().toString(16);
|
|
298131
|
+
var size2 = stat7.size.toString(16);
|
|
298132
298132
|
return '"' + size2 + "-" + mtime + '"';
|
|
298133
298133
|
}
|
|
298134
298134
|
}
|
|
@@ -298626,8 +298626,8 @@ var require_send = __commonJS({
|
|
|
298626
298626
|
this.sendFile(path98);
|
|
298627
298627
|
return res;
|
|
298628
298628
|
};
|
|
298629
|
-
SendStream.prototype.send = function send2(path98,
|
|
298630
|
-
var len =
|
|
298629
|
+
SendStream.prototype.send = function send2(path98, stat7) {
|
|
298630
|
+
var len = stat7.size;
|
|
298631
298631
|
var options2 = this.options;
|
|
298632
298632
|
var opts = {};
|
|
298633
298633
|
var res = this.res;
|
|
@@ -298639,7 +298639,7 @@ var require_send = __commonJS({
|
|
|
298639
298639
|
return;
|
|
298640
298640
|
}
|
|
298641
298641
|
debug9('pipe "%s"', path98);
|
|
298642
|
-
this.setHeader(path98,
|
|
298642
|
+
this.setHeader(path98, stat7);
|
|
298643
298643
|
this.type(path98);
|
|
298644
298644
|
if (this.isConditionalGET()) {
|
|
298645
298645
|
if (this.isPreconditionFailure()) {
|
|
@@ -298695,14 +298695,14 @@ var require_send = __commonJS({
|
|
|
298695
298695
|
var i11 = 0;
|
|
298696
298696
|
var self2 = this;
|
|
298697
298697
|
debug9('stat "%s"', path98);
|
|
298698
|
-
fs28.stat(path98, function onstat(err,
|
|
298698
|
+
fs28.stat(path98, function onstat(err, stat7) {
|
|
298699
298699
|
if (err && err.code === "ENOENT" && !extname3(path98) && path98[path98.length - 1] !== sep11) {
|
|
298700
298700
|
return next2(err);
|
|
298701
298701
|
}
|
|
298702
298702
|
if (err) return self2.onStatError(err);
|
|
298703
|
-
if (
|
|
298704
|
-
self2.emit("file", path98,
|
|
298705
|
-
self2.send(path98,
|
|
298703
|
+
if (stat7.isDirectory()) return self2.redirect(path98);
|
|
298704
|
+
self2.emit("file", path98, stat7);
|
|
298705
|
+
self2.send(path98, stat7);
|
|
298706
298706
|
});
|
|
298707
298707
|
function next2(err) {
|
|
298708
298708
|
if (self2._extensions.length <= i11) {
|
|
@@ -298710,11 +298710,11 @@ var require_send = __commonJS({
|
|
|
298710
298710
|
}
|
|
298711
298711
|
var p10 = path98 + "." + self2._extensions[i11++];
|
|
298712
298712
|
debug9('stat "%s"', p10);
|
|
298713
|
-
fs28.stat(p10, function(err2,
|
|
298713
|
+
fs28.stat(p10, function(err2, stat7) {
|
|
298714
298714
|
if (err2) return next2(err2);
|
|
298715
|
-
if (
|
|
298716
|
-
self2.emit("file", p10,
|
|
298717
|
-
self2.send(p10,
|
|
298715
|
+
if (stat7.isDirectory()) return next2();
|
|
298716
|
+
self2.emit("file", p10, stat7);
|
|
298717
|
+
self2.send(p10, stat7);
|
|
298718
298718
|
});
|
|
298719
298719
|
}
|
|
298720
298720
|
};
|
|
@@ -298728,11 +298728,11 @@ var require_send = __commonJS({
|
|
|
298728
298728
|
}
|
|
298729
298729
|
var p10 = join27(path98, self2._index[i11]);
|
|
298730
298730
|
debug9('stat "%s"', p10);
|
|
298731
|
-
fs28.stat(p10, function(err2,
|
|
298731
|
+
fs28.stat(p10, function(err2, stat7) {
|
|
298732
298732
|
if (err2) return next2(err2);
|
|
298733
|
-
if (
|
|
298734
|
-
self2.emit("file", p10,
|
|
298735
|
-
self2.send(p10,
|
|
298733
|
+
if (stat7.isDirectory()) return next2();
|
|
298734
|
+
self2.emit("file", p10, stat7);
|
|
298735
|
+
self2.send(p10, stat7);
|
|
298736
298736
|
});
|
|
298737
298737
|
}
|
|
298738
298738
|
next2();
|
|
@@ -298767,9 +298767,9 @@ var require_send = __commonJS({
|
|
|
298767
298767
|
debug9("content-type %s", type9);
|
|
298768
298768
|
res.setHeader("Content-Type", type9 + (charset ? "; charset=" + charset : ""));
|
|
298769
298769
|
};
|
|
298770
|
-
SendStream.prototype.setHeader = function setHeader(path98,
|
|
298770
|
+
SendStream.prototype.setHeader = function setHeader(path98, stat7) {
|
|
298771
298771
|
var res = this.res;
|
|
298772
|
-
this.emit("headers", res, path98,
|
|
298772
|
+
this.emit("headers", res, path98, stat7);
|
|
298773
298773
|
if (this._acceptRanges && !res.getHeader("Accept-Ranges")) {
|
|
298774
298774
|
debug9("accept ranges");
|
|
298775
298775
|
res.setHeader("Accept-Ranges", "bytes");
|
|
@@ -298783,12 +298783,12 @@ var require_send = __commonJS({
|
|
|
298783
298783
|
res.setHeader("Cache-Control", cacheControl);
|
|
298784
298784
|
}
|
|
298785
298785
|
if (this._lastModified && !res.getHeader("Last-Modified")) {
|
|
298786
|
-
var modified =
|
|
298786
|
+
var modified = stat7.mtime.toUTCString();
|
|
298787
298787
|
debug9("modified %s", modified);
|
|
298788
298788
|
res.setHeader("Last-Modified", modified);
|
|
298789
298789
|
}
|
|
298790
298790
|
if (this._etag && !res.getHeader("ETag")) {
|
|
298791
|
-
var val = etag(
|
|
298791
|
+
var val = etag(stat7);
|
|
298792
298792
|
debug9("etag %s", val);
|
|
298793
298793
|
res.setHeader("ETag", val);
|
|
298794
298794
|
}
|
|
@@ -306775,9 +306775,9 @@ var require_graceful_fs2 = __commonJS({
|
|
|
306775
306775
|
}
|
|
306776
306776
|
}
|
|
306777
306777
|
var fs$readdir = fs29.readdir;
|
|
306778
|
-
fs29.readdir =
|
|
306778
|
+
fs29.readdir = readdir21;
|
|
306779
306779
|
var noReaddirOptionVersions = /^v[0-5]\./;
|
|
306780
|
-
function
|
|
306780
|
+
function readdir21(path97, options2, cb2) {
|
|
306781
306781
|
if (typeof options2 === "function")
|
|
306782
306782
|
cb2 = options2, options2 = null;
|
|
306783
306783
|
var go$readdir = noReaddirOptionVersions.test(process.version) ? function go$readdir2(path98, options3, cb3, startTime) {
|
|
@@ -315619,7 +315619,7 @@ var require_make_dir = __commonJS({
|
|
|
315619
315619
|
checkPath(input3);
|
|
315620
315620
|
opts = Object.assign({}, defaults3, opts);
|
|
315621
315621
|
const mkdir42 = pify(opts.fs.mkdir);
|
|
315622
|
-
const
|
|
315622
|
+
const stat7 = pify(opts.fs.stat);
|
|
315623
315623
|
const make = (pth) => {
|
|
315624
315624
|
return mkdir42(pth, opts.mode).then(() => pth).catch((err) => {
|
|
315625
315625
|
if (err.code === "ENOENT") {
|
|
@@ -315628,7 +315628,7 @@ var require_make_dir = __commonJS({
|
|
|
315628
315628
|
}
|
|
315629
315629
|
return make(path97.dirname(pth)).then(() => make(pth));
|
|
315630
315630
|
}
|
|
315631
|
-
return
|
|
315631
|
+
return stat7(pth).then((stats) => stats.isDirectory() ? pth : Promise.reject()).catch(() => {
|
|
315632
315632
|
throw err;
|
|
315633
315633
|
});
|
|
315634
315634
|
});
|
|
@@ -365229,8 +365229,8 @@ CLI Version: ${options2.cliVersion}`;
|
|
|
365229
365229
|
return null;
|
|
365230
365230
|
}
|
|
365231
365231
|
try {
|
|
365232
|
-
const
|
|
365233
|
-
if (
|
|
365232
|
+
const stat7 = (0, import_node_fs33.statSync)(fullPath);
|
|
365233
|
+
if (stat7.isDirectory()) {
|
|
365234
365234
|
return null;
|
|
365235
365235
|
}
|
|
365236
365236
|
return (0, import_node_fs33.readFileSync)(fullPath, "utf-8");
|
|
@@ -366901,7 +366901,7 @@ var require_copy = __commonJS({
|
|
|
366901
366901
|
var { mkdirs } = require_mkdirs();
|
|
366902
366902
|
var { pathExists: pathExists2 } = require_path_exists();
|
|
366903
366903
|
var { utimesMillis } = require_utimes();
|
|
366904
|
-
var
|
|
366904
|
+
var stat7 = require_stat();
|
|
366905
366905
|
var { asyncIteratorConcurrentProcess } = require_async6();
|
|
366906
366906
|
async function copy(src, dest, opts = {}) {
|
|
366907
366907
|
if (typeof opts === "function") {
|
|
@@ -366916,8 +366916,8 @@ var require_copy = __commonJS({
|
|
|
366916
366916
|
"fs-extra-WARN0001"
|
|
366917
366917
|
);
|
|
366918
366918
|
}
|
|
366919
|
-
const { srcStat, destStat } = await
|
|
366920
|
-
await
|
|
366919
|
+
const { srcStat, destStat } = await stat7.checkPaths(src, dest, "copy", opts);
|
|
366920
|
+
await stat7.checkParentPaths(src, srcStat, dest, "copy");
|
|
366921
366921
|
const include = await runFilter(src, dest, opts);
|
|
366922
366922
|
if (!include) return;
|
|
366923
366923
|
const destParent = path97.dirname(dest);
|
|
@@ -366977,7 +366977,7 @@ var require_copy = __commonJS({
|
|
|
366977
366977
|
const destItem = path97.join(dest, item.name);
|
|
366978
366978
|
const include = await runFilter(srcItem, destItem, opts);
|
|
366979
366979
|
if (include) {
|
|
366980
|
-
const { destStat: destStat2 } = await
|
|
366980
|
+
const { destStat: destStat2 } = await stat7.checkPaths(srcItem, destItem, "copy", opts);
|
|
366981
366981
|
await getStatsAndPerformCopy(destStat2, srcItem, destItem, opts);
|
|
366982
366982
|
}
|
|
366983
366983
|
});
|
|
@@ -367004,10 +367004,10 @@ var require_copy = __commonJS({
|
|
|
367004
367004
|
resolvedDest = path97.resolve(process.cwd(), resolvedDest);
|
|
367005
367005
|
}
|
|
367006
367006
|
if (resolvedSrc !== resolvedDest) {
|
|
367007
|
-
if (
|
|
367007
|
+
if (stat7.isSrcSubdir(resolvedSrc, resolvedDest)) {
|
|
367008
367008
|
throw new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`);
|
|
367009
367009
|
}
|
|
367010
|
-
if (
|
|
367010
|
+
if (stat7.isSrcSubdir(resolvedDest, resolvedSrc)) {
|
|
367011
367011
|
throw new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`);
|
|
367012
367012
|
}
|
|
367013
367013
|
}
|
|
@@ -367026,7 +367026,7 @@ var require_copy_sync = __commonJS({
|
|
|
367026
367026
|
var path97 = require("path");
|
|
367027
367027
|
var mkdirsSync = require_mkdirs().mkdirsSync;
|
|
367028
367028
|
var utimesMillisSync = require_utimes().utimesMillisSync;
|
|
367029
|
-
var
|
|
367029
|
+
var stat7 = require_stat();
|
|
367030
367030
|
function copySync(src, dest, opts) {
|
|
367031
367031
|
if (typeof opts === "function") {
|
|
367032
367032
|
opts = { filter: opts };
|
|
@@ -367041,8 +367041,8 @@ var require_copy_sync = __commonJS({
|
|
|
367041
367041
|
"fs-extra-WARN0002"
|
|
367042
367042
|
);
|
|
367043
367043
|
}
|
|
367044
|
-
const { srcStat, destStat } =
|
|
367045
|
-
|
|
367044
|
+
const { srcStat, destStat } = stat7.checkPathsSync(src, dest, "copy", opts);
|
|
367045
|
+
stat7.checkParentPathsSync(src, srcStat, dest, "copy");
|
|
367046
367046
|
if (opts.filter && !opts.filter(src, dest)) return;
|
|
367047
367047
|
const destParent = path97.dirname(dest);
|
|
367048
367048
|
if (!fs28.existsSync(destParent)) mkdirsSync(destParent);
|
|
@@ -367116,7 +367116,7 @@ var require_copy_sync = __commonJS({
|
|
|
367116
367116
|
const srcItem = path97.join(src, item);
|
|
367117
367117
|
const destItem = path97.join(dest, item);
|
|
367118
367118
|
if (opts.filter && !opts.filter(srcItem, destItem)) return;
|
|
367119
|
-
const { destStat } =
|
|
367119
|
+
const { destStat } = stat7.checkPathsSync(srcItem, destItem, "copy", opts);
|
|
367120
367120
|
return getStats(destStat, srcItem, destItem, opts);
|
|
367121
367121
|
}
|
|
367122
367122
|
function onLink(destStat, src, dest, opts) {
|
|
@@ -367138,10 +367138,10 @@ var require_copy_sync = __commonJS({
|
|
|
367138
367138
|
resolvedDest = path97.resolve(process.cwd(), resolvedDest);
|
|
367139
367139
|
}
|
|
367140
367140
|
if (resolvedSrc !== resolvedDest) {
|
|
367141
|
-
if (
|
|
367141
|
+
if (stat7.isSrcSubdir(resolvedSrc, resolvedDest)) {
|
|
367142
367142
|
throw new Error(`Cannot copy '${resolvedSrc}' to a subdirectory of itself, '${resolvedDest}'.`);
|
|
367143
367143
|
}
|
|
367144
|
-
if (
|
|
367144
|
+
if (stat7.isSrcSubdir(resolvedDest, resolvedSrc)) {
|
|
367145
367145
|
throw new Error(`Cannot overwrite '${resolvedDest}' with '${resolvedSrc}'.`);
|
|
367146
367146
|
}
|
|
367147
367147
|
}
|
|
@@ -367747,11 +367747,11 @@ var require_move = __commonJS({
|
|
|
367747
367747
|
var { remove: remove3 } = require_remove3();
|
|
367748
367748
|
var { mkdirp } = require_mkdirs();
|
|
367749
367749
|
var { pathExists: pathExists2 } = require_path_exists();
|
|
367750
|
-
var
|
|
367750
|
+
var stat7 = require_stat();
|
|
367751
367751
|
async function move(src, dest, opts = {}) {
|
|
367752
367752
|
const overwrite = opts.overwrite || opts.clobber || false;
|
|
367753
|
-
const { srcStat, isChangingCase = false } = await
|
|
367754
|
-
await
|
|
367753
|
+
const { srcStat, isChangingCase = false } = await stat7.checkPaths(src, dest, "move", opts);
|
|
367754
|
+
await stat7.checkParentPaths(src, srcStat, dest, "move");
|
|
367755
367755
|
const destParent = path97.dirname(dest);
|
|
367756
367756
|
const parsedParentPath = path97.parse(destParent);
|
|
367757
367757
|
if (parsedParentPath.root !== destParent) {
|
|
@@ -367798,12 +367798,12 @@ var require_move_sync = __commonJS({
|
|
|
367798
367798
|
var copySync = require_copy2().copySync;
|
|
367799
367799
|
var removeSync = require_remove3().removeSync;
|
|
367800
367800
|
var mkdirpSync = require_mkdirs().mkdirpSync;
|
|
367801
|
-
var
|
|
367801
|
+
var stat7 = require_stat();
|
|
367802
367802
|
function moveSync(src, dest, opts) {
|
|
367803
367803
|
opts = opts || {};
|
|
367804
367804
|
const overwrite = opts.overwrite || opts.clobber || false;
|
|
367805
|
-
const { srcStat, isChangingCase = false } =
|
|
367806
|
-
|
|
367805
|
+
const { srcStat, isChangingCase = false } = stat7.checkPathsSync(src, dest, "move", opts);
|
|
367806
|
+
stat7.checkParentPathsSync(src, srcStat, dest, "move");
|
|
367807
367807
|
if (!isParentRoot(dest)) mkdirpSync(path97.dirname(dest));
|
|
367808
367808
|
return doRename(src, dest, overwrite, isChangingCase);
|
|
367809
367809
|
}
|
|
@@ -404715,8 +404715,8 @@ var require_file2 = __commonJS({
|
|
|
404715
404715
|
debug9("Normalized pathname: %o", filepath);
|
|
404716
404716
|
const fdHandle = await fs_1.promises.open(filepath, flags2, mode);
|
|
404717
404717
|
const fd = fdHandle.fd;
|
|
404718
|
-
const
|
|
404719
|
-
if (cache3 && cache3.stat &&
|
|
404718
|
+
const stat7 = await fdHandle.stat();
|
|
404719
|
+
if (cache3 && cache3.stat && stat7 && isNotModified(cache3.stat, stat7)) {
|
|
404720
404720
|
await fdHandle.close();
|
|
404721
404721
|
throw new notmodified_1.default();
|
|
404722
404722
|
}
|
|
@@ -404725,7 +404725,7 @@ var require_file2 = __commonJS({
|
|
|
404725
404725
|
...opts,
|
|
404726
404726
|
fd
|
|
404727
404727
|
});
|
|
404728
|
-
rs4.stat =
|
|
404728
|
+
rs4.stat = stat7;
|
|
404729
404729
|
return rs4;
|
|
404730
404730
|
} catch (err) {
|
|
404731
404731
|
if (err.code === "ENOENT") {
|
|
@@ -430345,37 +430345,37 @@ var require_tar_fs = __commonJS({
|
|
|
430345
430345
|
pack2.entry(header, onnextentry);
|
|
430346
430346
|
});
|
|
430347
430347
|
}
|
|
430348
|
-
function onstat(err, filename,
|
|
430348
|
+
function onstat(err, filename, stat7) {
|
|
430349
430349
|
if (pack2.destroyed) return;
|
|
430350
430350
|
if (err) return pack2.destroy(err);
|
|
430351
430351
|
if (!filename) {
|
|
430352
430352
|
if (opts.finalize !== false) pack2.finalize();
|
|
430353
430353
|
return finish(pack2);
|
|
430354
430354
|
}
|
|
430355
|
-
if (
|
|
430355
|
+
if (stat7.isSocket()) return onnextentry();
|
|
430356
430356
|
let header = {
|
|
430357
430357
|
name: normalize13(filename),
|
|
430358
|
-
mode: (
|
|
430359
|
-
mtime:
|
|
430360
|
-
size:
|
|
430358
|
+
mode: (stat7.mode | (stat7.isDirectory() ? dmode : fmode)) & umask,
|
|
430359
|
+
mtime: stat7.mtime,
|
|
430360
|
+
size: stat7.size,
|
|
430361
430361
|
type: "file",
|
|
430362
|
-
uid:
|
|
430363
|
-
gid:
|
|
430362
|
+
uid: stat7.uid,
|
|
430363
|
+
gid: stat7.gid
|
|
430364
430364
|
};
|
|
430365
|
-
if (
|
|
430365
|
+
if (stat7.isDirectory()) {
|
|
430366
430366
|
header.size = 0;
|
|
430367
430367
|
header.type = "directory";
|
|
430368
430368
|
header = map16(header) || header;
|
|
430369
430369
|
return pack2.entry(header, onnextentry);
|
|
430370
430370
|
}
|
|
430371
|
-
if (
|
|
430371
|
+
if (stat7.isSymbolicLink()) {
|
|
430372
430372
|
header.size = 0;
|
|
430373
430373
|
header.type = "symlink";
|
|
430374
430374
|
header = map16(header) || header;
|
|
430375
430375
|
return onsymlink(filename, header);
|
|
430376
430376
|
}
|
|
430377
430377
|
header = map16(header) || header;
|
|
430378
|
-
if (!
|
|
430378
|
+
if (!stat7.isFile()) {
|
|
430379
430379
|
if (strict) return pack2.destroy(new Error("unsupported type for " + filename));
|
|
430380
430380
|
return onnextentry();
|
|
430381
430381
|
}
|
|
@@ -430450,7 +430450,7 @@ var require_tar_fs = __commonJS({
|
|
|
430450
430450
|
uid: header.uid,
|
|
430451
430451
|
gid: header.gid,
|
|
430452
430452
|
mode: header.mode
|
|
430453
|
-
},
|
|
430453
|
+
}, stat7);
|
|
430454
430454
|
}
|
|
430455
430455
|
mkdirfix(dir, {
|
|
430456
430456
|
fs: xfs,
|
|
@@ -430476,7 +430476,7 @@ var require_tar_fs = __commonJS({
|
|
|
430476
430476
|
next2();
|
|
430477
430477
|
});
|
|
430478
430478
|
});
|
|
430479
|
-
function
|
|
430479
|
+
function stat7(err) {
|
|
430480
430480
|
if (err) return next2(err);
|
|
430481
430481
|
utimes(name2, header, function(err2) {
|
|
430482
430482
|
if (err2) return next2(err2);
|
|
@@ -430489,7 +430489,7 @@ var require_tar_fs = __commonJS({
|
|
|
430489
430489
|
xfs.unlink(name2, function() {
|
|
430490
430490
|
const dst = path97.resolve(path97.dirname(name2), header.linkname);
|
|
430491
430491
|
if (!inCwd(dst) && validateSymLinks) return next2(new Error(name2 + " is not a valid symlink"));
|
|
430492
|
-
xfs.symlink(header.linkname, name2,
|
|
430492
|
+
xfs.symlink(header.linkname, name2, stat7);
|
|
430493
430493
|
});
|
|
430494
430494
|
}
|
|
430495
430495
|
function onlink() {
|
|
@@ -430503,7 +430503,7 @@ var require_tar_fs = __commonJS({
|
|
|
430503
430503
|
stream5 = xfs.createReadStream(dst);
|
|
430504
430504
|
return onfile();
|
|
430505
430505
|
}
|
|
430506
|
-
|
|
430506
|
+
stat7(err2);
|
|
430507
430507
|
});
|
|
430508
430508
|
});
|
|
430509
430509
|
});
|
|
@@ -430519,7 +430519,7 @@ var require_tar_fs = __commonJS({
|
|
|
430519
430519
|
});
|
|
430520
430520
|
pump(rs4, ws8, function(err) {
|
|
430521
430521
|
if (err) return next2(err);
|
|
430522
|
-
ws8.on("close",
|
|
430522
|
+
ws8.on("close", stat7);
|
|
430523
430523
|
});
|
|
430524
430524
|
}
|
|
430525
430525
|
}
|
|
@@ -430579,23 +430579,23 @@ var require_tar_fs = __commonJS({
|
|
|
430579
430579
|
function normalize13(name2) {
|
|
430580
430580
|
return win322 ? name2.replace(/\\/g, "/").replace(/[:?<>|]/g, "_") : name2;
|
|
430581
430581
|
}
|
|
430582
|
-
function statAll(fs29,
|
|
430582
|
+
function statAll(fs29, stat7, cwd2, ignore4, entries22, sort) {
|
|
430583
430583
|
if (!entries22) entries22 = ["."];
|
|
430584
430584
|
const queue = entries22.slice(0);
|
|
430585
430585
|
return function loop(callback) {
|
|
430586
430586
|
if (!queue.length) return callback(null);
|
|
430587
430587
|
const next2 = queue.shift();
|
|
430588
430588
|
const nextAbs = path97.join(cwd2, next2);
|
|
430589
|
-
|
|
430589
|
+
stat7.call(fs29, nextAbs, function(err, stat8) {
|
|
430590
430590
|
if (err) return callback(entries22.indexOf(next2) === -1 && err.code === "ENOENT" ? null : err);
|
|
430591
|
-
if (!
|
|
430591
|
+
if (!stat8.isDirectory()) return callback(null, next2, stat8);
|
|
430592
430592
|
fs29.readdir(nextAbs, function(err2, files) {
|
|
430593
430593
|
if (err2) return callback(err2);
|
|
430594
430594
|
if (sort) files.sort();
|
|
430595
430595
|
for (let i11 = 0; i11 < files.length; i11++) {
|
|
430596
430596
|
if (!ignore4(path97.join(cwd2, next2, files[i11]))) queue.push(path97.join(next2, files[i11]));
|
|
430597
430597
|
}
|
|
430598
|
-
callback(null, next2,
|
|
430598
|
+
callback(null, next2, stat8);
|
|
430599
430599
|
});
|
|
430600
430600
|
});
|
|
430601
430601
|
};
|
|
@@ -432219,8 +432219,8 @@ var require_util9 = __commonJS({
|
|
|
432219
432219
|
exports2.removeUndefinedValuesFromObject = removeUndefinedValuesFromObject;
|
|
432220
432220
|
async function isDirectory(path97) {
|
|
432221
432221
|
try {
|
|
432222
|
-
const
|
|
432223
|
-
return
|
|
432222
|
+
const stat7 = await fs_1.promises.stat(path97);
|
|
432223
|
+
return stat7.isDirectory();
|
|
432224
432224
|
} catch (e6) {
|
|
432225
432225
|
if (e6.code === "ENOENT") {
|
|
432226
432226
|
return false;
|
|
@@ -432231,8 +432231,8 @@ var require_util9 = __commonJS({
|
|
|
432231
432231
|
exports2.isDirectory = isDirectory;
|
|
432232
432232
|
function isDirectorySync(path97) {
|
|
432233
432233
|
try {
|
|
432234
|
-
const
|
|
432235
|
-
return
|
|
432234
|
+
const stat7 = fs_1.default.statSync(path97);
|
|
432235
|
+
return stat7.isDirectory();
|
|
432236
432236
|
} catch (e6) {
|
|
432237
432237
|
if (e6.code === "ENOENT") {
|
|
432238
432238
|
return false;
|
|
@@ -536637,7 +536637,7 @@ function checkType(type8) {
|
|
|
536637
536637
|
}
|
|
536638
536638
|
throw new Error(`Invalid type specified: ${type8}`);
|
|
536639
536639
|
}
|
|
536640
|
-
var matchType = (type8,
|
|
536640
|
+
var matchType = (type8, stat7) => stat7[typeMappings[type8]]();
|
|
536641
536641
|
var toPath2 = (urlOrPath) => urlOrPath instanceof URL ? (0, import_node_url3.fileURLToPath)(urlOrPath) : urlOrPath;
|
|
536642
536642
|
async function locatePath(paths, {
|
|
536643
536643
|
cwd: cwd2 = import_node_process2.default.cwd(),
|
|
@@ -536651,8 +536651,8 @@ async function locatePath(paths, {
|
|
|
536651
536651
|
const statFunction = allowSymlinks ? import_node_fs.promises.stat : import_node_fs.promises.lstat;
|
|
536652
536652
|
return pLocate(paths, async (path_) => {
|
|
536653
536653
|
try {
|
|
536654
|
-
const
|
|
536655
|
-
return matchType(type8,
|
|
536654
|
+
const stat7 = await statFunction(import_node_path4.default.resolve(cwd2, path_));
|
|
536655
|
+
return matchType(type8, stat7);
|
|
536656
536656
|
} catch {
|
|
536657
536657
|
return false;
|
|
536658
536658
|
}
|
|
@@ -603121,7 +603121,7 @@ var AccessTokenPosthogManager = class {
|
|
|
603121
603121
|
properties: {
|
|
603122
603122
|
...event,
|
|
603123
603123
|
...event.properties,
|
|
603124
|
-
version: "4.63.1-
|
|
603124
|
+
version: "4.63.2-1-gcc2932efdb5",
|
|
603125
603125
|
usingAccessToken: true
|
|
603126
603126
|
}
|
|
603127
603127
|
});
|
|
@@ -603172,7 +603172,7 @@ var UserPosthogManager = class {
|
|
|
603172
603172
|
distinctId: this.userId ?? await this.getPersistedDistinctId(),
|
|
603173
603173
|
event: "CLI",
|
|
603174
603174
|
properties: {
|
|
603175
|
-
version: "4.63.1-
|
|
603175
|
+
version: "4.63.2-1-gcc2932efdb5",
|
|
603176
603176
|
...event,
|
|
603177
603177
|
...event.properties,
|
|
603178
603178
|
usingAccessToken: false,
|
|
@@ -814484,8 +814484,8 @@ var FileTokenizer = class _FileTokenizer extends AbstractTokenizer {
|
|
|
814484
814484
|
*/
|
|
814485
814485
|
static async fromFile(sourceFilePath) {
|
|
814486
814486
|
const fileHandle = await (0, import_promises62.open)(sourceFilePath, "r");
|
|
814487
|
-
const
|
|
814488
|
-
return new _FileTokenizer(fileHandle, { fileInfo: { path: sourceFilePath, size:
|
|
814487
|
+
const stat7 = await fileHandle.stat();
|
|
814488
|
+
return new _FileTokenizer(fileHandle, { fileInfo: { path: sourceFilePath, size: stat7.size } });
|
|
814489
814489
|
}
|
|
814490
814490
|
constructor(fileHandle, options2) {
|
|
814491
814491
|
super(options2);
|
|
@@ -838581,16 +838581,16 @@ var readdir11 = (rootPath, options2) => {
|
|
|
838581
838581
|
return;
|
|
838582
838582
|
populateResultFromSymlink(subPath, depth + 1);
|
|
838583
838583
|
};
|
|
838584
|
-
const handleStat = (dirmap, rootPath2, name2,
|
|
838584
|
+
const handleStat = (dirmap, rootPath2, name2, stat7, depth) => {
|
|
838585
838585
|
if (signal.aborted)
|
|
838586
838586
|
return;
|
|
838587
838587
|
if (isIgnored(rootPath2))
|
|
838588
838588
|
return;
|
|
838589
|
-
if (
|
|
838589
|
+
if (stat7.isDirectory()) {
|
|
838590
838590
|
handleDirectory(dirmap, rootPath2, name2, depth);
|
|
838591
|
-
} else if (
|
|
838591
|
+
} else if (stat7.isFile()) {
|
|
838592
838592
|
handleFile(dirmap, rootPath2, name2);
|
|
838593
|
-
} else if (
|
|
838593
|
+
} else if (stat7.isSymbolicLink()) {
|
|
838594
838594
|
handleSymlink(dirmap, rootPath2, name2, depth);
|
|
838595
838595
|
}
|
|
838596
838596
|
};
|
|
@@ -838645,14 +838645,14 @@ var readdir11 = (rootPath, options2) => {
|
|
|
838645
838645
|
return decrement();
|
|
838646
838646
|
if (signal.aborted)
|
|
838647
838647
|
return decrement();
|
|
838648
|
-
import_node_fs16.default.stat(realPath, (error51,
|
|
838648
|
+
import_node_fs16.default.stat(realPath, (error51, stat7) => {
|
|
838649
838649
|
if (error51)
|
|
838650
838650
|
return decrement();
|
|
838651
838651
|
if (signal.aborted)
|
|
838652
838652
|
return decrement();
|
|
838653
838653
|
const name2 = import_node_path20.default.basename(realPath);
|
|
838654
838654
|
const dirmap = map16[rootPath2] = { directories: [], directoriesNames: /* @__PURE__ */ new Set(), directoriesNamesToPaths: {}, files: [], filesNames: /* @__PURE__ */ new Set(), filesNamesToPaths: {}, symlinks: [], symlinksNames: /* @__PURE__ */ new Set(), symlinksNamesToPaths: {} };
|
|
838655
|
-
handleStat(dirmap, realPath, name2,
|
|
838655
|
+
handleStat(dirmap, realPath, name2, stat7, depth);
|
|
838656
838656
|
decrement();
|
|
838657
838657
|
});
|
|
838658
838658
|
});
|
|
@@ -839082,11 +839082,11 @@ var WatcherLocker = class _WatcherLocker {
|
|
|
839082
839082
|
};
|
|
839083
839083
|
watcher_locks_resolver_default.add(free, timeout4);
|
|
839084
839084
|
const resolve13 = () => {
|
|
839085
|
-
const
|
|
839086
|
-
if (!
|
|
839085
|
+
const unlink11 = locks.unlink.get(ino);
|
|
839086
|
+
if (!unlink11)
|
|
839087
839087
|
return;
|
|
839088
839088
|
cleanup();
|
|
839089
|
-
const targetPathPrev =
|
|
839089
|
+
const targetPathPrev = unlink11();
|
|
839090
839090
|
if (targetPath === targetPathPrev) {
|
|
839091
839091
|
if (events.change) {
|
|
839092
839092
|
if (this._watcher._poller.stats.has(targetPath)) {
|
|
@@ -839764,24 +839764,27 @@ var import_os9 = require("os");
|
|
|
839764
839764
|
var import_path54 = __toESM(require("path"), 1);
|
|
839765
839765
|
var LOCAL_STORAGE_FOLDER4 = ".fern-dev";
|
|
839766
839766
|
var LOGS_FOLDER_NAME = "logs";
|
|
839767
|
+
var MAX_LOGS_DIR_SIZE_BYTES = 100 * 1024 * 1024;
|
|
839767
839768
|
function getCliSource() {
|
|
839768
|
-
const version7 = "4.63.1-
|
|
839769
|
+
const version7 = "4.63.2-1-gcc2932efdb5";
|
|
839769
839770
|
return `cli@${version7}`;
|
|
839770
839771
|
}
|
|
839771
839772
|
var DebugLogger = class {
|
|
839772
839773
|
logFilePath = null;
|
|
839773
839774
|
initialized = false;
|
|
839774
839775
|
sessionStartTime;
|
|
839776
|
+
consoleLogger;
|
|
839775
839777
|
constructor() {
|
|
839776
839778
|
this.sessionStartTime = Date.now();
|
|
839777
839779
|
}
|
|
839778
839780
|
/**
|
|
839779
839781
|
* Initialize the debug logger by creating the log file
|
|
839780
839782
|
*/
|
|
839781
|
-
async initialize() {
|
|
839783
|
+
async initialize(consoleLogger) {
|
|
839782
839784
|
if (this.initialized) {
|
|
839783
839785
|
return;
|
|
839784
839786
|
}
|
|
839787
|
+
this.consoleLogger = consoleLogger;
|
|
839785
839788
|
const localStorageFolder = join2(AbsoluteFilePath2.of((0, import_os9.homedir)()), RelativeFilePath2.of(LOCAL_STORAGE_FOLDER4));
|
|
839786
839789
|
const logsDir = join2(localStorageFolder, RelativeFilePath2.of(LOGS_FOLDER_NAME));
|
|
839787
839790
|
if (!await doesPathExist(logsDir)) {
|
|
@@ -839800,6 +839803,7 @@ var DebugLogger = class {
|
|
|
839800
839803
|
].join("\n");
|
|
839801
839804
|
await (0, import_promises76.writeFile)(this.logFilePath, header, "utf-8");
|
|
839802
839805
|
this.initialized = true;
|
|
839806
|
+
void this.enforceLogSizeLimit(logsDir);
|
|
839803
839807
|
}
|
|
839804
839808
|
/**
|
|
839805
839809
|
* Get the path to the log file
|
|
@@ -839916,6 +839920,47 @@ var DebugLogger = class {
|
|
|
839916
839920
|
};
|
|
839917
839921
|
await this.logCliMetric(event);
|
|
839918
839922
|
}
|
|
839923
|
+
/**
|
|
839924
|
+
* Delete oldest log files until total directory size is within the cap.
|
|
839925
|
+
*/
|
|
839926
|
+
async enforceLogSizeLimit(logsDir) {
|
|
839927
|
+
try {
|
|
839928
|
+
const entries22 = await (0, import_promises76.readdir)(logsDir);
|
|
839929
|
+
const logFiles = entries22.filter((name2) => name2.endsWith(".log"));
|
|
839930
|
+
const fileInfos = [];
|
|
839931
|
+
for (const name2 of logFiles) {
|
|
839932
|
+
const fullPath = import_path54.default.join(logsDir, name2);
|
|
839933
|
+
try {
|
|
839934
|
+
const stats = await (0, import_promises76.stat)(fullPath);
|
|
839935
|
+
fileInfos.push({ name: name2, fullPath, size: stats.size, mtimeMs: stats.mtimeMs });
|
|
839936
|
+
} catch {
|
|
839937
|
+
}
|
|
839938
|
+
}
|
|
839939
|
+
let totalSize = fileInfos.reduce((sum, f10) => sum + f10.size, 0);
|
|
839940
|
+
const totalSizeMB = Math.round(totalSize / 1024 / 1024 * 100) / 100;
|
|
839941
|
+
const capMB = MAX_LOGS_DIR_SIZE_BYTES / 1024 / 1024;
|
|
839942
|
+
if (totalSize <= MAX_LOGS_DIR_SIZE_BYTES) {
|
|
839943
|
+
this.consoleLogger?.debug(`Log directory size ${totalSizeMB} MB does not exceed ${capMB} MB cap`);
|
|
839944
|
+
return;
|
|
839945
|
+
}
|
|
839946
|
+
this.consoleLogger?.info(`Rotating logs: total size ${totalSizeMB} MB exceeds ${capMB} MB cap`);
|
|
839947
|
+
fileInfos.sort((a10, b19) => a10.mtimeMs - b19.mtimeMs);
|
|
839948
|
+
for (const file4 of fileInfos) {
|
|
839949
|
+
if (totalSize <= MAX_LOGS_DIR_SIZE_BYTES) {
|
|
839950
|
+
break;
|
|
839951
|
+
}
|
|
839952
|
+
if (this.logFilePath != null && file4.fullPath === this.logFilePath) {
|
|
839953
|
+
continue;
|
|
839954
|
+
}
|
|
839955
|
+
try {
|
|
839956
|
+
await (0, import_promises76.unlink)(file4.fullPath);
|
|
839957
|
+
totalSize -= file4.size;
|
|
839958
|
+
} catch {
|
|
839959
|
+
}
|
|
839960
|
+
}
|
|
839961
|
+
} catch {
|
|
839962
|
+
}
|
|
839963
|
+
}
|
|
839919
839964
|
getEventType(payload, isAggregate) {
|
|
839920
839965
|
if (isAggregate) {
|
|
839921
839966
|
return "aggregate_summary";
|
|
@@ -841037,7 +841082,10 @@ async function runAppPreviewServer({ initialProject, reloadProject, validateProj
|
|
|
841037
841082
|
const serverPath = import_path55.default.join(bundleRoot, "standalone/packages/fern-docs/bundle/server.js");
|
|
841038
841083
|
const absoluteFilePathToFern = dirname4(initialProject.config._absolutePath);
|
|
841039
841084
|
const debugLogger = new DebugLogger();
|
|
841040
|
-
await debugLogger.initialize(
|
|
841085
|
+
await debugLogger.initialize({
|
|
841086
|
+
debug: (msg) => context3.logger.debug(msg),
|
|
841087
|
+
info: (msg) => context3.logger.info(msg)
|
|
841088
|
+
});
|
|
841041
841089
|
const debugLogPath = debugLogger.getLogFilePath();
|
|
841042
841090
|
if (debugLogPath) {
|
|
841043
841091
|
context3.logger.info(source_default.dim(`Debug log: ${debugLogPath}`));
|
|
@@ -850916,7 +850964,7 @@ var LegacyDocsPublisher = class {
|
|
|
850916
850964
|
previewId,
|
|
850917
850965
|
disableTemplates: void 0,
|
|
850918
850966
|
skipUpload,
|
|
850919
|
-
cliVersion: "4.63.1-
|
|
850967
|
+
cliVersion: "4.63.2-1-gcc2932efdb5"
|
|
850920
850968
|
});
|
|
850921
850969
|
if (taskContext.getResult() === TaskResult.Failure) {
|
|
850922
850970
|
return { success: false };
|
|
@@ -924294,7 +924342,7 @@ var CliContext = class {
|
|
|
924294
924342
|
if (false) {
|
|
924295
924343
|
this.logger.error("CLI_VERSION is not defined");
|
|
924296
924344
|
}
|
|
924297
|
-
return "4.63.1-
|
|
924345
|
+
return "4.63.2-1-gcc2932efdb5";
|
|
924298
924346
|
}
|
|
924299
924347
|
getCliName() {
|
|
924300
924348
|
if (false) {
|
|
@@ -941689,13 +941737,13 @@ async function collectFiles(baseDirectory, relativeBase) {
|
|
|
941689
941737
|
}
|
|
941690
941738
|
const fullPath = import_path92.default.join(baseDirectory, entry);
|
|
941691
941739
|
const relativePath = relativeBase ? join2(relativeBase, RelativeFilePath2.of(entry)) : RelativeFilePath2.of(entry);
|
|
941692
|
-
const
|
|
941693
|
-
if (
|
|
941740
|
+
const stat7 = (0, import_fs36.statSync)(fullPath);
|
|
941741
|
+
if (stat7.isDirectory()) {
|
|
941694
941742
|
const subdirectoryFiles = await collectFiles(fullPath, relativePath);
|
|
941695
941743
|
for (const [subPath, subRelativePath] of Object.entries(subdirectoryFiles)) {
|
|
941696
941744
|
discoveredFiles[subPath] = subRelativePath;
|
|
941697
941745
|
}
|
|
941698
|
-
} else if (
|
|
941746
|
+
} else if (stat7.isFile()) {
|
|
941699
941747
|
discoveredFiles[fullPath] = relativePath;
|
|
941700
941748
|
}
|
|
941701
941749
|
}
|
|
@@ -944464,8 +944512,8 @@ function addReplayForgetCommand(cli, cliContext) {
|
|
|
944464
944512
|
}
|
|
944465
944513
|
cliContext.logger.info(`${matched.length} patch(es) matched:`);
|
|
944466
944514
|
for (const patch5 of matched) {
|
|
944467
|
-
const
|
|
944468
|
-
cliContext.logger.info(` ${patch5.id}: ${patch5.message} (${
|
|
944515
|
+
const stat7 = `+${patch5.diffstat.additions}/-${patch5.diffstat.deletions}`;
|
|
944516
|
+
cliContext.logger.info(` ${patch5.id}: ${patch5.message} (${stat7})`);
|
|
944469
944517
|
}
|
|
944470
944518
|
if (dryRun) {
|
|
944471
944519
|
cliContext.logger.info("\nDry run \u2014 no patches removed.");
|
package/package.json
CHANGED