On 03/15/2012 01:07 PM, Nick Anderson wrote:
> On 03/15/2012 07:01 AM, Mark Burgess wrote:
>> Thanks Eric, I had exactly the same thought. The problem with this
>> approach is that introduces "body syntax" within a bundle, which will be
>> confusing and will weaken the integrity of the language (and parser).
>> That is my main objection to this.
>>
>> What do others think?
> I agree that specific syntax breaks the integrity and consistency of the
> language.
>
>
> To keep consistency you could do something like this.
> metadata:
> "$(this.bundlename)"
> author => "kermit";
> email => "[email protected]";
> version => "42";
> purpose => "Make sure Miss Piggy doesn't get angry";
> comment => "Please don't let her read this!";
>
> I am not really convinced though
Yes, the problem with this is that you can only have one promise and the
name of it is not open for discussion, so why bother to write it...
My other idea was to have a separate body:
body bundlename meta
{
author => "kermit";
email => "[email protected]";
version => "42";
purpose => "Make sure Miss Piggy doesn't get angry";
comment => "Please don't let her read this!";
}
but then this could become inconsistent. The version does not actually
label anything, because it is just a pointer not an instance. That
brought me back to the idea that a variable would be the best.
CFengine already has some reserved variables "promiser" etc, so adding a
couple more with unlikely names is, I think, an approach that does the
least violence to the config, and also makes it trivial to track
versions through the reporting.
M
--
CTO and Founder
CFEngine
http://www.cfengine.com
http://www.markburgess.org
_______________________________________________
Help-cfengine mailing list
[email protected]
https://cfengine.org/mailman/listinfo/help-cfengine