DrewNaylor / guinget

Unofficial GUI for Microsoft's Windows Package Manager (winget). Kinda like Synaptic, but for Windows. Not associated with either Microsoft or the Synaptic project, and Microsoft does not endorse this software.
Apache License 2.0
136 stars 3 forks source link

Use Robocopy and 7zip (or maybe RecursiveExtractor?) to speed up cache updates. #103

Open DrewNaylor opened 3 years ago

DrewNaylor commented 3 years ago

This'll require something that closes the child processes when the main form closes if the user closes it before it's done. Something here might help: https://stackoverflow.com/questions/3342941/kill-child-process-when-parent-process-is-killed

DrewNaylor commented 3 years ago

For now this won't be used as there have been major performance improvements already by extracting only manifests and moving the resulting folder instead of copying it. Might use this eventually if it's still too slow.

DrewNaylor commented 1 year ago

Or, maybe RecursiveExtractor's library could work: https://github.com/microsoft/RecursiveExtractor

This is under the MIT license, so it should be fine. Hopefully it can be used.

DrewNaylor commented 1 year ago

Update: just found this SO answer that mentions counting the compressed file size rather than using the file index, which apparently can speed things up: https://stackoverflow.com/a/61901480 From this link: https://stackoverflow.com/questions/61889156/system-io-compression-counting-the-number-of-files-using-zipfilearchive-is-ver

start of the post left half of the code right half of the code end of the post

Maybe I should try multi-threading with an option to turn it off if needed as well as a choice for the user to pick how many threads are used at a time maximum, or maybe not if it works just fine in a single-core VM?