help-cfengine
[Top][All Lists]
Advanced

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

RE: Three-Line service comments


From: Tim Auckland
Subject: RE: Three-Line service comments
Date: Thu, 2 Aug 2001 12:22:09 -0700

Please could you give me an example?  I've tried just embedding $(n) in
a search string or regexp and it doesn't seem to help.

I'm trying to delete the three lines:

#
# GNATS
#

This doesn't find any matches:
      DeleteLinesContaining "#$(n)# GNATS$(n)#"

This matches, but only deletes one line out of the three:

      DeleteLinesMatching "(#$(n))*# GNATS($(n)#)*"

Thanks,
  Tim

> -----Original Message-----
> From: Mark.Burgess@iu.hio.no [mailto:Mark.Burgess@iu.hio.no] 
> Sent: Wednesday, August 01, 2001 11:29 PM
> To: a.phillips@dnmi.no
> Cc: Tim Auckland; help-cfengine@gnu.org
> Subject: Re: Three-Line service comments
> 
>
... 
>
>
http://www.cfengine.org/docs/cfengine-Tutorial.html#Variable%20substitut
ion
>
>you can use $(n) as a newline or $(cr) for carriage return. That way
you could >just search and replace the commented line for a four line
stanza.
>
>cheers,
>Mark
>
>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
>Work: +47 22453272            Email:  Mark.Burgess@iu.hio.no
>Fax : +47 22453205            WWW  :  http://www.iu.hio.no/~mark
>~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~





reply via email to

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