chore: 实现重新启动增量构建的功能

This commit is contained in:
wangxuefeng
2025-03-11 18:26:20 +08:00
parent 14d4519d03
commit f259d54035
10 changed files with 99 additions and 108 deletions

View File

@@ -22,6 +22,7 @@ async function cleanTargetsRecursively(currentDir, targets) {
if (item === 'node_modules') {
continue;
}
if (targets.includes(item)) {
// 匹配到目标目录或文件时直接删除
await fs.rm(itemPath, { force: true, recursive: true });
@@ -41,7 +42,7 @@ async function cleanTargetsRecursively(currentDir, targets) {
(async function startCleanup() {
// 要删除的目录及文件名称
const targets = ['dist', '.turbo'];
const targets = ['dist', 'dist.zip'];
const cleanupTargets = [...targets];