Steve wrote:
>
> I am using Windows 98 and ActiveState Perl. I have a log file that after a
> certain size is truncated and reused. I have written a simple script to
> copy that file to another file using File::Copy. Is there a way to make
> sure the second file is appended instead of overwrit
Sorry for not explaining better. See commments below.
-Original Message-
From: Mat Harris [mailto:[EMAIL PROTECTED]]
Sent: Monday, October 07, 2002 7:24 AM
To: Timothy Johnson
Cc: 'Steve'; [EMAIL PROTECTED]
Subject: Re: File::Copy question
if you want to append to a second
if you want to append to a second file then you should use ">>" when
opening, not ">" or you will delete the text already there. if it was just
a typo then ignore me.
On Mon, Oct 07, 2002 at 07:20:29 -0700, Timothy Johnson wrote:
>
> If you want to append the contents of one file to another, the
If you want to append the contents of one file to another, then you will
have to open both files, read the first one, and write it to the second one.
Something like this should work:
##
use strict;
use warnings;
open(LOG,"mylog.log") || die "Couldn't open logfile for readin