Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Perl Rename

by Mad_Mac (Beadle)
on Jul 03, 2010 at 08:41 UTC ( #847883=perlquestion: print w/ replies, xml ) Need Help??

Help for this page

Select Code to Download


  1. or download this
    #!/usr/bin/perl -w
    $op = shift or die "Usage: rename expr [files]\n";
    ...
      die $@ if $@;
      rename ( $was, $_ ) unless $was eq $_;
    }
    
  2. or download this
    perl rename.pl 's/Blah Blah - \d{2} - //' *
    perl rename.pl 's/^Blah Blah - \d{2} - //' *
    

Log In?
Username:
Password:

What's my password?
Create A New User
Node Status?
node history
Node Type: perlquestion [id://847883]
Approved by Corion
Front-paged by Corion
help
Chatterbox?
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others contemplating the Monastery: (5)
As of 2015-07-04 10:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (59 votes), past polls