Upgrade scripts?

Andreas Raab andreas.raab at gmx.de
Tue Oct 25 05:05:54 UTC 2005


Hi Folks -

I'm making a few changes which are potentially *really* dangerous if you 
don't load them in the right (incremental) order and I would like to be 
able to add a script which allows me to test whether a (compatible) 
version of prerequisite changes are installed. This would be a trivial 
script, something like:

(Foo canUnderstand: #bar) ifFalse:[
     self error: 'You must first load Foo-bar.42.mcz'.
].

and the question here is simply: Is there *any* way of achieving this? 
I'd be fine, for example, with a preamble script if that were executed 
even during upgrades but I don't think they do. Any other ideas? All I 
want to make sure is to not just crash the system because a poor user 
inadvertantly loads the "latest version" of package X.

Note that this may also be an "internal" dependency, e.g., in order to 
be able to upgrade to version Y of some package you must at least have 
version X installed. I'm mentioning this merely to point out that the 
available dependency mechanism cannot handle this (since you cannot have 
a package to depend on itself, ey? :-)

Cheers,
   - Andreas



More information about the Packages mailing list