Hi Jeroen,
On Sat, Feb 11, 2012 at 11:53 AM, Jeroen van Meeuwen (Kolab Systems) <[email protected]> wrote: > I'm in the process of creating some new lenses for Cyrus IMAP configuration > files, /etc/cyrus.conf and /etc/imapd.conf. > > The latter is a relatively easy lens to write, and I've already done so > (based on Postfix_Main actually) since it's a really easy sectionless .INI > type of file format (like /etc/postfix/main.cf). That actually sounds like what the Simplevars module does. > A question I have, though, is the naming for such lens; would it be > appropriate to call such lens Cyrus_Imapd_Imap (vs. Cyrus_Imapd_Main for > /etc/cyrus.conf?), or do you have any naming suggestions? I usually refer to the existing manpage for that. There's a standard man 5 imapd.conf, so I'd call the lens Imapd, and the other one Cyrus, since there is a man 5 cyrus.conf. > Also, I was wondering whether someone would be willing to assist me in > creating a lens for /etc/cyrus.conf, which has a little more difficult file > format? Any pointers in parsing the sections and exposing such in, say, an > augtool print /files/etc/cyrus.conf would be greatly appreciated. Perhaps > somebody knows of an example lens that uses a similar (or the same?) parsing > method? Cyrus.conf seems to be a block-based file. Have a look at the new block constructs in the Build module (in the git master branch). In particular, the following modules are now making use of Build.block* constructs: Keepalived, Logrotate and Xinetd. Cheers, Raphaël > > -- > Systems Architect, Kolab Systems AG > > e: vanmeeuwen at kolabsys.com > t: +44 144 340 9500 > m: +44 74 2516 3817 > w: http://www.kolabsys.com > > pgp: 9342 BF08 > > _______________________________________________ > augeas-devel mailing list > [email protected] > https://www.redhat.com/mailman/listinfo/augeas-devel _______________________________________________ augeas-devel mailing list [email protected] https://www.redhat.com/mailman/listinfo/augeas-devel
