feat: optimize decompression
Signed-off-by: MiaoWoo <admin@yumc.pw>
This commit is contained in:
parent
367b732f7c
commit
ea8e62b696
@ -271,7 +271,7 @@
|
|||||||
// @ts-ignore
|
// @ts-ignore
|
||||||
var entry; var target = root + separatorChar + 'node_modules' + separatorChar + module_name;
|
var entry; var target = root + separatorChar + 'node_modules' + separatorChar + module_name;
|
||||||
while ((entry = tis.getNextEntry()) != null) {
|
while ((entry = tis.getNextEntry()) != null) {
|
||||||
var targetPath = Paths.get(target + separatorChar + entry.getName().substring('package/'.length));
|
var targetPath = Paths.get(target + separatorChar + entry.getName().substring(8));
|
||||||
targetPath.toFile().getParentFile().mkdirs();
|
targetPath.toFile().getParentFile().mkdirs();
|
||||||
Files.copy(tis, targetPath, StandardCopyOption.REPLACE_EXISTING);
|
Files.copy(tis, targetPath, StandardCopyOption.REPLACE_EXISTING);
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user