On Mon, 2005-10-24 at 01:16 +0200, Richard Levitte - VMS Whacker wrote:
> tbrownaw> pattern "net.example.project.{security,private}*"
> tbrownaw> allow "[EMAIL PROTECTED]"
> tbrownaw> allow "[EMAIL PROTECTED]"
> tbrownaw>
> tbrownaw> pattern "net.example.{public,project}*"
> tbrownaw> others "allow"
>
> Random response:
>
> I think it's quite confusing how the format is sometimes
> 'verb "subject"' and sometimes 'subject "verb"'. I would rather have
> some kind of consistency:
>
> pattern "net.example.project.{security,private}*"
> allow "[EMAIL PROTECTED]"
> allow "[EMAIL PROTECTED]"
>
> pattern "net.example.{public,project}*"
> allow "*"
It now uses this syntax. Keywords are "pattern", "allow", "deny", and
"continue". Every "pattern" line starts a new section, and it will only
"fall through" a block if it has a 'continue "true"' line. "deny" is the
default, so it's only useful in blocks with 'continue "true"' such as
# jim fubared this branch once already...
pattern "net.example.project.foobar*"
allow "[EMAIL PROTECTED]"
deny "[EMAIL PROTECTED]"
continue "true"
pattern "net.example.project*"
allow "[EMAIL PROTECTED]"
allow "[EMAIL PROTECTED]"
allow "[EMAIL PROTECTED]"
allow "[EMAIL PROTECTED]"
[...]
Any line that doesn't match ' *[^ ]* *".*"', or that doesn't have
"allow", "deny", "pattern", or "continue" as the first word is ignored.
Still TODO: the parser just looks for a word followed by a quoted
string. It should probably be improved to handle full basic_io, meaning
escaped chars in the string and any number (0+) of quoted strings using
either "" or [] . It should also be made to recognize comments properly,
possibly including comments at the end of lines with useful info.
allow "joe" # comment about joe
write-permissions is still a simple list of keys, but now with "*"
instead of "--all--".
Tim
_______________________________________________
Monotone-devel mailing list
[email protected]
http://lists.nongnu.org/mailman/listinfo/monotone-devel