[augeas-devel] [PATCH] Allow flags
David Lutterkort
dlutter at redhat.com
Wed Aug 13 18:29:04 UTC 2008
On Wed, 2008-08-13 at 18:20 +0200, Raphael Pinson wrote:
> # HG changeset patch
> # User Raphael Pinson <raphink at gmail.com>
> # Date 1218644422 -7200
> # Node ID 0fecb892aefdeef53e5c73d7cfe2c862e1e79488
> # Parent 77868db94cb316e09e7872cc3ab087a22ec9684c
> Allow flags
>
> diff -r 77868db94cb3 -r 0fecb892aefd lenses/inifile.aug
> --- a/lenses/inifile.aug Wed Aug 13 14:16:45 2008 +0200
> +++ b/lenses/inifile.aug Wed Aug 13 18:20:22 2008 +0200
> @@ -41,7 +41,7 @@ let empty = Util.empty
>
> (* Some implementations of INI file allow ":" as separator *)
> let entry_generic (kw:regexp) (sep:lens) (comment:lens)
> - = [ key kw . sep . value_to_comment? . (comment|eol) ]
> + = [ key kw . (sep . value_to_comment?)? . (comment|eol) ]
> let entry (kw:regexp)
> = entry_generic kw value_sepwithcolon comment
> let entry_setcomment (kw:regexp) (comment:lens)
I have two issues with this patch:
1. it's now legal to drop the '=' in _any_ inifile - is there a way
to do this only for the files where a key all by itself is
legal ?
2. because of bug #4, this might go terribly wrong; the tests all
pass, but I worry that we'll drop tons of stuff on the floor.
(That's really more a reason to fix that bug, but I am not sure
how quickly I'll have time to do that)
For now, I haven't committed this.
David
More information about the augeas-devel
mailing list