help-cfengine
[Top][All Lists]
Advanced

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

Re: ExecResult question


From: Chip Seraphine
Subject: Re: ExecResult question
Date: Mon, 30 Aug 2004 16:25:08 -0500
User-agent: KMail/1.5.4

Put the day 28 stuff in that directory.  :-)

On Monday 30 August 2004 16:03, John Sechrest wrote:
> 
> What do you do when there are 28 days in a month?
> 
> 
> 
> 
> Tod Oace <tod.r.oace@intel.com> writes:
> 
>  % Heh....this is what I ended up doing a while ago:
>  % 
>  % days = (  
>  % 01:02:03:04:05:06:07:08:09:10:11:12:13:14:15:16:17:18:19:20:21:22:23: 
>  % 24:25:26:27:28:29:30:31 )
>  % 
>  % Yes it's ugly and tedious, but it's more light-weight than forking and  
>  % running something else.
>  % -Tod
>  % 
>  % 
>  % On Aug 30, 2004, at 11:24, Chip Seraphine wrote:
>  % 
>  % >
>  % > I'm trying to get a list of days-of-the-month to iterate over (01 thru  
>  % > 31).
>  % > I'm doing this:
>  % >
>  % >  days=                           ( ExecResult(/usr/bin/perl -e 
> 'map{printf  
>  % > "day%02d\n",$_}(1..31)') )
>  % >
>  % > The contents of ExecResult(), when pasted into a shell, work fine  
>  % > (prints a
>  % > newline-delimited list of lines like "day01\nday02\n...").  However,  
>  % > cfengine
>  % > seems to result in $(days) equalling "')" (less the doublequotes).    
>  % > I've
>  % > been futzing about with the quote marks and backslashing various  
>  % > characters
>  % > but haven't gotten anything to work.  Any ideas what I am doing wrong?
>  % >
>  % > -- 
>  % >
>  % > Chip Seraphine
>  % > Unix Administrator
>  % > TradeLink, LLC
>  % > 312-264-2048
>  % > chip@trdlnk.com
>  % >
>  % >
>  % >
>  % > _______________________________________________
>  % > Help-cfengine mailing list
>  % > Help-cfengine@gnu.org
>  % > http://lists.gnu.org/mailman/listinfo/help-cfengine
>  % >
>  % -- 
>  % Tod Oace, Intel Corporation <tod@intel.com>
>  % 
>  % 
>  % 
>  % _______________________________________________
>  % Help-cfengine mailing list
>  % Help-cfengine@gnu.org
>  % http://lists.gnu.org/mailman/listinfo/help-cfengine
> 
> -----
> John Sechrest          .         Helping people use
>                         .           computers and the Internet
>                           .            more effectively
>                              .                      
>                                  .       Internet: sechrest@peak.org
>                                       .   
>                                               . http://www.peak.org/
~sechrest
> 

-- 

Chip Seraphine
Unix Administrator
TradeLink, LLC
312-264-2048
chip@trdlnk.com





reply via email to

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