quote:
Originally posted by L. Coyote
I suggested this months ago, and since I don't think it got a good response (I can't really remember), I made my own extra script for that.
It has in fact been suggested years ago, and again when the new update system was created.
The response back then, IIRC, was something in the line of "you're not supposed to change your script file names, so choose the file names wisely".
* CookieRevised slaps himself for not reading the posting date....
-------
quote:
Originally posted by L. Coyote
Instead of setting a "RemoveFile", I think the idea is to have a flag tag like "RemoveNonListed" (or some similar name, to express that the engine must remove all files that are not listed in the package being imported). That way, you don't have to write down each filename, you won't miss one and you won't misspell one.
quote:
Originally posted by whiz
My workaround is a list of files that should be there, and then everything else is removed.
Which will also delete any user generated file, (or script generated file), which is a major big no-no.... That would be a realy bad choice imo. I don't want any script to remove any files I have put in the scripting directory (like comment files, backups, a link to the thread, the actual plsc, etc).
A "RemoveFile" is far safer and better than "RemoveNonListed".
Also, I'm personaly not a fan of using wildcards, like markee suggested, in the "RemoveFile" attribute, for the same reasons above.
If you want to remove files you, as the script creater, knows what exact files were created/needed by the previous version. So no need for wildcards. Yes, it makes the "RemoveFile" list a bit longer, but it is far more safer and the user will not accidently loose any files because the script developper thinks he needed to remove all the existing files with <RemoveFile>*</RemoveFile>.
---------------
PS: in fact, I have no trouble manually deleting script files from scripts which are currently running though. The only thing you need to look out for when doing it manually is that the scripting editor isn't opened with the script you want to delete files from (goes only for JS files).
You can include the files you want to remove as null files (0 bytes long), and in the initialization of the script remove them (if they exist).
This even works when the scripting editor is opened (as long as you press "ok" to let Plus! close and re-open Messenger).