Re: [Templates] ttree message when copying files

[prev] [thread] [next] [Date index for 2004/05/24]

From: Dave Cross
Subject: Re: [Templates] ttree message when copying files
Date: 16:16 on 24 May 2004
On Mon, May 24, 2004 at 11:53:53AM -0400, Barbara Freeze wrote:
> 
> We just installed Template Toolkit version 2.13 (30 Jan 2004). When I
> use ttree to build my system now, it is giving me messages like this
> when it finds files that are to be copied:
> 
> Use of uninitialized value in concatenation (.) or string at
> /usr/bin/ttree line 357.
>   > images/vertical_divider.gif      (copied, matches //)
> 
> The config file I use has the copy line as:
> 
> copy = \.gif$
> 
> The file does appear to copy okay, but why am I getting this message?

Andy, there's code at line 325 of ttree that looks like:

  foreach $check (@$copy) {
      if ($filename =~ /$check/) {
          $copy_file = 1;
      }
  }

Should that be

  foreach $check (@$copy) {
      if ($filename =~ /$check/) {
          $copy_file = 1;
          last;
      }
  }

Otherwise $check will usually end up with the wrong value.

Hmm... on further investigation, even that doesn't fix it as Perl is
automatically localising the value of $check. Is that new behavior?

Dave...

        -- 
          If there's something inside that you wanna say
  Say it out loud it'll be ok

_______________________________________________
templates mailing list
templates@xxxxxxxxxxxxxxxx.xxx
http://lists.template-toolkit.org/mailman/listinfo/templates

[Templates] ttree message when copying files
Barbara Freeze 15:53 on 24 May 2004

Re: [Templates] ttree message when copying files
Dave Cross 16:16 on 24 May 2004

Re: [Templates] ttree message when copying files
Harald Joerg 16:25 on 24 May 2004

Generated at 08:56 on 15 Mar 2005 by mariachi v0.52