Date: Tue, 25 Jul 1995 15:04:47 +0930 (CST) From: Michael Smith <msmith@atrad.adelaide.edu.au> To: jkh@time.cdrom.com (Jordan K. Hubbard) Cc: msmith@atrad.adelaide.edu.au, current@FreeBSD.org Subject: Re: Knobs in /etc/sysconfig Message-ID: <199507250534.PAA01801@genesis.atrad.adelaide.edu.au> In-Reply-To: <3128.806642718@time.cdrom.com> from "Jordan K. Hubbard" at Jul 24, 95 08:25:18 pm
next in thread | previous in thread | raw e-mail | index | archive | help
Jordan K. Hubbard stands accused of saying: > > Please ensure that the default "yes" values are documented in the comments > > preceeding each knob; preferably in some standard format, eg: > > > > # default: <value> > > Sounds reasonable.. We still need to go through and ethnically clense > our handling of variables in general, actually. It would be nice if > there was a STANDARD NAMING CONVENTION that told one whether or not a > given variable was a Boolean, a list of arguments, a list of things > that had their own sub-variables (like the network_interfaces var), > etc. Hmm, configuration files : the bane of my existence 8) Before I/we get too rampant on this, what's the feeling (in particular from Rod, of course 8) on imposing some structure on the layout of /etc/sysconfig? A first cut would look something like this : Lines beginning with '#' are comments. Lines beginning with '#*' are structure comments. #* Section: Keyboard ... #* Keyword: KBD_repeat_rate #* OneOf: "No change"=none,"Fast"=fast,"Medium"=medium,"Slow"=slow #* Default: none KBD_repeat_rate = none ... #* Section: Networking ... #* Keyword: NET_interface_list #* String: #* Default: "ed0 lp0" NET_interface_list = "ed0 ed1" ... etc. It's impossible to embed _all_ of the intelligence required into these comments, and overdoing it is harmful to your sanity, but minimising the keyword-specific intelligence required for processing would be nice 8) Some other proposals : variable name prefixes. I've already proposed KBD and NET, I'll add PKG_pkgname for package-specific stuff (in a Packages section). As far as types are concerned, I see current use of : Boolean : ON/OFF OneOf : one of a,b,c,d ListOf : none or more of a,b,c,d String : some string value StringBoolean : some string value or OFF (or NO or something similar). FQDN : qualified name (dotted address style) IPADDR : a dotted-quad value. Pathname : a pathname I can see possible use for : Mailaddr : a mail address Device : a device name And I'm sure I've missed some. The alternative to the structure comments is a hints file, but keeping the two in sync would be a major nuisance, and would really only hit the limelight if a proposal similar to the above was rejected. > Probably the time to do that is now before it gets too big, but I'm > also not going to hold my breath. It's work. Not as much as some other things. Thoughts? > Jordan -- ]] Mike Smith, Software Engineer msmith@atrad.adelaide.edu.au [[ ]] Genesis Software genesis@atrad.adelaide.edu.au [[ ]] High-speed data acquisition and [[ ]] realtime instrument control (ph/fax) +61-8-267-3039 [[ ]] My car has "demand start" - Terry Lambert [[
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?199507250534.PAA01801>