help-cfengine
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Defining a class based on file contents


From: Chip Seraphine
Subject: Defining a class based on file contents
Date: Mon, 12 May 2003 09:43:55 -0500
User-agent: Mozilla/5.0 (X11; U; SunOS i86pc; en-US; rv:1.2.1) Gecko/20030121



I have a situation where I would like to define a class based on the contents of the file, but do not wish to actually modify the file itself. Does anybody know a good way to do this (other than using a module or shellcommand)?

I have tried "|BeginGroupIfNoLineContaining" and such, but this doesn't do the trick because I can't define classes inside the conditional block. There is no "touch" type command either, so I am not sure of a safe way to fool cfengine into thinking the file has been edited without doing something dangerous (changing the file) or silly (editing the file and then removing the edit). I was trying to do something clever with "abort" and "catchabort", but that doesn't seem well suited to this either.

Has anybody else solved a problem like this?
|





reply via email to

[Prev in Thread] Current Thread [Next in Thread]