On Mon, Oct 28, 2002 at 11:49:22AM +0000, Dominic Mitchell wrote: > Baldur Gislason wrote: > >I agree, that would be a nice feature in usbd, but a workaround to gain > >the same functionality would be: > > > >attach "/usr/sbin/moused `/usr/bin/perl -e 'while(<>) { $foo = $_ . $foo; > >} if($foo =~ /^moused_flags="(.*?)"$/im) { print $1; }' < /etc/rc.conf` -p > >/dev/${DEVNAME} -I /var/run/moused.${DEVNAME}.pid" > > Why not just: > > attach ". /etc/rc.conf; /usr/bin/moused ${moused_flags} -p > /dev/${DEVNAME} -I /var/run/moused.${DEVNAME}.pid" > > (untested)
This had better be ". /etc/defaults/rc.conf; source_rc_confs; ..." :) I have been thinking for quite some time of writing a little utility that parses various configuration file mechanisms and allows the administrator to specify which config mechanism to use for which program. I have a simple design in mind, which would allow direct variable setting, use of /etc/rc.conf, use of other configuration files, use of daemontools-style envdirs, and a couple of others, but so far, there has been no time to actually start writing a simple proof-of-concept thing. Funny now, the timing; I was thinking of writing up a simple rcenv(1) today or tomorrow, and then I saw this thread :) G'luck, Peter -- Peter Pentchev [EMAIL PROTECTED] [EMAIL PROTECTED] PGP key: http://people.FreeBSD.org/~roam/roam.key.asc Key fingerprint FDBA FD79 C26F 3C51 C95E DF9E ED18 B68D 1619 4553 No language can express every thought unambiguously, least of all this one.
msg37698/pgp00000.pgp
Description: PGP signature