BF3RM / vumm-cli

VU Mod Manager CLI
MIT License
6 stars 0 forks source link

Only replace files inside the mod folder that are distributed #12

Closed FoolHen closed 2 years ago

FoolHen commented 3 years ago

Right now the folder is deleted and replaced with the downloaded folder, but some mods create a mod.db that shouldn't be deleted when updating, as it might be populated with user data. I suggest only replacing the files/folders that are distributed, so each mod.db, mod.json, vu.vuic and ext file/folder is only replaced if it's inside the donwloaded zip.

kapraran commented 3 years ago

You should also add a cli option to do a clean update (maybe --clean) and delete everything.

paulhobbel commented 3 years ago

This is the current behavior, it will delete the mod folder and recreate it.

My idea is to check the file hashes and based on that check whether they where manually modified. If a file has been modified vumm should ask the user whether it's allowed to replace the file

Then when that's in place the --clean flag makes sense as that will force clean it yea

paulhobbel commented 2 years ago

For now I took another route, only the ext folder is removed and everything else is extracted over the existing files. This means that if your mod does not come with a built in mod.db it would not replace it on an update