--- Nichole Bialczyk <[EMAIL PROTECTED]> wrote:
> so how do i delete the lines that i read in? (keeping the first one
> so that the file still exists)

In the code segment I posted below, the first thig I do after openeing
the file is read a line from it -- which I do nothing with, so it gets
thrown away.

Afterwards, I print all remaining lines, which you could send to
another open filehandle instead of just the screen.

> On Fri, Jun 01, 2001 at 02:08:25PM -0700, Paul wrote:
> > 
> > --- Nichole Bialczyk <[EMAIL PROTECTED]> wrote:
> > > to be more specific, i want to do this: read and delete all of
> the
> > > lines  from a log file, except for the first one.
> > 
> >  open IN, $file or die "$file:$!";
> >  <IN>;        # throw away first line;
> >  print <IN>;  # print the rest of the file.
> > 
> > __________________________________________________
> > Do You Yahoo!?
> > Get personalized email addresses from Yahoo! Mail - only $35 
> > a year!  http://personal.mail.yahoo.com/


__________________________________________________
Do You Yahoo!?
Get personalized email addresses from Yahoo! Mail - only $35 
a year!  http://personal.mail.yahoo.com/

Reply via email to