View Single Post
08/11/20, 05:32 AM   #3
Baertram
Super Moderator
 
Baertram's Avatar
WoWInterface Super Mod
AddOn Author - Click to view addons
Join Date: Mar 2014
Posts: 4,912
Originally Posted by sirinsidiator View Post

Overall I don't think it makes much sense, since the data is very addon specific. You cannot make any decisions about what to delete and what to keep from the outside.
I agree here, the effort to keep this working would be too high, without a real gain.

Your best approach would be the manual way:
Always logout before changing SavedVariables.
Copy the folder "SaedVariables" for a backup.
Manipluate the \live\SavedVariables\<addonname>.lua file manually where needed, but you need to understand the lua table structues in it before.
Each { opens a table and got a relating }.
Due to several ways of addons storing the data in there it can be 1 table, or several in the same file. And either stored per @AccountName or for a specific character ["1234567890123456"].
Or even for all accounts the same ["AllAccounts"] (where this string "AllAccounts" could be any other string chosen by the addon dev for his/her/* addon.)
In addition the data can be saved for all servers the same, or there might be something like ["EU Megaserver"] or ["NA Megaserver"] and ["PTS"] to define which server the data was saved for. Again this could be chosen differentlky like just 1 2 3 or EU, NA PTS. It's the addon dev's decision how to create the file contents, maybe differently for each addon.

You see: Like sirinsidiator told you the effort to support them ALL, or also only a few, would be way to high and would need to checked and change each time any addon updates.

And corrupted files will only happen if maybe the client crashes (in most cases the files were not touched then and stay save, only if the crash happens during logout in the moment the files are written, it would happen).
Or if they grew too large which must be handled by the addons themselves, or by the user manually (in your example case with ESO Profiler).
  Reply With Quote