mirror of
https://github.com/unanmed/HumanBreak.git
synced 2026-11-10 06:54:30 +08:00
资源分类,分类出音频
This commit is contained in:
1 parent
820dc5bf4c
commit
80ce3b1a31
8 files changed
+101
-12
No files matched your search
+2
-1
@@ -23,11 +23,12 @@ let totalSize = 0;
|
||||
type Stats = fs.Stats & { name?: string };
|
||||
|
||||
export async function splitResorce(compress: boolean = false) {
|
||||
await fs.ensureDir('./dist-resource');
|
||||
await fs.emptyDir('./dist-resource');
|
||||
const folder = await fs.stat('./dist');
|
||||
totalSize = folder.size;
|
||||
if (totalSize < MAX_SIZE) return;
|
||||
|
||||
await fs.ensureDir('./dist-resource');
|
||||
await doSplit(compress);
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user