[Date Prev][Date Next] [Thread Prev][Thread Next] [Date Index] [Thread Index]

Re: problem with dpkg-reconfigure and noninteractive frontend



barbier@linuxfr.org (Denis Barbier) wrote:

> Consider for instance the locales package, can you please explain how
> local changes in /etc/locale.gen can be preserved while reconfiguring
> it in noninteractive mode?

Where's the problem? This file should be parseable really easy. It
consists only of 

a) comments (marked by ^[[:blank:]]*#) and empty lines
b) lines with pairs of entries

For each non-comment entry, one locale needs to be generated. You just
have to grep for the lines your package knows about, db_set them as
default, and offer them to the user in interactive mode (or just keep
them in noninteractive). User's changes through the debconf interface
can then be introduced either by deleting or adding the respective
lines, or by adding/removing comment signs.

Don't touch lines that your packages doesn't understand.

I have implemented this for tetex-bin's handling of language.dat in
config/postinst recently.

Regards, Frank
-- 
Frank Küster, Biozentrum der Univ. Basel
Abt. Biophysikalische Chemie



Reply to: