Beefy Boxes and Bandwidth Generously Provided by pair Networks
Just another Perl shrine
 
PerlMonks  

Re: Delete Lines Across Multiple Files

by jwkrahn (Abbot)
on Dec 31, 2020 at 22:50 UTC ( [id://11126063]=note: print w/replies, xml ) Need Help??


in reply to Delete Lines Across Multiple Files

This may work (UNTESTED):

my @files = ( $rrconfig::locodata, $rrconfig::availlocodata, # add other file names here ); { local @ARGV = @files; local $^I = '.back'; # change '.back' to '' if your system supports it while ( <> ) { next if /^[^:]*:$delroad:$delnumber:/; print; } }

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others drinking their drinks and smoking their pipes about the Monastery: (4)
As of 2024-04-25 21:19 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found