新增: 实时热卖榜(11分类/想要人数排序/热门搜索词热度)、价格监控(目标价通知/卖家信用筛选/销量下限/AI精准监控)、 一键转卖(收藏自动加载/改价直发/详情直达)、AI回复免费token(ai.88531.cn)、API密钥掩码、 推理模型兼容修复、商品本地编辑、授权系统接入(在线人数/版本/公告)、品牌更名躺赚鱼。 README 重写为项目介绍(改动清单/优势/真实截图/两种安装方式/体验地址 tzy.88531.cn/使用引导), 原版 README 完整保留为 README.upstream.md。
21 lines
730 B
JavaScript
21 lines
730 B
JavaScript
import { rm } from 'node:fs/promises';
|
|
import { resolve } from 'node:path';
|
|
import { fileURLToPath } from 'node:url';
|
|
|
|
const frontendDir = resolve(fileURLToPath(new URL('..', import.meta.url)));
|
|
const staticDir = resolve(frontendDir, '..', 'static');
|
|
const targets = [
|
|
resolve(staticDir, 'assets'),
|
|
resolve(staticDir, 'index.html'),
|
|
];
|
|
|
|
for (const target of targets) {
|
|
const relativeTarget = target.slice(staticDir.length + 1);
|
|
if (!relativeTarget || relativeTarget.startsWith('..')) {
|
|
throw new Error(`Refusing to clean outside static directory: ${target}`);
|
|
}
|
|
await rm(target, { recursive: true, force: true });
|
|
}
|
|
|
|
console.log('Removed previous frontend build output from static/assets and static/index.html.');
|