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

Re: Simple solution to pre-installation configuration

On Jan 29, ninf01@castor.GEL.USherb.CA (Fabien Ninoles) wrote:
> Really prefer this proposition then the other one. Is more 
> comprehensible, intuitive, easy to install and edit, and portable
> (I mean by this than is easier to do network installations this way).

Actually, while it may be more comprehensible at this point (because
Christophe is a better writer than I am), it's not easier. Here's why
(in terms of maintainer effort):

Christophe's method:

Maintainer writes a script to prompt for values, and then
writes/enhances the postinst script to generate/edit the configuration
file(s) that the package actually uses. If you're going to edit a file
(like a shell script), then you have to distribute a version or template
that has markers for each use of a configuration variable so that sed
(or whatever) can find them.

Greenland's method:

Worst case - identical to Christophe's, except that the post processing
is done in a separate script, not the postinst.

Better case - still has do the post processing to create the eventual
config file (probably non-executable, like smail's or cern-httpd), but
all user interaction is handled by a standard program. The maintainer
provides a straight forward list of variables, each with a description,
default value, and acceptable range.

Best case - maintainer modifies the executable "conf" files (think about
most of the scripts under /etc/init.d) to obtain their values from the
configuration database, and provides the list of variables, each with a
description, default value, and acceptable range. No scripts to

General comment:

Writing good UI code, even for something as simple as prompting for
values, is non-trivial. You have to deal with anything a user can type,
validate it against what you expect and can accept, and try to provide
some sort of sensible response if it's wrong.  For a configuration
script, you need to let the user cycle through the values, make changes,
but not lose anything they've entered once and and don't want to
change. Letting/requiring every maintainer to write (and re-write, and
update) this kind of script is not going to help Debian in its goals of
quality and consistency. response,

Steve Greenland

The Mole - I think, therefore I scream 

				"There's more hoods than we thought!"
				"Then shoot MORE BULLETS!"
[That champion of Justice, The FLAMING CARROT]

TO UNSUBSCRIBE FROM THIS MAILING LIST: e-mail the word "unsubscribe" to
debian-devel-REQUEST@lists.debian.org . Trouble? e-mail to Bruce@Pixar.com

Reply to: