[augeas-devel] Augeas lens for Debian control file

David Lutterkort lutter at redhat.com
Fri Feb 26 18:49:21 UTC 2010


On Fri, 2010-02-26 at 14:35 +0100, Dominique Dumont wrote:
> On Wednesday 24 February 2010 20:37:35 David Lutterkort wrote:
> > > This lens applies to Debian control file used for Debian package
> > > creation.  Since this is a user's configuration file, not to a system
> > > configuration file, augtool '-r' option must be used to set up the root
> > > directory used by Augeas.
> > 
> > Another way to do this is to set up the transform manually, e.g.
> > 
> >         augtool --noautload <<EOF
> >         rm /augeas/load/*
> >         set /augeas/load/Debctrl/lens Debctrl.lns
> >         set /augeas/load/Debctrl/incl /path/to/control
> >         load
> >         ... do stuff ..
> >         EOF
> 
> Err, that's an _interesting_ way of replacing the '-r' option ;-)
> 
> I see 2 problems: 
> - the setup is more complex than just specifying the root dir
> - the user is required to know the name of the lens to apply to control file
> 
> Anyway, feel free to add these steps in the comment of Debctrl lens.

Ok .. you convinced me. I pushed the lens as-is - the only downside of
using autoload here is that in the default setup, Augeas will try to
find the file /control. That is not much of a problem right now, and
hopefully will never be.

David




More information about the augeas-devel mailing list