Joined: July 2004
||Posted: Oct. 06 2007,19:30
Personally I have no intention of editing what I wrote unless there is error in it. The reason for this is that I don't recommend your method of removing all directories indiscriminately. In most cases it should be fine to do that, but occasionally an application wants a particular directory to exist regardless of whether or not it's empty. I've actually even seen some apps that will fail to run if a particular directory is not found. This is poor programming, in my opinion, but it happens sometimes. In other cases, I think it's a good idea to keep some empty directories in select packages to help the user know where to put certain user-added files, such as plugins, codecs, themes, etc.
I think I've mentioned this before, but I believe solving the problem of file clobbering by removing all directories is similar to opening windows with a hammer. It works, but if you find out later that you needed to keep some of those windows closed you end up making more work for yourself. The only time directories cause problems is when they are pre-existing directories that have different owners/permissions than those in the extension, and typically this affects only the top few levels of the directory structure. For example, if you have an application that installs to /opt/myapp, the only directory you need to worry about taking out of the package is /opt. Any directories within myapp will not clobber anything unless "myapp" happens to be the name of a pre-existing directory (which it should *not* be unless you're making an extension just for your own use).
Existing directories in a *.dsl extension are of course much more common, so perhaps omitting them all (at least initially) would be much more efficient in that case. I haven't made a *.dsl myself in a couple of years, though, so my personal thought on that is "I don't care what you want to write about that type". Since nearly everything I do now is *.uci, the only directories that I need to watch are in user.tar.gz...a very minor task. Nothing else has even the slightest chance of clobbering.