Perl: How do I remove the first line of a file without reading and copying whole file.

Posted by dr jerry on Stack Overflow See other posts from Stack Overflow or by dr jerry
Published on 2010-06-10T17:13:10Z Indexed on 2010/06/10 22:32 UTC
Read the original article Hit count: 244

Filed under:
|
|

I do have a whole bunch of files in a directory and from every file I want to remove the first line (including carriage return). I can read the whole file into an array of strings and write all but the first element to a new file, but that looks a bit cumbersome to me are there better ways? Oh the prefered language is Perl.

© Stack Overflow or respective owner

Related posts about perl

Related posts about remove