Updating modules
Posted: 06 Dec 2015, 16:28
I am in the process of "cleaning up" my save.dat. There's a helpful script called update-module which copies changed files into a module. My understanding of this process is that the script checks whether a file that is in the module is also in live changes. If so, that file is copied back into the module (I'm leaving out the finer details of unpacking/packing the module and copying stuff into a /tmp directory).
This prompts a couple of questions. First and foremost, for this updating process to be foolproof (in theory at least) one would either need intimate knowledge as to which files are stored in what module or one would have to apply the update to all modules. My reasoning is as follows: say /usr/bin/whatever is both in 000-core and 07-somemod. In this case the copy in 07-somemod "wins", ie is the version that makes it into the live filesystem. If I now change /usr/bin/whatever and update 07-somemod, all seems to be well. If, however, 07-somemod is not activated for some reason, the (not updated) copy in 000-core wins. So either I *know* that /usr/bin/whatever needs updating in those two modules or I have to update *all* modules. (I'm talking here about the most general case.)
Case in point: Let's say I've just compiled a new version of 7zip and I now want to propagate this new version to all modules that have a copy (000-core and 05-devel). In this case that's no big deal because it's just one file... but in general? How do others deal with that?
Second question. Let's say I've updated module X and want to get rid of the updated files in the live system because they're now in module X. How do I find those files?
This prompts a couple of questions. First and foremost, for this updating process to be foolproof (in theory at least) one would either need intimate knowledge as to which files are stored in what module or one would have to apply the update to all modules. My reasoning is as follows: say /usr/bin/whatever is both in 000-core and 07-somemod. In this case the copy in 07-somemod "wins", ie is the version that makes it into the live filesystem. If I now change /usr/bin/whatever and update 07-somemod, all seems to be well. If, however, 07-somemod is not activated for some reason, the (not updated) copy in 000-core wins. So either I *know* that /usr/bin/whatever needs updating in those two modules or I have to update *all* modules. (I'm talking here about the most general case.)
Case in point: Let's say I've just compiled a new version of 7zip and I now want to propagate this new version to all modules that have a copy (000-core and 05-devel). In this case that's no big deal because it's just one file... but in general? How do others deal with that?
Second question. Let's say I've updated module X and want to get rid of the updated files in the live system because they're now in module X. How do I find those files?