3 Parses /etc/schroot/schroot.conf
5 Author: Raphael Pinson <raphink@gmail.com>
8 This lens tries to keep as close as possible to `man 5 schroot.conf` where possible.
11 This file is licenced under the LGPL v2+, like the rest of Augeas.
16 About: Configuration files
17 This lens applies to /etc/schroot/schroot.conf. See <filter>.
25 (************************************************************************
26 * Group: USEFUL PRIMITIVES
27 *************************************************************************)
30 An <IniFile.comment> entry *)
31 let comment = IniFile.comment "#" "#"
34 An <IniFile.sep> entry *)
35 let sep = IniFile.sep "=" "="
38 (************************************************************************
40 *************************************************************************)
43 Descriptions are special entries, which can have an optional lang parameter *)
45 let lang = [ Util.del_str "[" . label "lang"
46 . store IniFile.entry_re . Util.del_str "]" ]
47 in IniFile.entry_generic_nocomment (key "description" . lang?) sep "#" comment
50 An <IniFile.entry>, or <description> *)
51 let entry = IniFile.entry (IniFile.entry_re - "description") sep comment
56 let title = IniFile.title IniFile.record_re
59 An <IniFile.record> *)
60 let record = IniFile.record title entry
64 let lns = IniFile.lns record comment
67 let filter = (incl "/etc/schroot/schroot.conf")
69 let xfm = transform lns filter