Imported Upstream version 0.10.0
[platform/upstream/augeas.git] / lenses / shells.aug
1 (*
2 Module: Shells
3   Parses /etc/shells
4
5 Author: Raphael Pinson <raphink@gmail.com>
6
7 About: Reference
8   This lens tries to keep as close as possible to `man 5 shells` where possible.
9
10 About: License
11    This file is licenced under the LGPLv2+, like the rest of Augeas.
12
13 About: Lens Usage
14    To be documented
15
16 About: Configuration files
17    This lens applies to /etc/shells. See <filter>.
18 *)
19
20
21 module Shells =
22   autoload xfm
23
24 let empty = Util.empty
25 let comment = Util.comment
26 let shell = [ seq "shell" . store /[^# \t\n]+/ . Util.eol ]
27
28 (* View: lns
29      The shells lens
30 *)
31 let lns = ( empty | comment | shell )*
32
33 (* Variable: filter *)
34 let filter = incl "/etc/shells"
35     . Util.stdexcl
36
37 let xfm = transform lns filter