I've been pondering how to implement the default choice in the main menu. The menutest scripts will of course have to be used, but I don't think they should be the primary method.
Currently, we do this: - We ask all menu items "do you want to be default?" If they have a menutest, they answer yes or no, if they don't have a menutest, we check the status of the package (ret = unpacked || half_configured). - Of the menu items who say yes on isdefault, we pick the one with highest installer_menu_item Right, so the lower you are on the menu, the better you're off, and you're also better off if you *don't* have a menutest script :) That's why lilo-installer and base-installer often is the default. I think that the main way to check for default is package dependencies (among the menu items! I don't care if cdebconf isn't configured yet). This would mean that di-utils-mkfs cannot ever be the default before partitioned-harddrives -> di-utils-partitioner has been configured. base-installer cannot be default before mounted-partitions -> di-utils-mount-partitions has been configured. If we have ties, i.e. several packages that meet these criteria we could look at - status (unpacked ranks higher than installed, since 'installed' means it's been configured, i.e. the menu item has been executed) - menutest This puts menutests in a completely different situation, since they are now used mainly to resolve ties between different packages that provide the same virtual package (i.e. netcfg-dhcp exits with 0 and netcfg-static with 1, so -dhcp is default instead of -static) Can we still have ties after this? Do we want to still have ties after this and if so, how do we resolve them? Can we make sure that we don't have any ties here? Comments appreciated. /Martin
signature.asc
Description: Detta =?ISO-8859-1?Q?=E4r?= en digitalt signeradmeddelandedel