[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Re: list iteration?
From: |
Mike |
Subject: |
Re: list iteration? |
Date: |
Mon, 03 May 2004 20:11:26 -0000 |
User-agent: |
slrn/0.9.7.4 (Linux) |
In article <mailman.3134.1083612534.1061.help-cfengine@gnu.org>, Luke A. Kanies
wrote:
> On Mon, 3 May 2004, Mike wrote:
>
>> What about the second part? In an editfiles: section how do you add
>> to the variable such that the variable has new things to iterate
>> over in the shellcommands: section?
>
> The only way to do that is to set a class in editfiles and then react to
> that in control:
>
> control:
> AddInstallable = ( dosomething )
>
> editfiles:
> { /path/to/file
> HashCommentLinesMatching "127.0.0.1"
> Define "dosomething"
> }
>
> control:
> dosomething::
> var = ( newvalue )
>
> shellcommands:
> "/bin/do something ${var}"
>
> The only ways to set variables in cfengine are in the control action or
> via methods or modules.
>
Thanks, that's what I felt was the answer.
I did find the BeginGroupIfDefined/EndGroup that should allow me
to update /ChangeLog from within editfiles:.
Mike
- list iteration?, Mike, 2004/05/03
- Re: list iteration?, Luke A. Kanies, 2004/05/03
- Message not available
- Re: list iteration?, Mike, 2004/05/03
- Re: list iteration?, Luke A. Kanies, 2004/05/03
- Message not available
- Re: list iteration?,
Mike <=
- Re: list iteration?, Steve Wray, 2004/05/03
- Re: list iteration?, Luke A. Kanies, 2004/05/05
- Re: list iteration?, Tod Oace, 2004/05/05
- Re: list iteration?, Luke A. Kanies, 2004/05/05
- Re: list iteration?, Tim Nelson, 2004/05/05