Re: Debconf is not a registry
Colin Watson <cjwatson@debian.org> schrieb:
> On Mon, Nov 01, 2004 at 08:04:14AM +0100, Marc Haber wrote:
>> On Sun, 31 Oct 2004 01:07:05 +0200, Petter Reinholdtsen
>> <pere@hungry.com> wrote:
>> >Well, the solution to this problem is to _never_ use debconf to store
>> >information. The configuration info should be stored in the
>> >configuration files, and the current debconf values should be set
>> >based on the content of the configuration files. The values in the
>> >debconf database should only be used when no configuration file exist.
>> >
>> >(This is sometimes summarized using statements like 'debconf is not a
>> >registry'.)
>>
>> Why is the information given during package installation stored
>> persistently in the first place?
>
> As a convenience so that you don't have to waste time answering
> questions again and again.
But that could as well be achieved by parsing the configuration files:
if mypackage_parseconfig; then
db_set mypackage/item1 "$itemone"
db_set mypackage/item2 "$itemtwo"
db_set mypackage/item3 "$itemthree"
else
db_input mypackage/item1
db_input mypackage/item2
db_input mypackage/item3
db_go
fi
Regards, Frank
--
Frank Küster
Inst. f. Biochemie der Univ. Zürich
Debian Developer
Reply to: