On Sat, Feb 08, 2020 at 11:04:10PM +0100, Ingo Schwarze wrote:
> Hi Theo,
> 
> you have a point, that was a lot of cheap talk and no patch.
> 
> I don't aim at changing yacc(1) grammars.  I think most parts of
> OpenBSD configuration systems already have sane defaults and most
> configuration syntaxes are already good with respect to simplicity
> and usability.  At least "most", maybe even all.
> 
> > The example files were moved from /etc, so that /etc contained fewer
> > files for unconfigured software.
> 
> That was a very good step, and it was also good to not encumber it
> by trying to do more at the same time.
> 
> > Little to no effort was put into curating them.  That's the gap that
> > occured.
> 
> So, here i'm putting a few pennies where my mouth is, starting from the
> shortest file in /etc/examples/.  The example is so short that cut and
> paste from the manual page will certainly cause no trouble, and the
> file also isn't a special case with respect to permissions,
> it is -rw-r--r-- root:wheel.
> 
> OK?
>   Ingo
> 
> 
> P.S.
> When preparing this, i noticed i already had the change to
> mixerctl.conf.5 in my tree.  It looks like i started it
> in the past, then forgot about it.
> 
> P.P.S.
> Note that i will not propose to get rid of *all* of /etc/examples/,
> but just of trivial examples that provide no benefit by being outside
> the manual page.  There are certainly some that make sense as they
> are.
> 
> 
> Index: etc/Makefile
> ===================================================================
> RCS file: /cvs/src/etc/Makefile,v
> retrieving revision 1.477
> diff -u -p -r1.477 Makefile
> --- etc/Makefile      24 Jan 2020 06:17:37 -0000      1.477
> +++ etc/Makefile      8 Feb 2020 21:42:14 -0000
> @@ -46,7 +46,7 @@ MUTABLE=changelist daily etc.${MACHINE}/
>  
>  # -rw-r--r--
>  EXAMPLES=acme-client.conf chio.conf dhclient.conf dhcpd.conf exports \
> -     httpd.conf ifstated.conf inetd.conf man.conf mixerctl.conf \
> +     httpd.conf ifstated.conf inetd.conf man.conf \
>       mrouted.conf ntpd.conf printcap rad.conf rbootd.conf \
>       remote sensorsd.conf wsconsctl.conf
>  
> Index: share/man/man5/mixerctl.conf.5
> ===================================================================
> RCS file: /cvs/src/share/man/man5/mixerctl.conf.5,v
> retrieving revision 1.7
> diff -u -p -r1.7 mixerctl.conf.5
> --- share/man/man5/mixerctl.conf.5    30 Jul 2018 17:24:24 -0000      1.7
> +++ share/man/man5/mixerctl.conf.5    8 Feb 2020 21:42:14 -0000
> @@ -141,6 +141,11 @@ Default audio mixing device.
>  .Xr mixerctl 1
>  configuration file.
>  .El
> +.Sh EXAMPLES
> +Most audio cards support setting the output volume by adding this line to
> +.Nm :
> +.Pp
> +.Dl outputs.master=200
>  .Sh SEE ALSO
>  .Xr aucat 1 ,
>  .Xr audioctl 1 ,
> Index: etc/examples/mixerctl.conf
> ===================================================================
> RCS file: etc/examples/mixerctl.conf
> diff -N etc/examples/mixerctl.conf
> --- etc/examples/mixerctl.conf        16 Jul 2014 13:21:33 -0000      1.1
> +++ /dev/null 1 Jan 1970 00:00:00 -0000
> @@ -1,7 +0,0 @@
> -# $OpenBSD: mixerctl.conf,v 1.1 2014/07/16 13:21:33 deraadt Exp $
> -#
> -# mixerctl(1) configurable parameters. See mixerctl.conf(5) for details.
> -#
> -
> -# output volume value for most audio cards
> -#outputs.master=200

without getting into a discussion about /etc/examples, in this case i
personally see neither the point of the example config file (so trivial
as to be questionable) nor the addition to the man page (if the example
is worthwhile, add it to mixerctl, not the conf page).

surely stuff like this is self explanatory.

note that mixerctl.conf.5 has an entry in FILES for /etc/mixerctl.conf
(non-existent by default) but not /etc/examples/mixerctl.conf (which
does exist). i guess whatever we decide on, we need to check that we're
getting this right and doing it consistently across our pages.

jmc

Reply via email to