@tnotesjs/core 0.0.4 → 0.0.5
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.
|
@@ -4085,13 +4085,9 @@ var VitepressService = class _VitepressService {
|
|
|
4085
4085
|
) ? process.env.NODE_OPTIONS : [process.env.NODE_OPTIONS, "--max-old-space-size=4096"].filter(Boolean).join(" ")
|
|
4086
4086
|
}
|
|
4087
4087
|
});
|
|
4088
|
-
let buildSucceeded = false;
|
|
4089
4088
|
const filterOutput = (data) => {
|
|
4090
4089
|
const str = data.toString();
|
|
4091
|
-
if (str.includes("\u{1F528}") || str.includes("\u2705
|
|
4092
|
-
if (str.includes("\u2705 \u6784\u5EFA\u6210\u529F")) {
|
|
4093
|
-
buildSucceeded = true;
|
|
4094
|
-
}
|
|
4090
|
+
if (str.includes("\u{1F528}") || str.includes("\u2705") || str.includes("\u274C \u6784\u5EFA\u5931\u8D25") || str.includes("\u{1F4C1}") || str.includes("\u{1F4CA}") || str.includes("\u{1F4E6}") || str.includes("\u23F1\uFE0F") || str.includes("\u23F3") || str.includes("Building [") || str.includes("error") || str.includes("Error")) {
|
|
4095
4091
|
process.stdout.write(data);
|
|
4096
4092
|
return;
|
|
4097
4093
|
}
|
|
@@ -4105,7 +4101,7 @@ var VitepressService = class _VitepressService {
|
|
|
4105
4101
|
reject(err);
|
|
4106
4102
|
});
|
|
4107
4103
|
child.on("close", (code) => {
|
|
4108
|
-
if (code === 0
|
|
4104
|
+
if (code === 0) {
|
|
4109
4105
|
resolve2();
|
|
4110
4106
|
} else {
|
|
4111
4107
|
reject(new Error(`Command failed with code ${code}`));
|
package/dist/cli/index.js
CHANGED
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
UpdateNoteConfigCommand,
|
|
5
5
|
generateAnchor,
|
|
6
6
|
logger
|
|
7
|
-
} from "../../chunk-
|
|
7
|
+
} from "../../chunk-JDVN2QYW.js";
|
|
8
8
|
import "../../chunk-NASIL5FY.js";
|
|
9
9
|
|
|
10
10
|
// vitepress/config/index.ts
|
|
@@ -827,9 +827,10 @@ function buildProgressPlugin(options = {}) {
|
|
|
827
827
|
chunkCount: Math.floor(globalChunkCount / 2),
|
|
828
828
|
transformEndRatio: transformTime / totalTime
|
|
829
829
|
});
|
|
830
|
-
console.log(`\
|
|
830
|
+
console.log(`\u{1F528} Rollup \u6253\u5305\u5B8C\u6210`);
|
|
831
831
|
console.log(` \u{1F4C1} \u8F93\u51FA\u76EE\u5F55: ${globalOutDir}`);
|
|
832
832
|
console.log(` \u23F1\uFE0F \u8017\u65F6: ${elapsed}s`);
|
|
833
|
+
console.log(` \u23F3 VitePress \u6B63\u5728\u6E32\u67D3\u9875\u9762...`);
|
|
833
834
|
} else {
|
|
834
835
|
console.log(`
|
|
835
836
|
\u274C \u6784\u5EFA\u5931\u8D25\uFF0C\u8BF7\u68C0\u67E5\u9519\u8BEF\u4FE1\u606F`);
|
package/package.json
CHANGED
|
@@ -216,7 +216,10 @@ function renderProgress(
|
|
|
216
216
|
const currentPercent = Math.floor(percent * 100)
|
|
217
217
|
const currentBucket = Math.floor(currentPercent / 10) * 10
|
|
218
218
|
const now = Date.now()
|
|
219
|
-
if (
|
|
219
|
+
if (
|
|
220
|
+
currentBucket <= globalLastLoggedPercent ||
|
|
221
|
+
now - globalLastOutputTime < 500
|
|
222
|
+
) {
|
|
220
223
|
return
|
|
221
224
|
}
|
|
222
225
|
globalLastLoggedPercent = currentBucket
|
|
@@ -452,9 +455,10 @@ export function buildProgressPlugin(
|
|
|
452
455
|
transformEndRatio: transformTime / totalTime,
|
|
453
456
|
})
|
|
454
457
|
|
|
455
|
-
console.log(
|
|
458
|
+
console.log(`🔨 Rollup 打包完成`)
|
|
456
459
|
console.log(` 📁 输出目录: ${globalOutDir}`)
|
|
457
460
|
console.log(` ⏱️ 耗时: ${elapsed}s`)
|
|
461
|
+
console.log(` ⏳ VitePress 正在渲染页面...`)
|
|
458
462
|
} else {
|
|
459
463
|
console.log(`\n❌ 构建失败,请检查错误信息`)
|
|
460
464
|
}
|