Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Deleting first and last lines of a text file

by blue_cowdawg (Monsignor)
on May 16, 2014 at 13:56 UTC ( [id://1086316]=note: print w/replies, xml ) Need Help??


in reply to Deleting first and last TWO(2) lines of a text file

#!/usr/bin/perl -w use Tie::File; use strict; my $fname = shift @ARGV; tie my @file,'Tie::File',$fname or die $!; pop @file; pop @file; shift @file; untie @file; exit(0);


Peter L. Berghold -- Unix Professional
Peter -at- Berghold -dot- Net; AOL IM redcowdawg Yahoo IM: blue_cowdawg

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://1086316]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others sharing their wisdom with the Monastery: (2)
As of 2024-04-24 17:59 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found